cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matthew Cordes <cor...@cs.usm.maine.edu>
Subject Re: init() and destroy() in XSP
Date Fri, 04 May 2001 16:51:06 GMT
You may want to use the Turbine connection pool mechanism instead.

failing that why not something like:

<xsp:logic>

void finalize()
{
	// close db connection
}

</xsp:logic>

-matt

On Fri, May 04, 2001 at 09:16:56AM -0500, Polley Christopher W wrote:
> Hello, all:
> 
> I have an XSP page in which  I would like to do some setup (open JDBC
> connection, create prepared statements) upon instantiation and cleanup
> (close ps's and connection) upon destruction.
> 
> In its previous life as a jsp page, it used jspInit() and jspDestroy(), and
> in a servlet it could use init() and destroy().
> 
> I found XSPPage.init(parameters), which I can override to do the
> initialization, but I am unclear on the tail end of the xsp life cycle.  How
> & when is it destroyed (in Cocoon 1.8.1) ?  How is this type of thing done
> in XSP?
> 
> I suppose that in this case, in which I am only doing JDBC stuff, I could
> try the sql taglib, but am unclear on how that would be done.  Can
> <?cocoon-process type="sql"?> safely be placed ahead of <?cocoon-process
> type="xsp"?>? What would the resultant xsp-servlet look like?
> 
> 
> Thanks,
> Chris
> 
> 
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail: <cocoon-users-help@xml.apache.org>
> 

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.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