JSF Management Bean & JSR168 Portlet Session problem

Hi,

I'm developing a JSR168 Portlet with JSF. I seem to have run into a little bit of a snag with JSF & JSTL (v1.1xxx).

I have set a managed bean in my faces config file as a session bean. All works well if I use JSF tags to access the jsf-managed-session-bean. The problem occurs that JSTL tags cannot see the jsf-managed-session-bean. The JSTL tags print nothing, not even "null". So it doesn't seem to be able to find the jsf-managed-bean in the session. If I change the JSF-managed-bean to request within the jsf config then the JSTL tags can see the bean fine. I'm not sure if this is a portlet or a JSF issues, but I suspect it could be a portlet issue.

If I print out all the session attribute names I find that the JSF-managed-bean has a very strange name like:

"javax.portlet.p.7_AJM41F3308FRE02H3CT5S120K6?<jsf-bean-name>"

So it seems that JSF or the portal is storing session data as part of the attribute name. I assume this is why the JSTL is not able to see the managed-bean. I still find it rather strange that the JSF-tags have no problem accessing the JSF-managed-session bean.

Any ideas or help would be greatly appreciated.

Thank you,

[1218 byte] By [rac00nzaa] at [2007-11-27 0:51:25]
# 1
I take it that I'm the only one on this planet with this problem? lol
rac00nzaa at 2007-7-11 23:22:14 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

Not everyone on the planet reads this forum! :)

There are a good few other forums you could try though... JGuru, JSFTutorials, IBM, and Neoseeker all have JSF forums I think!

Good luck with it!

Also, here is a link to an article about mixing JSTL and JSF. In it the writer uses JSTL to access a session-scoped bean, so it could be a help to you, hopefully!

http://www.devx.com/Java/Article/21020/1954?pf=true

Cheers,

Illu

Message was edited by:

Illu

Message was edited by:

Illu

Illua at 2007-7-11 23:22:14 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

Hi Illu ,

Thanks for your reply. I've read through that article previously, and I am doing nothing different then what the article does. Thats why I'm completely vexed as to why I'm having this problem. It seems to be other a JSF with JSR-168 portal problem. If I mix JSF and JSTL in a normal jsp without Portals it works fine.

I'll try post on those other links.

Thanks

rac00nzaa at 2007-7-11 23:22:14 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4
hii am new in jsfi am facing a problem, i have two JSFManagement bean in my application one bean in working fine but another is not, how can i run othere one bean throught jsf.help plz.
vikas_Porwala at 2007-7-11 23:22:14 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...