activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jai_aXIS <jaib...@gmail.com>
Subject JBoss Messaging Stomp Configuration
Date Mon, 15 Jun 2009 10:39:47 GMT

Hi All, 
I am new to JMS .
      I am uisng Jboss-5.0.0GA which has  Java Messaging 1.4.1. GA . In the
JBoss I have created a new connection factory .
Then from  a stand alone program I try to get connection factory from jboss
and succeeded , but when i try to get connection from the connection factory
I get the error below :

2009 Jun 15 17:18:56 [main] ERROR
org.jboss.remoting.transport.socket.SocketClientInvoker  - Got marshalling
exception, exiting
java.io.IOException:
EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeArray(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteObject(Unknown Source)
	at
EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap.writeObject(ConcurrentHashMap.java:1170)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeWriteObject(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeObject(Unknown Source)
	at
org.jboss.jms.wireformat.SerializedPacket.write(SerializedPacket.java:80)
	at org.jboss.jms.wireformat.JMSWireFormat.write(JMSWireFormat.java:237)
	at
org.jboss.remoting.transport.socket.MicroSocketClientInvoker.versionedWrite(MicroSocketClientInvoker.java:956)
	at
org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:552)
	at
org.jboss.remoting.transport.bisocket.BisocketClientInvoker.transport(BisocketClientInvoker.java:269)
	at
org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:122)
	at org.jboss.remoting.LeasePinger.sendClientPing(LeasePinger.java:283)
	at org.jboss.remoting.LeasePinger.addClient(LeasePinger.java:117)
	at
org.jboss.remoting.MicroRemoteClientInvoker.establishLease(MicroRemoteClientInvoker.java:398)
	at org.jboss.remoting.Client.setupClientLease(Client.java:1504)
	at org.jboss.remoting.Client.connect(Client.java:1404)
	at org.jboss.remoting.Client.connect(Client.java:441)
	at
org.jboss.jms.client.remoting.JMSRemotingConnection$1.run(JMSRemotingConnection.java:319)
	at java.security.AccessController.doPrivileged(Native Method)
	at
org.jboss.jms.client.remoting.JMSRemotingConnection.start(JMSRemotingConnection.java:315)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate.org$jboss$jms$client$delegate$ClientConnectionFactoryDelegate$createConnectionDelegate$aop(ClientConnectionFactoryDelegate.java:154)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.java)
	at
org.jboss.jms.client.container.StateCreationAspect.handleCreateConnectionDelegate(StateCreationAspect.java:83)
	at
org.jboss.aop.advice.org.jboss.jms.client.container.StateCreationAspect0.invoke(StateCreationAspect0.java)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.java)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate.createConnectionDelegate(ClientConnectionFactoryDelegate.java)
	at
org.jboss.jms.client.JBossConnectionFactory.createConnectionInternal(JBossConnectionFactory.java:205)
	at
org.jboss.jms.client.JBossConnectionFactory.createConnection(JBossConnectionFactory.java:87)
	at
org.jboss.jms.client.JBossConnectionFactory.createConnection(JBossConnectionFactory.java:82)
	at com.jms.test.SimpleTestClient.main(SimpleTestClient.java:22)
