How should an MDB reactivate itself after self-deactivation ( which might be technically possible with some tedious MBean code )? There has to be some other external monitor/stimulus for that !
Take a look at somebody's message here:
http://www.jboss.org/modules/bb/index.html?module=bb&op=viewtopic&t=forums/ the source to JBoss and craft yourself an Invoker subclass.
See the classes:
Invocation.getArguments() returns an array of one object,
the first is the javax.jms.Message going to your MDB.
You can decide to hold on to the message, or redirect it to another queue, like the dead letter service. Remember that you're going to be affecting all JMS messages.
Probably even better: If you want to suspend message delivery, you can easily call stopService on the MDB using the "jmx-console", and then startService to being receiving the messages again.
There are lots of ways of doing this.