Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

PORTAL session NOT PortletSession

 
Gangadhar Reddy
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I know that Portlet-A will be having different PortletSession then that of Portlet-B, even though both are in same portal page. Here I need a session for a client to store some thing from Portlet-A's PortletSession and the same can be retrieved by Portlet-B's PortletSession. I can't keep/share in ApplicationScope as it is available to entire application/ALL users. I want the data to be available only for that logged in user. So do we have some thing like HttpSession which is unique for each logged in user and can be shared by all portlets with in that unique session.
 
Gangadhar Reddy
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No one has replied to my question ;-) However I had found out the solution.

getPortletSession().setAttribute("SOME_CONSTANT", Object, PortletSession.APPLICATION_SCOPE);

getPortletSession().getAttribute("SOME_CONSTANT",PortletSession.APPLICATION_SCOPE);
 
Dharmesh Chheda
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Gangadhar

This will only work if you have both the portlets in the same portlet application... only then will the APPLICATION_SCOPE work
 
Per-Morten Lindanger
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have been looking for something about how to share session-beans between portlets in different applications for quite some time now, and I have'nt had any success.

According to this link, it should be in the JSR 286 spesification but I just can't find any information about how to use it!

http://marcus-christie.blogspot.com/2006/09/top-10-coolest-things-coming-in-jsr.html

Please help!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic