Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

JMS between two Weblogic Servers

0 views
Skip to first unread message

Adarsh Dattani

unread,
Dec 11, 2001, 8:41:17 PM12/11/01
to
We are starting a new project and I'd really appreciate answers to the
following questions before I can start prototyping.
I have two instances of WLS 6.0 in separate machines (not part of the same
cluster) :
Question 1 : Can I send a JMS message from ServerA to ServerB and have MDBs
process those messages in Server B.
Question 2 : Can I have an MDB in Server B pull messages from Server A ?
Question 3 : In Question 1 the publisher/sender in Server A, and in Question
2 the MDB in Server B will need the URL, QueueConnectionFactory,
InitialContextFactory and Queue names. Can I have these in a common LDAP
store and then do lookups ? Or, can these classes lookup the objects from
the other server assuming there are no firewall issues ?
Question 4 : Do I have to do anything special for the operations in Question
1 and Question 2 to work under a 2PC license (I believe these would be 2PC
transactions) ? Or, does the WL Transaction manager automatically manage it
as a 2PC operation since the foreign destination is Weblogic JMS ?
Question 5 : Can I accomplish all of the above with both servers running WLS
6.1 ?
Question 6 : Can I have one server running WLS 6.0 sp2 and the other running
WLS 6.1 sp1 and still accomplish all of the above ?
Thanks in advance,
Adarsh

Zach

unread,
Dec 11, 2001, 9:54:58 PM12/11/01
to
> Question 1 : Can I send a JMS message from ServerA to ServerB and have
MDBs
> process those messages in Server B.
Yes.

> Question 2 : Can I have an MDB in Server B pull messages from Server A ?

Yes.

> Question 3 : In Question 1 the publisher/sender in Server A, and in
Question
> 2 the MDB in Server B will need the URL, QueueConnectionFactory,
> InitialContextFactory and Queue names. Can I have these in a common LDAP
> store and then do lookups ? Or, can these classes lookup the objects from
> the other server assuming there are no firewall issues ?

You just need an initial context for the other server so you can look up the
connection factory and queues there.

> Question 4 : Do I have to do anything special for the operations in
Question
> 1 and Question 2 to work under a 2PC license (I believe these would be 2PC
> transactions) ? Or, does the WL Transaction manager automatically manage
it
> as a 2PC operation since the foreign destination is Weblogic JMS ?

Standard stuff. in the ejb-jar.xml file and weblogic-ejb-jar.xml.


> Question 5 : Can I accomplish all of the above with both servers running
WLS
> 6.1 ?

Yes, but I would setill get 6.1 SP1.

> Question 6 : Can I have one server running WLS 6.0 sp2 and the other
running
> WLS 6.1 sp1 and still accomplish all of the above ?

No.

Adarsh Dattani

unread,
Dec 12, 2001, 11:19:28 AM12/12/01
to

Thanks Zach. That was very helpful!

Adarsh Dattani

unread,
Dec 12, 2001, 4:43:48 PM12/12/01
to
Zach,
Just to do a prototype I set up two instances of WLS on my desktop. Server
A listening on port 7001 and the Server B on port 7005. I have an MDB in
Server A that reads messages from a persistent queue in the same server and
sends them to a non-persistent queue in Server B. I have a
non-transactional SSP and consumer in Server B hooked to the queue in Server
B.
When I start both servers, and run the above test case, Server A writes the
following messages to the log file. The MDB in Server B says that the
message was sent successfully but I don't see nothing in Server B.

####<Dec 12, 2001 1:32:24 PM PST> <Error> <RJVM> <oak_4481> <myserver>
<ExecuteThread: '9' for queue: 'default'> <> <> <000000> <Unsolicited error
response for: '-1'>
java.lang.RuntimeException: Client possibly malfunctioning as
RuntimeException t
hrown from the onMessage routine of the client
at weblogic.jms.client.JMSSession.onMessage(JMSSession.java:1938)
at weblogic.jms.client.JMSSession.execute(JMSSession.java:1892)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
at weblogic.kernel.Kernel.execute(Kernel.java:250)
at weblogic.jms.client.JMSSession.pushEnvelope(JMSSession.java:1779)
at weblogic.jms.client.JMSCallback.pushEnvelope(JMSCallback.java:78)
at weblogic.jms.frontend.FESession.execute(FESession.java:1972)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)

