cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vadim Gritsenko" <vadim.gritse...@verizon.net>
Subject RE: Initialization and background threads
Date Thu, 01 Aug 2002 23:35:52 GMT
> From: Justin Fagnani-Bell [mailto:justin@paraliansoftware.com]
> 
> Hi List,
> 
>    The web app I'm developing with Cocoon needs to initialize a few
> things at startup and perform some tasks in the background like
database
> cleanup, checking for mail, automating site updates. Is there a good
way
> to integrate this with Cocoon?
> 
> For the initialization, I'm reading in an XML file to create resources
> available to my Cocoon components. I'd like to use the same parser
> configured for Cocoon. I've though about adding something like this to
> cocoon.xconf:
> 
> <init-param>
>    <param-name>load-class</param-name>
>    <param-value>MyClass</param-value>
> </init-param>
> 
> and using a static initializer to perform the initialization and start
> the background thread, but I don't see how I could get access to the
> Cocoon environment. I'd like to be able to access components and
> resources through Cocoon.

It's not first time this question was asked, and here is the usual
answer: follow implementation of HSQLDB built-in server in
hsqldb/Server.java and in hsqldb/ServerImpl.java. See how it is declared
in cocoon.roles and cocoon.xconf.


Vadim


> Thanks,
>    Justin


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>


Mime
View raw message