Re: how to thread a really computationally intensive page ?
Re: how to thread a really computationally intensive page ?
- Subject: Re: how to thread a really computationally intensive page ?
- From: Lachlan Deck <email@hidden>
- Date: Fri, 28 Mar 2008 06:28:04 +1100
On 28/03/2008, at 5:20 AM, Mike Schrag wrote:
We're looking at various options -- improve the Java code, generate
the reports off-line as static HTML, etc.
I would recommend probably computing the report in a long response,
pushing the results into an intermediate model (not necessarily EO-
based, maybe just POJO's) and then render that in your page. I've
never tried actually RENDERING a page in a long response, but I
suspect it's going to be sort of nasty to get it behaving properly.
You should not be using your long response's context if you are --
you should make a new one (or clone your current context). This
should be roughly equivalent to the docs for ERJavaMail where it
talks about sending component-based emails.
Example:
YourPage backgroundPage =
ERXApplication.instantiatePage( YourPage.class.getName() );
...
WOResponse backgroundResponse = backgroundPage.generateResponse();
String result = response.contentString();
with regards,
--
Lachlan Deck
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden