|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
MQ Series |
« View previous topic :: View next topic » |
Author |
Message
|
maxyen |
Posted: Thu Aug 08, 2002 5:44 pm Post subject: MQ Series |
|
|
Newbie
Joined: 08 Aug 2002 Posts: 8
|
I am about to write my first application using MQseries. I am wondering whether it makes sense to have a program that will open the queue at the start of the day and one that will close the queue at the end of the day.
Or does it not make any difference opening and closing when needed.
Is there any overhead in opening and closing?
What is the best approach?
Thanks,
Max |
|
Back to top |
|
 |
kolban |
Posted: Thu Aug 08, 2002 6:58 pm Post subject: |
|
|
 Grand Master
Joined: 22 May 2001 Posts: 1072 Location: Fort Worth, TX, USA
|
Opening a queue is only second in cost to connecting to a queue manager. If you plan on doing frequent activity against the queue, keep it open. If you are going to do infrequent activity against the queue, then close after use. Having a queue open does consume system resources. |
|
Back to top |
|
 |
mgrabinski |
Posted: Thu Aug 08, 2002 9:38 pm Post subject: |
|
|
Master
Joined: 16 Oct 2001 Posts: 246 Location: Katowice, Poland
|
Maxyen,
If open a queue in program 'A', you can't close it in program 'B'. Keep your queue open as long as you need, but close it in the same program (process or thread) that opened it. Ending the program will also close all open queues _________________ Marcin Grabinski <>< |
|
Back to top |
|
 |
nimconsult |
Posted: Thu Aug 08, 2002 10:13 pm Post subject: |
|
|
 Master
Joined: 22 May 2002 Posts: 268 Location: NIMCONSULT - Belgium
|
Max,
You do not write a program that opens the queue and another that closes the queue. This is not the MQ Series way of working.
What you write is an application that opens a queue, gets messages (may be also waits for these messages), performs some processing, closes the queue and stops.
Now you can decide that this application will run the whole day, or at specific hours of the day, or triggered by MQ Series. Everything is possible and the option is a question of business requirements and design option.
Running the application the entire day:
+: application is always ready, only one warm-up sequence, best response time
-: the application constantly holds resources on the machine (design must ensure that resources are not locked)
Running the application on trigger:
+: does not constantly hold resources; gives a better operational view that the application is doing something.
-: you pay an overhead of starting and stopping process, perform warm-up sequence, clean resources on every occurrence of the application. _________________ Nicolas Maréchal
Senior Architect - Partner
NIMCONSULT Software Architecture Services (Belgium)
http://www.nimconsult.be |
|
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
|
|
|
|