We've got an app that makes several queries. Intermittantly, it will fail with an error like:
Unable to obtain lock in 60 seconds: org.jboss.resource.adapter.jdbc.local.LocalManagedConnection@1478101
|
I've been able to track this down to:
BaseWrapperManagedConnectionFactory.useTryLock, which defaults to 60, thus the 60 seconds.
However, there doesn't seem to be any way to set this value in the datasource configuration. The dtd for datasources talks about use-try-lock, but it never appears to be getting set (based on debugging)
How do I configure this value? Moreover, why do I need to (i.e. why would I be getting the error in the first place).
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241272#4241272
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241272
PeterJ, thanks a lot!
This is correct solution.
That way I am also able to use
<load-on-startup>1</load-on-startup>
in web.xml
I had tried adding similar construction before (but as injection into servlet), and it did not work:
| @Depends({"-the mbean name goes here-"})
| public class JMSEventListenerServlet extends HttpServlet {
| ..
|
I did get error about not bound JNDI name (that was JMS resource, actually)
Could you explain please what is the difference between your working solution and that one, which is not?
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241264#4241264
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241264
Remote clients do not have access to JNDI entries in the java: namespace, thus any items (such as data sources) that a remote client needs must be in the global namespace. Of course, once the name is moved out of the java: namespace, then even local clients need to look the name up in the global namespace.
(Please use the 'code' tag when posting XML text - otherwise the browser thinks the tags are html and tries to render them, making the post difficult to read.)
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241252#4241252
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241252