ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Java / JMS » MQ JMS PUB SUB

Post new topic  Reply to topic Goto page 1, 2, 3  Next
 MQ JMS PUB SUB « View previous topic :: View next topic » 
Author Message
adoyle65
PostPosted: Thu Mar 31, 2005 12:13 pm    Post subject: MQ JMS PUB SUB Reply with quote

Apprentice

Joined: 18 Feb 2004
Posts: 37
Location: Canada

Hello,

I have read through many postings on this topic but have found the answer difficult to find. Let me first say I know nothing about Websphere or JMS.

We have an app server and a web server running on a windows box. We have a broker and its queue manager running on an AIX box. We want the app server to be able to subscribe to and publish messages using the broker on the AIX box. What is the setup we need to follow? We believe that we have to run the MQJMS_*.* script to create some queues, why? This is on the AIX box? Do we need a queue manager on the windows box, or can websphere connect directly to the queue manager on the AIX machine?

If anyone can help it would be greatly appreciated.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu Mar 31, 2005 12:35 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

First of all you need your setup to be complete and functioning.

If your MQ server is running on the AIX box, where would your broker be running (hint on top of an MQ Server).

Once your MQ Server and broker are setup you need to define what will go into your JNDI environment.

As for the connections: Yes your Win Web/App server can connect directly to the MQ Server on the AIX box using a client connection.

Just be aware that unless you pay for the extended transactional client, you cannot do a 2 phase commit with a client connection.

To do a 2 phase commit the Web server (transaction coordinator) and MQ Server (XA resource) need to be on the same box.

Enjoy
Back to top
View user's profile Send private message Send e-mail
adoyle65
PostPosted: Thu Mar 31, 2005 12:48 pm    Post subject: Reply with quote

Apprentice

Joined: 18 Feb 2004
Posts: 37
Location: Canada

Hi there,

Our broker and qmgr are both running on an AIX box.
Not really sure what the setup being complete and functioning means.

The broker and qmgr are being used by other applications with no issues.

The intent is for an message driven bean to subscribe to a topic and retrieve messages from its subscription queue.

I guess we are having trouble because this is our first attempt at pub sub.

Any help would be appreciated.

Regards
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu Mar 31, 2005 12:56 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Just read carefully the using Java manual. (see docu button on top)
With what you intend you should be having little to no problem.

You did not specify what kind of WAS you are running.
Make sure the Classpath and all the other requirements for the MQ connection are done properly. Have MQ and WAS admin get their heads together.

Remember to use a TopicConnectionFactory for topics (pub/sub) and a QueueConnectionFactory for point to point.

Enjoy
Back to top
View user's profile Send private message Send e-mail
adoyle65
PostPosted: Thu Mar 31, 2005 1:03 pm    Post subject: Reply with quote

Apprentice

Joined: 18 Feb 2004
Posts: 37
Location: Canada

Hey,

Where is this docu button?

Thanks
Back to top
View user's profile Send private message
EddieA
PostPosted: Thu Mar 31, 2005 1:13 pm    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

Quote:
Where is this docu button?

At the top of this very page you are reading.

Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
Michael Dag
PostPosted: Thu Mar 31, 2005 1:22 pm    Post subject: Reply with quote

Jedi Knight

Joined: 13 Jun 2002
Posts: 2607
Location: The Netherlands (Amsterdam)

EddieA wrote:
Quote:
Where is this docu button?

At the top of this very page you are reading.

Just realised... with Firefox these buttons did not always show,
now that I am on 1.02 the buttons show, but not the dropdowns as in IE
_________________
Michael



MQSystems Facebook page
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
adoyle65
PostPosted: Thu Mar 31, 2005 1:25 pm    Post subject: Reply with quote

Apprentice

Joined: 18 Feb 2004
Posts: 37
Location: Canada

Hey,


Do you mean the blue menu at the top of the page?

Thanks
Back to top
View user's profile Send private message
Michael Dag
PostPosted: Thu Mar 31, 2005 1:26 pm    Post subject: Reply with quote

Jedi Knight

Joined: 13 Jun 2002
Posts: 2607
Location: The Netherlands (Amsterdam)

adoyle65 wrote:
Hey,
Do you mean the blue menu at the top of the page?
Thanks

Yes!
_________________
Michael



MQSystems Facebook page
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
bower5932
PostPosted: Thu Mar 31, 2005 1:49 pm    Post subject: Reply with quote

Jedi Knight

Joined: 27 Aug 2001
Posts: 3023
Location: Dallas, TX, USA

The following URL:

http://www.developer.ibm.com/tech/faq/individual?oid=2:83352

gives details on setting up a couple of jms sample programs that run outside of the app server. It gives information regarding the setup of the JMS definitions. Even though it isn't for the app server, you might find it helpful.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
adoyle65
PostPosted: Mon Apr 18, 2005 9:29 am    Post subject: Reply with quote

Apprentice

Joined: 18 Feb 2004
Posts: 37
Location: Canada

Hello,

We have managed to get some of this working but when in testing our app server crashes we get an error

Subscription has an active TopicSubscriber

Does anyone have any ideas?

Thanks
Back to top
View user's profile Send private message
bower5932
PostPosted: Mon Apr 18, 2005 10:12 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Aug 2001
Posts: 3023
Location: Dallas, TX, USA

My guess would be that you are not deregistering your subscribers. If you are using the MA0C broker, the dumpbroker.java program at:

http://www.developer.ibm.com/tech/sampmq.html

can be used to see who is active. It would also be nice to see the exact exception that is being thrown.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
adoyle65
PostPosted: Mon Apr 18, 2005 10:22 am    Post subject: Reply with quote

Apprentice

Joined: 18 Feb 2004
Posts: 37
Location: Canada

Hi,

I know nothing about Java or JMS how are you supposed to deregister a subscriber? Can you deregister a subscriber if your app crashes? We have a durable subscriber and we get this error message and the previous text MQJMS3023.

Hope this helps.

Thanks
Back to top
View user's profile Send private message
bower5932
PostPosted: Mon Apr 18, 2005 1:27 pm    Post subject: Reply with quote

Jedi Knight

Joined: 27 Aug 2001
Posts: 3023
Location: Dallas, TX, USA

When you mentioned your app crashing, I think that is probably what is causing your problem. You never disconnect from the qmgr, so your subscriber is left active. You then try to come right back with the same subscriber and get a message that you are already active. I would think that this would clear itself up when WMQ recognized you've gone away and closes the connection.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
adoyle65
PostPosted: Tue Apr 19, 2005 3:56 am    Post subject: Reply with quote

Apprentice

Joined: 18 Feb 2004
Posts: 37
Location: Canada

Hi bower5932,

I would have thought that our broker would have cleared up the subscritpion but this does not seem to be happening. Any ideas as to how we might resolve this. Apparently in production I am led to believe that it is not uncommonn to recycle the app server during the day, so we will be faced with this problem in prod.

Thanks
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page 1, 2, 3  Next Page 1 of 3

MQSeries.net Forum Index » IBM MQ Java / JMS » MQ JMS PUB SUB
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.