portals-pluto-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "LaCasse, John" <JLaCa...@filenet.com>
Subject RE: response.createActionURL() doesn't return a fully qualified URL
Date Wed, 02 Feb 2005 19:02:14 GMT
Thanks for the response Stephan,

I'm a bit confused by the response so let me restate what I'm trying to
do. I'm not trying to create a URL from the outside to get into the
portlet (as your question to J2 would indicate). I'm passing what
response.createActionURL().toString() returns to me to an outside app
and using it to redirect back to the portlets processAction method. I'm
assuming this url is guaranteed to be valid as this is the mechanism
used to create a url that will trigger a processAction/event. At the end
of the day I'm expecting the url returned from
response.createActionURL().toString will trigger the proper event in the
portlet when redirected to from an outside app. If this url were just
fully qualified it would work. If I prepend the scheme and domain:port
to it, it in fact does work. Interestingly, in a previous build I'm
pretty sure this url was fully qualified. My stuff was working fine
until I got the latest source. Consequently now I have to fully qualify
it myself. This particular issue is frustrating because I have to deal
with it differently on every different implementation. Right now it is
true that at least with Websphere, Weblogic and Pluto the url is valid
as long as it is fully qualified so it's not clear to my why everybody
just doesn't fully qualify the returned url; that way this behavior
would be standard across platforms and not have to be special cased. I
fully admit I don't fully understand the underlying implications but
based on three of the most popular venders there doesn't seem be a
reason not to require this (or at least some standard way of getting
this) in the spec.

-----Original Message-----
From: Stefan Hepper [mailto:sthepper@apache.org] 
Sent: Wednesday, February 02, 2005 9:33 AM
To: pluto-dev@portals.apache.org
Subject: Re: response.createActionURL() doesn't return a fully qualified

LaCasse, John wrote:

> When I call response.createActionURL() it isn't returning a fully 
> qualified URL; other jsr168 containers I've used specifically 
> WebSphere and Weblogic may or may not return fully qualified URL's. In

> WebSphere you have to response.encodeURL() to get it; Weblogic does it

> by default and pluto doesn't appear to do it at all. This makes it 
> difficult to get back to the portlet from outside the app which I need

> to do frequently. One thing is for sure and that is that everybody 
> seems to be doing their own thing here and hence removing some of the 
> benefit of having a standard. Any thoughts or suggestions on this
> Thanks,
> Jpl
The JSR 168 clearly states that the URL generated by PortletURL.toString

may not be a valid URL. This is especially true when running as a WSRP 
producer where the URL will be a WSRP defined token that gets re-written

by the WSRP producer. EncodeURL is meant for encoding resource URLs, not

portlet URLs.

The JSR 168 spec does not define any means to address portlets directly,

this is something that is vendor specific currently. This is also not an

easy thing, as normally you would want to address a portal page with 
specific portlets on the page, right? Even if it is one portlet only you

would need the combination of portlet Java instance + preference data, 
which is why you cannot simply map it to a URL for the java instance 
like in the servlet case. Inside portals this can be quite differently 
represented right now.

Some help may be coming from the web services world. Once WS-Resouces is

further along, WSRP V 2.0 or 3.0 may include something like that.

So, sorry nothing as solution for today, besides vendor extensions.

Question to the Jetspeed-2 guys: is there a service in J2 that a outside

component can use to create a link to specific portlets.


View raw message