I'm seeing some issues with an AS clustering test that attempts to restart (ie.
deploy, then stop(), then start()) a bunch of services. They tie back to restarting an
instance of UnifiedInvoker and how it interacts the Remoting classes.
Problem occurs when trying to start a UnifiedInvoker that has previously been deployed:
| 2008-06-04 12:33:00,382 DEBUG [org.jboss.invocation.unified.server.UnifiedInvokerHA]
(RMI TCP Connection(31)-127.0.0.1) Starting failed
jboss:service=invoker,type=unifiedha,partitionName=RestartPartition
| java.lang.IllegalArgumentException: Illegal cache capacities
| at org.jboss.util.LRUCachePolicy.<init>(LRUCachePolicy.java:77)
| at org.jboss.remoting.transport.socket.LRUPool.<init>(LRUPool.java:44)
| at
org.jboss.remoting.transport.socket.SocketServerInvoker.start(SocketServerInvoker.java:231)
| at
org.jboss.invocation.unified.server.UnifiedInvoker.startService(UnifiedInvoker.java:140)
| at
org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:376)
| at
org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:322)
| at sun.reflect.GeneratedMethodAccessor65.invoke(Unknown Source)
| at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
Looking into this I've found a couple things:
1) The UnifiedInvoker stopService() method has this:
| public void stopService() throws Exception
| {
| if(serverInvoker != null)
| {
| serverInvoker.stop();
| }
| }
That seems broken. The UnifiedInvoker is handed back a ref to the serverInvoker when it
registers itself with the connector as a ServerInvocationHandler. AFAICT, that
serverInvoker belongs to the Connector, and any other registered handlers will also have a
ref to it. So UnifiedInvoker should not be stopping it; the stop of one handler
shouldn't affect the other handlers.
2) Seems SocketServerInvoker can't be restarted. If you call stop(), it calls
cleanup(), which does this:
maxPoolSize = 0; // so ServerThreads don't reinsert themselves
Thereafter, if you call start(), the max pool size will be less than the min pool size,
leading to the exception shown above.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4155802#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...