2009 Jun 15 17:18:56 [main] WARN  org.jboss.remoting.LeasePinger  -
LeasePinger[SocketClientInvoker[1c80b01,
bisocket://127.0.0.1:4457](aaw19-i6j7nu-fvyz3zgo-1-fvyz3zse-6)] failed to
ping to server: Failed to communicate.  Problem during
marshalling/unmarshalling; nested exception is: 
	java.io.IOException:
EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment
2009 Jun 15 17:19:06 [Timer-0] ERROR
org.jboss.remoting.transport.socket.SocketClientInvoker  - Got marshalling
exception, exiting
java.io.IOException:
EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeArray(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteObject(Unknown Source)
	at
EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap.writeObject(ConcurrentHashMap.java:1170)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeWriteObject(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeObject(Unknown Source)
	at
org.jboss.jms.wireformat.SerializedPacket.write(SerializedPacket.java:80)
	at org.jboss.jms.wireformat.JMSWireFormat.write(JMSWireFormat.java:237)
	at
org.jboss.remoting.transport.socket.MicroSocketClientInvoker.versionedWrite(MicroSocketClientInvoker.java:956)
	at
org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:552)
	at
org.jboss.remoting.transport.bisocket.BisocketClientInvoker.transport(BisocketClientInvoker.java:269)
	at
org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:122)
	at org.jboss.remoting.LeasePinger.sendClientPing(LeasePinger.java:283)
	at org.jboss.remoting.LeasePinger.access$100(LeasePinger.java:20)
	at org.jboss.remoting.LeasePinger$LeaseTimerTask.run(LeasePinger.java:300)
	at java.util.TimerThread.mainLoop(Unknown Source)
	at java.util.TimerThread.run(Unknown Source)
2009 Jun 15 17:19:06 [Timer-0] WARN  org.jboss.remoting.LeasePinger  -
LeasePinger[SocketClientInvoker[1c80b01,
bisocket://127.0.0.1:4457](aaw19-i6j7nu-fvyz3zgo-1-fvyz3zse-6)] failed to
ping to server: Failed to communicate.  Problem during
marshalling/unmarshalling; nested exception is: 
	java.io.IOException:
EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment
org.jboss.jms.exception.MessagingNetworkFailureException
	at
org.jboss.jms.client.delegate.DelegateSupport.handleThrowable(DelegateSupport.java:245)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate.org$jboss$jms$client$delegate$ClientConnectionFactoryDelegate$createConnectionDelegate$aop(ClientConnectionFactoryDelegate.java:187)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.java)
	at
org.jboss.jms.client.container.StateCreationAspect.handleCreateConnectionDelegate(StateCreationAspect.java:83)
	at
org.jboss.aop.advice.org.jboss.jms.client.container.StateCreationAspect0.invoke(StateCreationAspect0.java)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_N3019492359065420858.java)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate.createConnectionDelegate(ClientConnectionFactoryDelegate.java)
	at
org.jboss.jms.client.JBossConnectionFactory.createConnectionInternal(JBossConnectionFactory.java:205)
	at
org.jboss.jms.client.JBossConnectionFactory.createConnection(JBossConnectionFactory.java:87)
	at
org.jboss.jms.client.JBossConnectionFactory.createConnection(JBossConnectionFactory.java:82)
	at com.jms.test.SimpleTestClient.main(SimpleTestClient.java:22)
Caused by: org.jboss.remoting.ConnectionFailedException: Timed out trying to
create control socket
	at
org.jboss.remoting.transport.bisocket.BisocketClientInvoker.handleConnect(BisocketClientInvoker.java:273)
	at
org.jboss.remoting.MicroRemoteClientInvoker.connect(MicroRemoteClientInvoker.java:294)
	at org.jboss.remoting.Client.connect(Client.java:1596)
	at org.jboss.remoting.Client.connect(Client.java:498)
	at
org.jboss.remoting.callback.ServerInvokerCallbackHandler.connect(ServerInvokerCallbackHandler.java:166)
	at
org.jboss.remoting.ServerInvoker.getCallbackHandler(ServerInvoker.java:2047)
	at
org.jboss.remoting.ServerInvoker.handleInternalInvocation(ServerInvoker.java:1663)
	at
org.jboss.remoting.transport.bisocket.BisocketServerInvoker.handleInternalInvocation(BisocketServerInvoker.java:863)
	at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:895)
	at
org.jboss.remoting.transport.socket.ServerThread.completeInvocation(ServerThread.java:742)
	at
org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:695)
	at
org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:549)
	at
org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:230)
	at
org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:163)
	at org.jboss.remoting.Client.invoke(Client.java:1513)
	at org.jboss.remoting.Client.addCallbackListener(Client.java:1582)
	at org.jboss.remoting.Client.addListener(Client.java:885)
	at
