We have a connection pool (xa-datasource), accessed through JNDI, specified in 
[JBoss]\server\default\deploy\oracle-xa-ds.xml, and we're having difficulty 
accessing it during servlet (filter) init.  Our filters (in their init methods) 
access other global objects that are themselves initialized and require the 
data connection.  

>From the log file it's clear that the connection pool service starts after the 
>filters initialize, which is too late, because the filters and other objects 
>have already failed to initialize properly.  Of course, if we add a try block 
>surrounding the context.lookup("java:[ourConnectionPool]") and subsequent 
>catch block containing the hard-coded connection process, everything works 
>fine.  It's an ok work-around for now, but there ought to be an elegant way of 
>doing this.

We've tried moving the xml code to other files, namely jboss-service.xml and 
server.xml, but that doesn't seem to change anything.

Can anyone give me an answer as to whether this works as it does by design or 
whether I'm just not setting it up properly?  Is there any way to ensure that 
the connection pool is set up before the filters start their initialization?

TIA
Paul T.



View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3999657#3999657

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3999657
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to