[JBoss Cache] - JBoss cache / concurrent creation event
by Brett Cave
Brett Cave [http://community.jboss.org/people/brettcave] created the discussion
"JBoss cache / concurrent creation event"
To view the discussion, visit: http://community.jboss.org/message/564341#564341
--------------------------------------------------------------
We have been having an issue with this for quite some time, and I am battling to understand the cause of the issue, hoping someone could help explain and work a solution for this.
While using a web application an exception occassionally occurs:
2010-09-30 14:12:27,901 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/]] (ajp-0.0.0.0-8009-2) Exception while dispatching incoming RPC call
com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract com.mycompany.web.common.client.model.rank.RankResponse com.mycompany.web.common.client.rpc.Ranking
Service.rank(java.lang.String,int,com.mycompany.web.common.client.model.rank.RankRequestProperties,java.util.Map,java.util.Map,java.util.Map,java.util.Map)' threw an unexpected exception: javax.ejb.EJBTransactionRolledbackException: Transaction rolled back
Just prior to that in the log, the following is seen:
2010-09-30 14:12:27,895 WARN [org.jboss.cache.interceptors.OptimisticTxInterceptor] (ajp-0.0.0.0-8009-2) Caught exception, will now set transaction to roll back
org.jboss.cache.optimistic.DataVersioningException: Transaction attempted to create /adonis/org/hibernate/cache/StandardQueryCache/QUERY/sql: select <QUERY DETAILS>; max rows: 2 anew. It has already been created since this transaction started, by another (possibly remote) transaction.
We have a concurrent creation event.
at org.jboss.cache.interceptors.OptimisticValidatorInterceptor.visitOptimisticPrepareCommand(OptimisticValidatorInterceptor.java:116)
....
2010-09-30 14:12:27,897 WARN [com.arjuna.ats.arjuna.logging.arjLoggerI18N] (ajp-0.0.0.0-8009-2) [com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator_2] TwoPhaseCoordinator.beforeCompletion - failed for com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple@493ee8c1
org.jboss.cache.optimistic.DataVersioningException: Transaction attempted to create /adonis/org/hibernate/cache/StandardQueryCache/QUERY/sql: select <QUERY DETAILS>; max rows: 2 anew. It has already been created since this transaction started, by another (possibly remote) transaction.
We have a concurrent creation event.
at org.jboss.cache.interceptors.OptimisticValidatorInterceptor.visitOptimisticPrepareCommand(OptimisticValidatorInterceptor.java:116)
Environment:
The application is deployed in an ear with an ejb and war component.
The ejb has a persistence unit, which uses an XA jta-datasource and 3 entity jar-files defined (that are deployed independantly)
Another application is deployed that the primary application depends on, an EAR with ejb and persistence. The persistence unit references a different XA datasource and references 1 of the 3 jar-files as above.
The issue might be caused by having 2 persistence contexts being applied to a single entity, but not entirely sure on this though
I have tried adjusting the transaction manger's configuration to allowMultipleLastResources = true (before we switched to XA datasources, this was necessary with tx datasources and this environment), but the error occurs with this enabled or disabled.
I am not sure whether this is a jboss cache issue, hibernate or transaction manager issue.
how could I avoid this issue? (the exception occurs irregularly, it's difficult to reproduce).
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/564341#564341]
Start a new discussion in JBoss Cache at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 2 months
[JBoss Remoting] - [Urgent] Random org.jboss.remoting.CannotConnectException
by Alfonso Olias
Alfonso Olias [http://community.jboss.org/people/aolias] created the discussion
"[Urgent] Random org.jboss.remoting.CannotConnectException"
To view the discussion, visit: http://community.jboss.org/message/563013#563013
--------------------------------------------------------------
Hi
We are running a Client/Server Application were there is a server receiving incoming remote requests. Everything works ok until we double the number of clients (workers).
Then we start having this exception stack trace in some workers when they call remotely the server (master). We have implemented a retry mechanism that catches this error and tries to send the data 10 times, with random delays and also re-starting the transport. But none of the failover mechanisms work.
org.jboss.remoting.CannotConnectException: Can not get connection to server. Problem establishing socket connection for InvokerLocator [socket://xxxxxxxxxxxxx.xxxxx.xxx:9003/?serializationtype=jboss]
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:831)
at org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:167)
at org.jboss.remoting.Client.invoke(Client.java:2034)
at org.jboss.remoting.Client.invoke(Client.java:877)
at org.jboss.remoting.Client.invoke(Client.java:865)
at org.jboss.remoting.transporter.TransporterClient.invoke(TransporterClient.java:321)
at $Proxy15.isReady(Unknown Source)
Caused by: java.net.ConnectException: Connection refused
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:519)
at org.jboss.remoting.transport.socket.SocketClientInvoker.connect(SocketClientInvoker.java:293)
at org.jboss.remoting.transport.socket.SocketClientInvoker.createSocket(SocketClientInvoker.java:210)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.getConnection(MicroSocketClientInvoker.java:1165)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:816)
... 10 more
We are using the following libraries
<dependency org="org.jboss.remoting" name="jboss-remoting" rev="2.5.3.SP1" />
<dependency org="jboss" name="jboss-serialization" rev="1.0.3.GA" />
<dependency org="org.jboss" name="jboss-common-core" rev="2.2.14.GA">
<exclude module="commons-httpclient"/>
</dependency>
<dependency org="jboss" name="jboss-logging-spi" rev="2.0.3.GA" />
<dependency org="jboss" name="jboss-concurrent" rev="1.0" />
<dependency org="jboss" name="jboss-jmx" rev="4.0.4" />
<dependency org="trove" name="trove" rev="2.0.4" />
The way we start the server is like this
this.transporter = TransporterServer.createTransporterServer("socket://"+this.hostname + ":"+ port + "/?serializationtype=jboss", this, this.serverName);
And at the client side
org.jboss.remoting.CannotConnectException: Can not get connection to server. Problem establishing socket connection for InvokerLocator [socket://gaials48.n1data.lan:9003/?serializationtype=jboss]
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:831)
at org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:167)
at org.jboss.remoting.Client.invoke(Client.java:2034)
at org.jboss.remoting.Client.invoke(Client.java:877)
at org.jboss.remoting.Client.invoke(Client.java:865)
at org.jboss.remoting.transporter.TransporterClient.invoke(TransporterClient.java:321)
at $Proxy15.isReady(Unknown Source)
at gaia.cu3.agis.algo.gis.DistributedUpdateCalculatorServerProxy.send2Server(DistributedUpdateCalculatorServerProxy.java:255)
at gaia.cu3.agis.algo.gis.attitude.DistributedAttitudeUpdateCalculatorServerProxy.access$100(DistributedAttitudeUpdateCalculatorServerProxy.java:73)
at gaia.cu3.agis.algo.gis.attitude.DistributedAttitudeUpdateCalculatorServerProxy$1.run(DistributedAttitudeUpdateCalculatorServerProxy.java:242)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.net.ConnectException: Connection refused
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:519)
at org.jboss.remoting.transport.socket.SocketClientInvoker.connect(SocketClientInvoker.java:293)
at org.jboss.remoting.transport.socket.SocketClientInvoker.createSocket(SocketClientInvoker.java:210)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.getConnection(MicroSocketClientInvoker.java:1165)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:816)
... 10 more
updateServer = (T) TransporterClient.createTransporterClient("socket://"+hostName+":" + port + "/?serializationtype=jboss", this.myClass);
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/563013#563013]
Start a new discussion in JBoss Remoting at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 2 months
[JBoss Tools] - Re: Deployment from Eclipse don't deploy?
by Alla Winter
Alla Winter [http://community.jboss.org/people/allawin] created the discussion
"Re: Deployment from Eclipse don't deploy?"
To view the discussion, visit: http://community.jboss.org/message/564163#564163
--------------------------------------------------------------
I had encountered the same problem , I went through your sugestions and I was able to execute my index.html. But now I am having a different problem, I do not know how to instruct JBOSS where my library with the jars files ( I am trying to integrade JBOSS with SPRING). I do have lib directory under WEB-INF, but I do not think that JBOSS sees it. When I select eclipse option RUN AS->RUN CONFIGURATION, JBOSS entry is not present in there, like TOMCAT for example. If that entry would have been present in there, then I would be able to set the class path. I am new to JBOSS, so it is kind of chalenging for me to figure out on my own how to configure it since it is not set up in a standard way like other servers.
I would appreciate if you help me out how to configure JBOSS to see the SPRING jar files.
thanks a lot.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/564163#564163]
Start a new discussion in JBoss Tools at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 2 months
[JBoss Messaging] - JBoss Messaging 1.4.3 GA stuck?
by Nikos Massios
Nikos Massios [http://community.jboss.org/people/massios] created the discussion
"JBoss Messaging 1.4.3 GA stuck?"
To view the discussion, visit: http://community.jboss.org/message/564303#564303
--------------------------------------------------------------
Hello,
We are having a problem in our uat environment.
We are using
JBoss 5.1 GA, JBoss Messaging 1.4.3 GA (comes with JBoss 5.1GA)
JBoss ESB 4.6
Windows x64 with the 64 bit version of the jvm (1.6)
We have a strange condition where sometimes a message will be placed in the queue by the esb but a JMS client local to the machine (so no firewall in between) will not be able to read the message placed in the queue. We do not see any exceptions in the server log (it is in DEBUG for the org.jboss classes). New messages placed in the queue will be readable by the the client until another message will be placed in the queue that has this kind of property (that makes it not readable) and this continues like that.
Has anybody else had similar problems?
Nikos
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/564303#564303]
Start a new discussion in JBoss Messaging at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 2 months
[JBoss Remoting] - Re: SocketClientInvoker - NEW ClientSocketWrapper Errors
by Ron Sigal
Ron Sigal [http://community.jboss.org/people/ron.sigal%40jboss.com] created the discussion
"Re: SocketClientInvoker - NEW ClientSocketWrapper Errors"
To view the discussion, visit: http://community.jboss.org/message/564183#564183
--------------------------------------------------------------
Hi Vidhya,
Re: "The odd thing being the IP address (X) on the thread name is different from the bisocket's one...(Is this OK ? Is this because that worker thread was created for an ip X and then went back to the pool and is being reused for another ip Y? )"
When a ServerThread is retrieved from the pool its name is reset to reflect its new socket. The address in ServerThread.toString() is generated by a call to Socket.getInetAddress().getHostAddress() and the address in ClientSocketWrapper is generated in Socket.toString() by a call to java.net.SocketImp.getInetAddress(). I would expect them to refer to the same host, but, possibly, look a little different. Are they actually referring to distinct hosts?
Both of your stacktraces indicate that something has happened to a client. In the first one, JBossMessaging is trying to send some messages to a consumer and the connection has been closed on the client side. The second stacktrace suggests that, in response to the broken connection, Remoting is trying to create a new connection by writing a CREATE_ORDINARY_SOCKET message on the bisocket control connection (for the details see Section 5.4.17 "Bisocket transport" of the Remoting Guide at http://docs.jboss.org/jbossremoting/2.5.3.SP1/html/ http://docs.jboss.org/jbossremoting/2.5.3.SP1/html/). So, I don't know what the problem is, but you should check out what's going on at the client side.
-Ron
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/564183#564183]
Start a new discussion in JBoss Remoting at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 2 months