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 » General Discussion » MQ Series

Post new topic  Reply to topic
 MQ Series « View previous topic :: View next topic » 
Author Message
maxyen
PostPosted: Thu Aug 08, 2002 5:44 pm    Post subject: MQ Series Reply with quote

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
View user's profile Send private message
kolban
PostPosted: Thu Aug 08, 2002 6:58 pm    Post subject: Reply with quote

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
View user's profile Send private message
mgrabinski
PostPosted: Thu Aug 08, 2002 9:38 pm    Post subject: Reply with quote

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
View user's profile Send private message
nimconsult
PostPosted: Thu Aug 08, 2002 10:13 pm    Post subject: Reply with quote

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
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General Discussion » MQ Series
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.