I want to send a message to a queue, then if the message is not picked up in
the allotted time frame, forward the errored message to my
DeadLetterChannel.

here is my routing:

*    public static final String CHANNEL_GG_CS_COMMAND_TIMEOUT =
"activemq:queue:channel/command/timeout?timeToLive=545000";

        from(Constants.CHANNEL_GG_CS_TAP)
                .to(Constants.CHANNEL_GG_CS_COMMAND_TIMEOUT);

        from(Constants.CHANNEL_GG_CS_COMMAND_TIMEOUT)
                .errorHandler(

deadLetterChannel(Constants.CHANNEL_GG_CS_COMMAND_STATUS_ERROR) // need to
direct this to timeoutProcessor
                                .loggingLevel(LoggingLevel.INFO)
                ).transform(body().append(" *** TIMEOUT EXCEPTION ***")); //
does not get consumed as we want to wait for a timeout


*

But when I send a message to the timeout queue, is seems to immediately be
an DLC

*[ltMessageListenerContainer-244] EndpointMessageListener        DEBUG
Endpoint[activemq:queue:channel/gogrid/cloudstorage/command/timeout?timeToLive=5
5000] consumer receiving JMS message: ActiveMQTextMessage {commandId = 5,
responseRequired = true, messageId = ID:mickknutson-1507-1223421985269-0:11:
1:1:1, originalDestination = null, originalTransactionId = null, producerId
= ID:mickknutson-1507-1223421985269-0:11:1:1, destination = queue://channe
l/gogrid/cloudstorage/command/timeout, transactionId = null, expiration =
1223422281505, timestamp = 1223422226505, arrival = 0, brokerInTime = 122342
2226884, brokerOutTime = 1223422226942, correlationId = null, replyTo =
null, persistent = true, type = null, priority = 4, groupID = null,
groupSeque
nce = 0, targetConsumerId = null, compressed = false, userID = null, content
= [EMAIL PROTECTED], marshalledProperties = org
[EMAIL PROTECTED], dataStructure = null,
redeliveryCounter = 0, size = 0, properties = null, readOnlyProperties =
true, readO
nlyBody = true, droppable = false, text = null}
[ltMessageListenerContainer-244] EndpointMessageListener        DEBUG Cannot
send reply message as there is no replyDestination for: JmsMessage: {"com
mandType":"jobStatus","status":"succeeded","message":{"customerId":"16323"},"changeRequestId":"4322","jobId":"ebd47e58-94c7-11dd-b4f0-0030488bd1fd"}
*
** TIMEOUT EXCEPTION ***
*

and never seems to get routed to *CHANNEL_GG_CS_COMMAND_STATUS_ERROR either.
*

-- 
---
Thank You…

Mick Knutson
BASE Logic, inc.
(415) 354-4215

Website: http://baselogic.com
Blog: http://baselogic.com/blog
BLiNC Magazine: http://blincmagazine.com
Linked IN: http://linkedin.com/in/mickknutson
DJ Mick: http://djmick.com
MySpace: http://myspace.com/mickknutson
Vacation Rental: http://tahoe.baselogic.com

Reply via email to