View Full Version : Portlet Namespace
sarojkr
Mar 27th, 2007, 03:14 AM
Hi,
I have few queries regarding namespace.
1. How is the namespace created for a portlet by the portlet container ?
2. How unique is it ? Is is unique for every portlet across sessions and users ? i.e. Will it vary for different users and subsequent user session ?
3. How do i obtain the namespace of a portlet programatically ? I know it can be obtained from renderResponse.getNamespace(). Any other ways or workaround.
Please share your thought, insights and ideas in this regard.
Regards,
Saroj Kumar
cmelgar
Mar 27th, 2007, 06:59 AM
1. How is the namespace created for a portlet by the portlet container ?
2. How unique is it ? Is is unique for every portlet across sessions and users ? i.e. Will it vary for different users and subsequent user session ?
The only requirement is that the namespace must be unique within the page the portlet is being rendered in. Each RenderRequest could possibly return a different value for the same portlet on the same page (within a single render request it returns the same value each time getNamespace() is called).
3. How do i obtain the namespace of a portlet programatically ? I know it can be obtained from renderResponse.getNamespace(). Any other ways or workaround.
The only time is makes sense to get the namespace is during the RenderRequest of a particular portlet so I can't think of any other place where you could get it, or why it would make sense to obtain it at another way...
sarojkr
Mar 27th, 2007, 07:38 AM
Hi Chris,
The need is this. I need to invoke the action phase of a portlet in another page ? I found out that it requries namespace information for this.
As of now, i can construct an action url. This is of the form
http://url/pagename/action.process/javax.portlet.action=true&javax.portlet.tpst=c8834cbd5b1754f730948210266edea 0. This requires the knowledge of namespace.
Is there any other way to trigger action phase of a portlet other the using the namespace ??
Regards,
Saroj Kumar
cmelgar
Mar 27th, 2007, 04:51 PM
This question would probably be better directed at your portal server's support forums as it relates to implementation specific details. There is no connection between the portlet namespace and the generated URLs in the standard...
Chris
vBulletin® v3.7.3, Copyright ©2000-2008, Jelsoft Enterprises Ltd.