On Oct 27, 2009, at 7:32 AM, Francesco Iadanza wrote:
Hi all,
a couple of questions as I'm doing some tests with OpenEJB:
- is there a way to get statistics about the pool size of ejb (SB /
MDB) and
of JMS queues used by OpenEJB?
Statistics is one feature we are lacking. There has been a lot of
interest in this lately, though, so there is definitely going to be
some activity around this at some point.
- how can I set a timeout on the connection I use to connect
remotely to SB
exposed through Tomcat?
In Tomcat, we piggy back on their http connector, so any server-side
timeout functionality they have should work. I do not know if they
actually have any though. They *should* have something that controls
the http Keep-Alive duration, but I don't know first hand.
On the client side for http we use the built in vm support
(java.net.HttpURLConnection). We don't have anything setup for
configuring that in the 3.1.2 release, but I just added something for
you for next release.
https://issues.apache.org/jira/browse/OPENEJB-1100
Grab this class and include it right in your client code (change the
package of course):
http://svn.apache.org/repos/asf/openejb/trunk/openejb3/server/openejb-client/src/main/java/org/apache/openejb/client/HttpConnectionFactory.java
Then you can install it by calling this method in the client vm:
HttpConnectionFactory customHttpFactory = new
HttpConnectionFactory();
org.apache.openejb.client.ConnectionManager.registerFactory("http",
customHttpFactory);
org.apache.openejb.client.ConnectionManager.registerFactory("https",
customHttpFactory);
Hope that helps!
-David