org.jboss.jms.client.remoting.JMSRemotingConnection.addInvokerCallbackHandler(JMSRemotingConnection.java:230)
	at
org.jboss.jms.client.remoting.JMSRemotingConnection.start(JMSRemotingConnection.java:340)
	at
org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate.org$jboss$jms$client$delegate$ClientConnectionFactoryDelegate$createConnectionDelegate$aop(ClientConnectionFactoryDelegate.java:154)
	... 9 more

Kindly help me to solve the issue shortly .

Thanks in Advance .

Regards 
Jai





Ovidiu Feodorov-2 wrote:
> 
> Tim Fox wrote:
>> Ram Venkataraman wrote:t 
>>> I talked to Ovididu about a month or so ago when Messaging went GA 
>>> and spoke about integration  JBM into 4.x and I clearly remember 
>>> asking about remoting. He did not raise any red flags, in fact we 
>>> spoke of it being compatible.
>>
>> I don't have any explanations why he would say that - we have been 
>> dependent on remoting 2.2 for some time now.
> 
> There is misunderstanding then. I could not have said JBM is compatible 
> with Remoting currently used by JBM 4.x because it's clearly not, and 
> this is a well know problem. I probably said there's no problem if we go 
> scoped, which cannot be avoided for 4.2.0, but we should align our 
> dependencies in 4.2.1. I also remember that this was still an open 
> discussion.
> 
> _______________________________________________
> jboss-development mailing list
> jboss-development@lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jboss-development
> 
> 








