views:

18

answers:

1

I'm trying to get rendered WCM content in an Asych bean (which implements the Work interface). I can create a Workspace using a username and password, but I don't see an API to create a RenderingContext without passing either a portlet request/response or a servlet request/response pair).

Is there any way I can either 1) Create a RenderingContext without a portlet or servlet request and response, or 2) Render WCM content in an asynchronous work bean some other way?

I'm using IBM Web Content Management, WebSphere Portal and WAS versions all at versions 6.1.x.

+2  A: 

According to the API you can't get a RenderingContext without a ServletRequest or PortletRequest. You might need to make an http request back to the WCM servlet or write a web service that use the WCM API.

chrisr
We're currently doing it that way (making an http request to WCM servlet), but we're facing performance issues when doing so (the http call blocks the thread while it gets the content, as well as uses up a connection). It didn't seem like the most efficient way of doing things; that's why I was investigating if there's a way to do it using the API.
hexium