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 » How Message Goes in Dead_Letter_Queue?

Post new topic  Reply to topic
 How Message Goes in Dead_Letter_Queue? « View previous topic :: View next topic » 
Author Message
niraj.tayade
PostPosted: Mon Jul 24, 2006 10:51 pm    Post subject: How Message Goes in Dead_Letter_Queue? Reply with quote

Newbie

Joined: 24 Jul 2006
Posts: 6
Location: Pune

Hi to All

I want a sample code for putting the message in DLQ
If I put message in my local queue and that local queue is Inhibited then how messge goes in DLQ



Thanks In Advanced
_________________
Regards
Niraj Tayade
Software Developer
Xite etc Software Pvt.Ltd.
Pune,India
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Mr Butcher
PostPosted: Mon Jul 24, 2006 11:13 pm    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

the dlq is used by the queuemanager, not by the application (you can, but you should not).

if an application tries to put a message to a queue and that put failes, mq cann pass a returncode and conditioncode to the application. it is then up to the application to decide what to do. this is some kind of synchronous processing, there is a connection between the application and mq.

but when you use distributed queueing, it is a little bit different becuase there are multiple UOWs involved, and the processing is asynchronous.
application A puts a message in qmgr 1, qmgr 1 transferes message to qmgr 2 so it can be processed by application B (this are 3 UOWs). now qmgr2 fails to put the message to the target queue. who shall qmgr2 notiry? application A? no. this UOW is already gone and comitted, there is no way to give application A a returncode for this UOW. So qmgr2 tries to put the message to the local DLQ if defined, adding a DLQ header with the reason why the put fails.

if you want to use a similiar processing for the application, then you should consider using the backout queue or something similiar. it is a good advice not to use the dlq for application purposes.
_________________
Regards, Butcher
Back to top
View user's profile Send private message
niraj.tayade
PostPosted: Mon Jul 24, 2006 11:28 pm    Post subject: How Message Goes in Dead_Letter_Queue? Reply with quote

Newbie

Joined: 24 Jul 2006
Posts: 6
Location: Pune

Which setting I want to do in my application for goes the message in DLQ if any problem exists.

Thanx in Advanced
_________________
Regards
Niraj Tayade
Software Developer
Xite etc Software Pvt.Ltd.
Pune,India
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Mr Butcher
PostPosted: Tue Jul 25, 2006 12:22 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

there is not such a setting.

when the application puts and the put fails, you get a returncode and condition code. there is no setting that makes mq place the message in the dlq.
if you want to do that, you have to code it. (open, put, close or put1). but what do you do if that put fails too?
_________________
Regards, Butcher
Back to top
View user's profile Send private message
niraj.tayade
PostPosted: Tue Jul 25, 2006 1:19 am    Post subject: What is complete procedure for DLQ? Reply with quote

Newbie

Joined: 24 Jul 2006
Posts: 6
Location: Pune

Then,how the mesasge goes in DLQ?
If the application fails to put the message in local queue,what happened?


Thanx In Advanced

Niraj
_________________
Regards
Niraj Tayade
Software Developer
Xite etc Software Pvt.Ltd.
Pune,India
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Nigelg
PostPosted: Tue Jul 25, 2006 1:47 am    Post subject: Reply with quote

Grand Master

Joined: 02 Aug 2004
Posts: 1046

The main cause of a msg being put to the DLQ is if a channel operation fails, e.g. a channel cannot put a persistent msg to a destination queue because the queue is full.

A msg is NOT put to the DLQ if a user app fails to put a msg to a local queue. In that case, the MQPUT returns with a ReasonCode describing the failure; the app then has to take action based on the ReasonCode.
_________________
MQSeries.net helps those who help themselves..
Back to top
View user's profile Send private message
Mr Butcher
PostPosted: Tue Jul 25, 2006 1:49 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

something makes me feel that you have not read what i wrote.

sorry, i give up on this one.
_________________
Regards, Butcher
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General Discussion » How Message Goes in Dead_Letter_Queue?
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.