[Clustering/JBoss] - cluster invocation failed under heavy load and rejoin one no
by targit
hi,
following szenario produces under heavy load exceptions:
Using JDK6, JBoss AS 4.2.3GA
Start 2 instances with:
./run.sh -c all -b10.3.60.60 -DBind.address=10.3.60.60
and
./run.sh -c all -b10.3.60.57 -Dbind.address=10.3.60.57
after starting. Cluster will be formed !
Then start stress client with following code:
try {
Properties p = new Properties();
p.put(Context.INITIAL_CONTEXT_FACTORY,
"org.jnp.interfaces.NamingContextFactory");
p.put(Context.URL_PKG_PREFIXES, "jboss.naming:org.jnp.interfaces");
p.put(Context.PROVIDER_URL, "10.3.60.57:1100,10.3.60.60:1100");
InitialContext ctx = new InitialContext(p);
while (true) {
try {
HelloWorldEJBRemote ejb = (HelloWorldEJBRemote) ctx.lookup("HelloWorldEJB");
System.out.println(ejb.helloWorld("hello"));
} catch (Exception ex) {
ex.printStackTrace();
}
}
} catch (Exception ex) {
ex.printStackTrace();
}
then all will be ok. Shutdown one server. Test client is running and produce no exceptions. I start the stopped server to rejoin the cluster. but test-client produce following exceptions:
java.lang.RuntimeException: cluster invocation failed, last exception was:
at org.jboss.aspects.remoting.ClusterChooserInterceptor.invoke(ClusterChooserInterceptor.java:166)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.aspects.tx.ClientTxPropagationInterceptor.invoke(ClientTxPropagationInterceptor.java:67)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.aspects.security.SecurityClientInterceptor.invoke(SecurityClientInterceptor.java:53)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.ejb3.remoting.ClusteredIsLocalInterceptor.invoke(ClusteredIsLocalInterceptor.java:55)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.ejb3.stateless.StatelessClusteredProxy.invoke(StatelessClusteredProxy.java:112)
at $Proxy1.helloWorld(Unknown Source)
at Main.main(Main.java:26)
Caused by: org.jboss.remoting.CannotConnectException: Can not get connection to server. Problem establishing socket connection for InvokerLocator [socket://10.3.60.60:3873/]
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:579)
at org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:122)
at org.jboss.remoting.Client.invoke(Client.java:1634)
at org.jboss.remoting.Client.invoke(Client.java:548)
at org.jboss.aspects.remoting.InvokeRemoteInterceptor.invoke(InvokeRemoteInterceptor.java:62)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.aspects.remoting.ClusterChooserInterceptor.invoke(ClusterChooserInterceptor.java:77)
... 10 more
Caused by: java.net.BindException: Address already in use: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at java.net.Socket.connect(Socket.java:518)
at org.jboss.remoting.transport.socket.SocketClientInvoker.createSocket(SocketClientInvoker.java:192)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.getConnection(MicroSocketClientInvoker.java:827)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:569)
at org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:122)
at org.jboss.remoting.Client.invoke(Client.java:1634)
at org.jboss.remoting.Client.invoke(Client.java:548)
at org.jboss.aspects.remoting.InvokeRemoteInterceptor.invoke(InvokeRemoteInterceptor.java:62)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.aspects.remoting.ClusterChooserInterceptor.invoke(ClusterChooserInterceptor.java:77)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.aspects.tx.ClientTxPropagationInterceptor.invoke(ClientTxPropagationInterceptor.java:67)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.aspects.security.SecurityClientInterceptor.invoke(SecurityClientInterceptor.java:53)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.ejb3.remoting.ClusteredIsLocalInterceptor.invoke(ClusteredIsLocalInterceptor.java:55)
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
at org.jboss.ejb3.stateless.StatelessClusteredProxy.invoke(StatelessClusteredProxy.java:112)
at $Proxy1.helloWorld(Unknown Source)
at Main.main(Main.java:26)
at org.jboss.aspects.remoting.InvokeRemoteInterceptor.invoke(InvokeRemoteInterceptor.java:74)
... 12 more
whats wrong ? or its a design error ?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4187322#4187322
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4187322
17 years, 5 months
[Installation, Configuration & DEPLOYMENT] - Re: Running Jboss As Windows Service
by jaikiran
"jaikiran" wrote : going by the JIRA comments (readme), it looks like only the 32 bit version is by default packaged with the JBoss-AS
|
The readme part in the JIRA actually confused me:
anonymous wrote : With a note on the header of README-service.txt:
| ---------------------------------------------------------------------
| README-service.txt, service.bat and jbosssvc.exe are part of the
| 'JBoss Native Win32' distribution. They are included here to allow
| JBossAS run as a Service in Windows environments.
|
| The version used is 'JBoss Native 2.0.6 Win32'
However, it looks like care has been taken to make the service work on even 64 bit systems :-) A comment from the same JIRA:
anonymous wrote :
| 4. Allow paralell native installations and use the one corresponding to the JVM used and host CPU. If we are on the 64-bit system detect if the JVM is 64 or 32 bit (reported from java -version) and construct the path to the native according to that. This allows a single native binary for windows that has multiple CPU builds.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4187318#4187318
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4187318
17 years, 5 months
[Persistence, JBoss/CMP, Hibernate, Database] - Help on join query
by icordoba
In my system I have the following classes:
File
Category
User
Role
Permission
Files belong to one or more categories
Users can have one or more roles
A permission can refer to a file or a category of files (never both)
A permission can refer to a user or role (and so affecting all users in that role) (never both user and role)
Permission has 3 booleans, read, write, edit
I need a HQL query to get all files accessible by a user. It should return all files that have a read permission for that user or any of the roles assigned to the user and all files belonging to a category that has a read permission to that user or any of the roles assigned to the user.
I am pretty new to Hibernate/JBoss and I've been examining example queries but can't find anyone similar to this one... any directions/help?
thanks,
Ignacio
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4187315#4187315
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4187315
17 years, 5 months