|
Websphere MQ Everyplace | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.mqe.MQe | +--com.ibm.mqe.MQeRule | +--examples.mqbridge.rules.UndeliveredMQMessageToDLQRule
This is an example rules class which dictates what action an MQ XmitQ Listener should take if a message is undelivered. In this situation, the permit() method will be loaded and queried dynamically. This example class either returns any undelivered message to the MQ series Dead Letter Queue or (if the message has MQRO_DISCARD set) discards it.
Field Summary | |
static short[] |
version
|
Constructor Summary | |
UndeliveredMQMessageToDLQRule()
|
Method Summary | |
java.lang.Object |
permit(java.lang.Object failureCodesO,
java.lang.Object targetNames,
java.lang.Object failedMQeMessageO)
To find out what behaviour should occur in the listener when a message cannot be delivered, but may benefit from a retry at a later date. |
Methods inherited from class com.ibm.mqe.MQeRule |
activate, close, newRule |
Methods inherited from class com.ibm.mqe.MQe |
abbreviate, alias, asciiToByte, byteToAscii, byteToHex, byteToHex, byteToInt, byteToLong, byteToShort, byteToUnicode, fileSeparator, getEventLogHandler, hexToAscii, hexToByte, intToByte, isCLDC, loadClass, loadObject, log, setEventLogHandler, setLoader, sliceByteArray, type, unicodeToByte, uniqueValue |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static short[] version
Constructor Detail |
public UndeliveredMQMessageToDLQRule()
Method Detail |
public java.lang.Object permit(java.lang.Object failureCodesO, java.lang.Object targetNames, java.lang.Object failedMQeMessageO) throws java.lang.Exception
The listener has a number of conditions under which a message cannot be delivered to the MQe network.
Whenever an MQ Message cannot be put to MQe a rule class like this can decide on which course of action to take.
targetNames
- String[] with the following two elements:
The listener should stop as a result of this message being undeliverable.
The message should either be discarded or moved to the MQ dead letter queue, depending on the value of the original 'report' field of the original MQ Message.
The number of seconds which the listener should wait before retrying the MQ-to-MQe transfer operation.
If a value not in the list above is specified, or if the rule throws an exception, then the listener will assume the STOP_LISTENER result was returned.
Fails
- if the rule has some problem with it's logic.
This will have the same result as returning the STOP_LISTENER value
in terms of how the listener will react.
java.lang.Exception
|
Websphere MQ Everyplace | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |