Great stuff! I've added this page to the STOMP wiki http://docs.codehaus.org/display/STOMP/StompConnect+with+JBoss
On 10/03/2008, Johann Ungerer <[EMAIL PROTECTED]> wrote: > Hi all, > > After some fun and games, we managed to configure STOMPConnect to work with > JBOSS. Thought I'd share our experience with everyone. > > ---------------- > > > @echo off > cls > setlocal > title STOMPConnect:61613 - jbosssrv > > > set uri=tcp://169.254.109.194:61613 > set providerurl=jnp://localhost:1099 > > set > classes=stompconnect-1.0.jar;commons-logging-1.1.jar;jboss-messaging.jar;jnpserver.jar;jboss-common.jar;jboss-messaging-client.jar;jbossall-client.jar;jboss-remoting.jar;javassist.jar;jboss-j2ee.jar;trove.jar;jboss-aop-jdk50.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 > > > -------------- > > Thanks to the list for the help in getting me on the right road. > > Regards, > > j/ > > > -----Original Message----- > From: Johann Ungerer [mailto:[EMAIL PROTECTED] > Sent: 28 February 2008 23:11 > To: users@activemq.apache.org > > Subject: RE: JBoss Messaging Stomp Configuration > > 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:[EMAIL PROTECTED] > 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 <[EMAIL PROTECTED]> > 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:[EMAIL PROTECTED] > > 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 <[EMAIL PROTECTED] > > > > > 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/ > > > > > > > > > -- James ------- http://macstrac.blogspot.com/ Open Source Integration http://open.iona.com