2 Replies Latest reply on Oct 12, 2011 4:25 PM by Clebert Suconic

    Writing a transform class that discards/drops messages

    bence magyar Newbie

      Hi folks,

      I am writing a transform class for hornetQ-2.2.8-EAP.  I would like the transform to drop/discard messages that meet certain criteria.  Is this possible?

      Is it permissible to return "null" from a transform class?

       

      public class myTransform implements Transformer

      {

          public ServerMessage transform(final ServerMessage message)

          {

                   if(...){

                       // discard message

                   }

          }

      }