title: How can i see messages from DLQ on Jboss AS 7?
body: <p>I'm using Jboss AS 7.1.1 and i need to see the messages that are in DLQ (Dead Letter Queue).</p>
  
  <p>I tried writing a simple MDB for it:</p>
  
  <pre><code>@MessageDriven(messageListenerInterface = MessageListener.class, activationConfig = {
          @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue"),
          @ActivationConfigProperty(propertyName = "destination", propertyValue = "java:/queue/DLQ"),
          @ActivationConfigProperty(propertyName = "maxSession", propertyValue = "1") })
  public class DLQMDB implements MessageListener{
  public void onMessage(Message message) {
      try {
          process(message);
      } ...
  }
  }
  </code></pre>
  
  <p>I wrote another MDB that throws error so the messages will do to the DLQ, but the DLQ MDB is never triggered.</p>
  
  <p>I don't know if it is because there are no messages in the DLQ or the MDB is not defined correctly.</p>
  
  <p>What am i doing wrong? Is there another way to see messages in the DLQ (like logging, admin interface)?</p>