Both Servers use separate JVMs.
Server A uses a JDBC data store.
The queue in Server B is non-persistent.

Any thoughts ?
Thanks,
Adarsh


"Adarsh Dattani" <Adarsh_...@apl.com> wrote in message
news:3c178390$1...@newsgroups.bea.com...

Adarsh Dattani

unread,
Dec 12, 2001, 4:46:32 PM12/12/01
to
Correcting a small typo.

When I start both servers, and run the above test case, Server A writes

the following messages to the log file. The MDB in Server A (not Server B)


says that the
message was sent successfully but I don't see nothing in Server B.

"Adarsh Dattani" <Adarsh_...@apl.com> wrote in message
news:3c17cf34$1...@newsgroups.bea.com...

Zach

unread,
Dec 12, 2001, 10:46:01 PM12/12/01
to
I am not sure where the "Unsolicted error response for: '-1'" comes from.
But the stack trace indicates a RuntimeException in the OnMessage method.
We don't display the stack trace from that. I suggest catching such
exceptions inside your onMessage method to see what is going on.

_sjz


"Adarsh Dattani" <Adarsh_...@apl.com> wrote in message

news:3c17cf34$1...@newsgroups.bea.com...

Adarsh Dattani

unread,
Dec 13, 2001, 3:56:39 PM12/13/01
to
Let's set aside the "Unsolicited error ....'. There is still something
driving me crazy.

There is no other message listener in Server A except for the MDB. I have
coded a complete stack track display for any error in onMessage. I still
get the RunTimeException from the onMessage method (only that it doesn't say
the onMessage of which class).

Server B has a file store. The message sent from Server A makes it to the
file store in Server B. I just verfied that. But the message listener in
Server B won't see that message. If I send a message directly to Server B
from a client, the listener is invoked but NOT when it comes from Server A.
My MDB in Server A confirmed that the message was sent and the tx was
committed. I verfied that by looking at the file store in Server B. Now,
why is it that the listener won't see the message when it comes from Server
A ? Also why am I getting the RunTimeException from a ghost listener's
onMessage method ?

Please help, help, help !!

Regards,
Adarsh


"Zach" <za...@nospam.com> wrote in message
news:3c18...@newsgroups.bea.com...

Rob Hayes

unread,
Dec 20, 2001, 12:10:31 PM12/20/01
to
Adarsh,

I know it's a long shot but I do remember we had some problems when
sending / receiving between two Weblogic's because the Weblogic server
name was the same in both, try making sure that the weblogic server
names (not the JMS Server name) are different.

Rob

Adarsh Dattani

unread,
Dec 20, 2001, 12:49:52 PM12/20/01
to
I'll give it a shot. Right now, they are both set to the default
(myserver).
Thanks for the info,
Adarsh

"Rob Hayes" <robert...@db.com> wrote in message
news:fcd31e2f.0112...@posting.google.com...

Adarsh Dattani

unread,
Dec 20, 2001, 2:09:35 PM12/20/01
to
Did not work Rob. I have narrowed it down to a JNDI authentication issue in
the WLInitialContextFactory. Will let you know when I have a solution.
Thanks,
Adarsh


"Adarsh Dattani" <Adarsh_...@apl.com> wrote in message

news:3c22...@newsgroups.bea.com...

Rajesh Mirchandani

unread,
Dec 20, 2001, 2:30:20 PM12/20/01
to
Make sure you have the same system password for both the servers.

Adarsh Dattani wrote:

--
Rajesh Mirchandani
Developer Relations Engineer
BEA Support


0 new messages