geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: [jira] Created: (GERONIMO-568) Switch system-datasource plan to the derby xa connector
Date Thu, 10 Feb 2005 06:35:15 GMT wrote on 10/02/2005 01:34:22 PM:

> I am working on a patch for switching system-datasource plan to the 
> xa connector as well as moving the timer gbeans to the system datasource 

> plan.
> I am having a problem where the 
> GBean is being invoked before the DerbySystemGBean.
> The JDBCStoreThreadPooledNonTransactionalTimer constructor creates a new 

> instance of JDBCWorkerPersistence, which then calls the execSQL method 
> its superclass that opens a database connection, therefore initialising 
> the embedded derby database.
> One of the problems with this is that the SystemDatabase and derby.log 
> not created under geronimo\var\derby (since the derby.system.home 
> is set by the DerbySystemGBean, which hasn't been started yet.
> Both the timer GBeans have a reference to 
> geronimo.server:J2EEApplication=null,J2EEServer=geronimo,
> JCAResource=org/apache/geronimo/SystemDatabase,
> j2eeType=JCAManagedConnectionFactory,name=SystemDatasource,*
> The SystemDatasource GBean reference is shown as started in the log 
> Derby has been initialised.
> Some options to discuss:
> * Have the Timer GBeans have a reference to the DerbySystem GBean, so 
> aren't started until the DerbySystem GBean has started.  Do you really 
> want a DerbySystem parameter on the constructor of the Timer GBeans? 
> if we do this, it won't stop future GBeans referencing the 
> SystemDatasource when Derby hasn't been initialised.

FYI.. After an IRC discussion with David Jencks and Dain I ended up taking 
this option.


> * Have the SystemDatasource Gbean have a reference to the DerbySystem 
> GBean, so the SystemDatasource is not started until the DerbySystem 
> has started.  Not sure how this can be done and how practical it is.
> * Have a new system-derby-plan.xml file with 
> configId="org/apache/geronimo/DerbySystem" and 
> parentId="org/apache/geronimo/Server" that contains the DerbySystem and 
> DerbyNetwork gbeans .  Change the system-database-plan.xml file to have 
> parentId="org/apache/geronimo/DerbySystem".
> Thanks,
> John

View raw message