-
1. Re: Integration with bea weblogic portal
claprun Apr 14, 2008 2:33 PM (in response to emigcrd)I'm not sure what you are trying to do exactly... What do you mean by "backing file"?
Note that anything that is not in the WSRP messages sent by the consumer will not be passed to the producer. Any attempts to modify the request on the consumer side of things will not result in anything interesting on the producer if these modifications are not conveyed to the WSRP messages. -
2. Re: Integration with bea weblogic portal
emigcrd Apr 14, 2008 3:59 PM (in response to emigcrd)Hi, im trying to pass parameters from the portal to portlets, for example, when an end user log on in the portal, the user get an id (an id session for example), i need to pass this id to the portlet, my consumer is bea and im using a backing file like:
http://edocs.bea.com/wlp/docs81/wsrp/custxfer.html
my backing file only contain :
public class CustomDataBacking extends AbstractJspBacking
{
public boolean preRender(HttpServletRequest request,
HttpServletResponse response)
{
request.setAttribute("zipCode", "80501");
return true;
}
}
in the producer in the method doView i try to get this value with:
protected void doView(RenderRequest rRequest, RenderResponse rResponse)
throws PortletException, IOException, UnavailableException
{
rResponse.setContentType("text/html");
String value=(String) rRequest.getParameter("zipCode");
}
but value is null.
exist other method to do this?
thanks for you help -
3. Re: Integration with bea weblogic portal
claprun Apr 14, 2008 4:44 PM (in response to emigcrd)I am not familiar with BEA's custom data transfer feature. From the brief look I took at the document, it seems to rely on mechanisms proprietary to BEA and outside of WSRP's scope. It's therefore no surprise that it wouldn't work with a non-BEA producer such as JBoss Portal. I suspect that the extra data is passed as extensions in the WS messages, though I cannot tell for sure that this is the case. You might be able to do something similar using a standard JAX-RPC Handler to achieve the result you desire.
-
4. Re: Integration with bea weblogic portal
emigcrd Apr 16, 2008 10:35 AM (in response to emigcrd)Hi, Thanks for your reply!, a last question, using Jboss portal, in both side(producer and consumer), exists any procedure to send parameters from the consumer to producer, for example an user id?
Thanks a lot for your help! -
5. Re: Integration with bea weblogic portal
dzzy Mar 6, 2009 5:05 AM (in response to emigcrd)"chris.laprun@jboss.com" wrote:
I suspect that the extra data is passed as extensions in the WS messages, though I cannot tell for sure that this is the case. You might be able to do something similar using a standard JAX-RPC Handler to achieve the result you desire.
Hi,
thanks for this hint! you are right, I tested this in a WLP 10.2 consumer - JBoss Portal 2.6.4 producer scenario and managed to pass data using BEA's custom transfer mechanism. Basically, from WLP portlet backing file you can add the object to the request something like:
request.setAttribute(MarkupRequestState.KEY, "TEST");
The WLP consumer will serialize, encode this object (Base64) and add an extension to the SOAP message (getMarkup) with the result, something like:
<v1:extensions>
<ext1:MarkupRequestState xmlns:ext1='urn:bea:wsrp:ext:v1:types'>
<ext1:state>
rO0ABXQAC0dFT1JHRSBURVNU
</ext1:state>
</ext1:MarkupRequestState>
</v1:extensions>
As you mentioned, this value can be extracted from the SOAP message, Base64 decoded and deserialized on the JBoss Portal side using a custom JAX-RPC handler (for the MarkupService).
However, a downside of this approach is that, in case of sending custom objects, you need to have the same version of the class on the producer as well, otherwise the deserialization will fail. Therefore is safer to use primitives and common java objects.
Cheers,
George -
6. Re: Integration with bea weblogic portal
claprun Mar 6, 2009 5:26 AM (in response to emigcrd)Hi George,
Care to document this in our Wiki? Maybe under http://www.jboss.org/community/docs/DOC-12628?
Thanks in advance. -
7. Re: Integration with bea weblogic portal
dzzy Mar 6, 2009 6:35 AM (in response to emigcrd)Done, please review and amend it if case,
Thanks,
George -
8. Re: Integration with bea weblogic portal
claprun Mar 6, 2009 8:55 AM (in response to emigcrd)Why didn't you add it to the main content instead of as a comment? I can do the switch if needed, but you might as well get credits for it... :)
I will review the content later.
Thanks again and keep contributing to Portal! :)