cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vadim Gritsenko" <vgritse...@hns.com>
Subject RE: Generators
Date Wed, 25 Jul 2001 14:13:49 GMT
Kevin,

If it's OK to create one session EJB for the lifetime of a generator, do this
in configure() method;
If you need to create/obtain EJB for each request (it may be the case with
session stateful EJB), you can do this in setup() method.

Look at TraxTransformer as it have both of these methods.

Don't forget to implement recycle() to do cleanup between requests.


Vadim

> -----Original Message-----
> From: Kevin O'Neill [mailto:kevin@rocketred.com.au]
> Sent: Wednesday, July 25, 2001 12:44 AM
> To: cocoon-dev@xml.apache.org
> Subject: Generators
> 
> 
> I'm in the process of creating a cocoon 2 generator and I have a couple
> of questions that I don't seem to be able to find the answers to in the
> documentation, if this is just a matter of my eyes being blind to the
> documentation then please tell me to RTFM (with a reference if
> possible).
> 
> I have a generator that calls an EJB Session Bean to do some processing
> and returns me a JDOM document that I then trigger the SAX events from.
> 
> I want to create the reference to the home interface once when the
> object is fist initialised and put into the pool. At the moment (as I
> can't seem to locate the correct method to implement/override) I'm
> initialising the reference on object creation using a parameter from a
> properties file. I'd rather do this in some sort of lifecycle event a
> little like ejbCreate and read the home interface jndi location from a
> parameter in the sitemap file.
> 
> Can anybody point me in the right direction, at some sample code?
> 
> k.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message