1 Reply Latest reply on May 3, 2005 7:44 PM by Scott Stark

    seting MDB destination on the fly

    Eric Freed Newbie

      Is it possible to set the destination of a MDB programmatically? Perhaps with jmx?

      I have a single configuration file (the queues are created at startup using jmx), and will have a number of queues setup. I would like to reduce duplication of the queue name (one in the config file for the sources, once in the jboss.xml for each MDB). However, it looks to me like this might not be possible if I want to use MDB.

      Anyone done this successfully?

      Many thanks

      Eric

        • 1. Re: seting MDB destination on the fly
          Scott Stark Master

          Its not possible currently. You could try using a system property reference in the jboss.xml file and set the corresponding property before the mdbs are depoyed.

          <jboss>
          ...
           <message-driven>
           <ejb-name>somemdb</ejb-name>
           <destination-jndi-name>${somemdb.queue.name}</destination-jndi-name>
           </message-driven>
          ...