Johann Ungerer wrote:
> 
> Hi Jim,
> 
> Thank you for the reply, its gotten me quite a bit further.
> 
> I am currently experiencing a connectivity issue from stomp to JBM, so I'm
> posting the startup file that I'm using for stomp in hopes that I'm doing
> something silly. I am able to connect to the JBM via code on the provider
> url i'm using, so the url "should" be right.
> 
> If anyone sees anything obviously wrong, it would be greatly appreciated.
> 
> --
> 
> set uri=stomp://localhost:61613
> set providerurl=tcp://192.168.0.53:1099
> 
> set
> classes=stompconnect-1.0.jar;commons-logging-1.1.jar;jboss-messaging.jar;jnpserver.jar;jboss-common.jar
> set
> properties=-Djava.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
> set properties=%properties% -Djava.naming.provider.url=%providerurl%
> set properties=%properties% -Djava.naming.security.principal=guest
> set properties=%properties% -Djava.naming.security.credentials=guest
> 
> echo Connecting to %providerurl%
> 
> java %properties% -classpath %classes% org.codehaus.stomp.jms.Main %uri%
> ConnectionFactory
> 
> --
> 
> TIA,
> j/
> 
> -----Original Message-----
> From: Jim Gomes [mailto:e.semog@gmail.com]
> Sent: 26 February 2008 17:15
> To: users@activemq.apache.org
> Subject: Re: JBoss Messaging Stomp Configuration
> 
> Hi Johann,
> 
> It can take a little bit to figure out STOMPConnect, but once you have it
> configured, it's very low maintenance.  I had to do something very similar
> to what you are attempting to do.  I needed to be able to connect to TIBCO
> EMS using the Apache NMS client (this was before direct support was added
> for TIBCO).  I used STOMPConnect to be my bridging mechanism.  I ran the
> TIBCO server on one machine, the STOMPConnect on a second machine, and my
> NMS client on a third machine.  The STOMPConnect portion could actually be
> run on any machine.  I created a simple batch file that would run it on a
> Windows box.  Essentially, the connection works as follows: The NMS client
> connects to STOMPConnect on port 61613.  STOMPConnect translates the STOMP
> messages and forwards them as native JMS messages by connecting to TIBCO
> on
> port 7222.  Here's the batch file.  Hopefully, you can take this and
> customize it to use the JBOSS Messaging class factory and JMS clients.  No
> custom Java coding required.
> 
> ------------- 8< ----- SNIP ---- 8< ---------
> 
> @echo off
> cls
> setlocal
> title STOMPConnect:61613 - jbosssrv
> 
> set uri=stomp://localhost:61613
> set providerurl=tcp://jbosssrv:7222
> 
> set
> classes=stompconnect-1.0.jar;commons-logging-1.1.jar;jms.jar;tibjms.jar
> set properties=-
> Djava.naming.factory.initial=com.tibco.tibjms.naming.TibjmsInitialContextFactory
> set properties=%properties% -Djava.naming.provider.url=%providerurl%
> set properties=%properties% -Djava.naming.security.principal=guest
> set properties=%properties% -Djava.naming.security.credentials=guest
> 
> echo Connecting to %providerurl%
> 
> java %properties% -classpath %classes% org.codehaus.stomp.jms.Main %uri%
> GenericConnectionFactory
> 
> ------------- 8< ----- SNIP ---- 8< ---------
> 
> You should replace the
> com.tibco.tibjms.naming.tibjmsInitialContextFactorywith the
> corresponding JBOSS Messaging context factory.  The
> tibjms.jar file will be replaced with the JBOSS Messaging client jar file.
> 
> Hope this helps you get further.
> 
> - Jim
> 
> On Mon, Feb 25, 2008 at 8:54 PM, Johann Ungerer
> <JohannU@pyrogenesis.co.za>
> wrote:
> 
>> Hi Jim,
>>
>> Thanks for the reply. I've pretty much gotten that far. The trick I'm not
>> able to sort out on my own is actually configuring STOMPConnect to bridge
>> to
>> JBM. The documentation is a little patchy, I'm not sure which configs to
>> touch, would I run STOMPConnect as a stand-alone product, or can I use
>> the
>> "Injection Dependency" mentioned in the docs? I'm comfortable that I'll
>> sort
>> the client out, it's the server and bridge config that I'm not too sure
>> of.
>>
>> TIA,
>> j/
>>
>> -----Original Message-----
>> From: Jim Gomes [mailto:e.semog@gmail.com]
>> Sent: 25 February 2008 23:50
>> To: users@activemq.apache.org
>> Subject: Re: JBoss Messaging Stomp Configuration
>>
>> Hi Johann,
>>
>> To get the NMS client to talk the stomp protocol, you will need to set
>> your
>> connection string in one of the following formats.  Either is acceptable,
>> so
>> it's up to you which one you prefer.
>>
>> activemq:tcp://jbosssrvr:61613?transport.wireformat=stomp
>>      OR
>> activemq:stomp://jbosssrvr:61613
>>
>> The port 61613 is the port that ActiveMQ listens on for STOMP protocol
>> messages.  You will need to set the correct port entry for the JBOSS
>> Messaging broker.  If JBOSS Messaging does not support STOMP natively,
>> you
>> may need to use the STOMPConnect product to bridge between your client
>> and
>> JBOSS Messaging.
>>
>> Good Luck,
>> Jim
>>
>> On Mon, Feb 25, 2008 at 1:06 PM, Johann Ungerer
>> <JohannU@pyrogenesis.co.za
>> >
>> wrote:
>>
>> > Hi All,
>> >
>> > I'm totally new to the entire JMS environment, but am trying to connect
>> a
>> > .NET Client to a JBOSS Messaging implementation. Thus far I've tried
>> with
>> > the NMS client, using an OpenWire connector, but I figure this will
>> never
>> > work.
>> >
>> > It's been recommended that I use a STOMP connector, but can't quite get
>> > either my JBOSS Server configured to listen on STOMP, or get STOMP to
>> talk
>> > to the JBOSS.
>> >
>> > Has anyone tried to make a C# client talk to JBOSS and if so, please
>> > provide some guidance on what I need to do in order to achieve this.
>> >
>> > TIA,
>> > j/
>> >
>> >
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/JBoss-Messaging-Stomp-Configuration-tp15677725p24032215.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message