[Clustering/JBoss] - Re: Accessing singleton MBean from a cluster node
by bstansberry@jboss.com
Yes, that declaration does not include your mbean in a security domain. Have a look at your deploy/jmx-invoker-service.xml file, jboss.jmx:type=adaptor,name=Invoker mbean, section about the invoke operation. You must have this uncommented:
<descriptors>
| <interceptors>
| <interceptor code="org.jboss.jmx.connector.invoker.AuthenticationInterceptor"
| securityDomain="java:/jaas/jmx-console"/>
| </interceptors>
| </descriptors>
That adds server side security to the RMIAdaptor. Your singleton-jmx-adaptor-service.xml doesn't include that, so the service is unsecured.
In 4.0.5, the section above was commented out by default. The fact that you have it uncommented may indicate that someone in your organization wants that service secured (not a bad idea!!). So, you might want to double check before deploying a second, unsecured, version.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4047580#4047580
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4047580
18 years, 11 months
[JBoss Seam] - release connection after lazy init in view
by imario
Hi!
I would like to know if seam handle (if at all) the following problem:
(BTW: I looked at the source, but couldn't find something in this direction)
You load an entity from the database which has a lazy OneToMany within.
Now, when you do not access this list from your action class or any other managed code the session will be disconnected and the underlaying Connection will be passed back to the pool.
Fine!
Now, when your JSF page iterate through the lazy list the Session will be automatically reconnected - a new Connection will be borrowed - to fetch the data from the database.
But now, no one knows that this happened ... no one passes back this Connection to the pool.
The request finished and the Connection is still alive in the Session.
Its not that a big problem, though, it cost some resources especially if you have to wait until the end of a conversation to release the Connection again.
Is there something I oversee? Do you know how to deal with?
One solution I have in mind is a new Hibernate ConnectionReleaseMode - something like: ConnectionReleaseMode.AFTER_TRANSACTION_OTHERWISE_ALWAYS
This means something like: If within a transaction release the connection after it, otherwise release the connection after each statement.
Such a lazy init issued by the view will most likely be outside of any transaction ... so this could work - even if it just works with Hibernate.
Or a way to change the ConnectionReleaseMode during the lifetime of the Session.
Thanks!
Ciao,
Mario
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4047576#4047576
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4047576
18 years, 11 months
[JBossCache] - Cache Lock TimeoutException
by karnivas
I'm using JBoss Cache 1.4.1 SP2 without CacheLoader. I dont want cacheloader to be used.
In my application there are multiple instances which are writing a particular node acquiring a WRITE lock. While this process is performed by a thread, another thread wakes up periodically and tries to read the value in that node, trying to acquire a READ lock. Since there are multiple instances writing on that node this READ lock is prioritized as low which waits for 15000milliseconds(as configured) and TIME-OUT occurs failing to read.
Use Case is Thread A and Thread B writes on Node N continously and Thread C starts to read the value in Node N which fails after waiting leading to a Cache Lock Timeout Exception.
Please advice on preventing this scenario or an alternate approach to read the value in Node N
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4047574#4047574
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4047574
18 years, 11 months