|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
TopicPublisher.publish() |
« View previous topic :: View next topic » |
Author |
Message
|
techno |
Posted: Wed Apr 09, 2003 9:19 pm Post subject: TopicPublisher.publish() |
|
|
Chevalier
Joined: 22 Jan 2003 Posts: 429
|
Does above method wait (does get stuck without doing anything), in case Publish/subscribe broker down?
I think I am doing something wrong. The program should be able to put the message. When the broker comes up, the message should be reaching subscriber queue from publications queue.
Topic t = sess.createTopic("my/Topic");
TopicPublisher pub = sess.createPublisher(t);
TextMessage hello = sess.createTextMessage();
hello.setText("Hello World");
pub.publish(hello);
Correct me,
shiva. |
|
Back to top |
|
 |
techno |
Posted: Thu Apr 10, 2003 7:44 am Post subject: |
|
|
Chevalier
Joined: 22 Jan 2003 Posts: 429
|
Added to that, above call publish() is waiting for some time (a minute or so) and finally giving an error saying that broker is not available, in case the broker is down.
Thanks
Shiva. |
|
Back to top |
|
 |
bower5932 |
Posted: Fri Apr 11, 2003 12:00 pm Post subject: |
|
|
 Jedi Knight
Joined: 27 Aug 2001 Posts: 3023 Location: Dallas, TX, USA
|
The publish will definitely "hang" if the broker isn't available. The publish message will go to the broker and a reply will come back. If the broker isn't running, the reply times out. Do you have your broker running? What broker are you running? |
|
Back to top |
|
 |
techno |
Posted: Fri Apr 11, 2003 2:21 pm Post subject: |
|
|
Chevalier
Joined: 22 Jan 2003 Posts: 429
|
I stopped broker running. Is it not that the publication should be existing in publication queue? Is it to be running always?
Thanks
Shiva. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|