1 Reply Latest reply: Nov 1, 2013 6:44 PM by Ayush Ganeriwal-Oracle RSS

    MessageSelector and client Id for JMS queues


      Hi everyone,


      I am using odi version


      I have configured data server , physical and logical schema for JMS queue technology.

      Connection is succesful.

      I also created model for jms queue...created a new datastore


      so now when i tried to view data in datastore , there is a windows that appears where i need to enter MESSAGE SELECTOR and CLIENT ID


      from where do I get this information about MESSAGE SELECTOR and CLIENT ID???


      I need to enter this info so that i can view the message in the queue (which is my data basically)


      my java console app for sender in jms queue is as follows:


      //this code will populate the queue with message hello

      //all necessary imports


      public class Sender


          public static void main(String[] args) throws Exception



          Hashtable env = new Hashtable();


          env.put(Context.PROVIDER_URL, "t3://localhost:7001");

          env.put(Context.SECURITY_PRINCIPAL, "weblogic");

          env.put(Context.SECURITY_CREDENTIALS, "welcome1");



          System.out.println("Contents of Env: " +env);


          // get the initial context

             InitialContext ctx = new InitialContext(env);


            // lookup the queue object

            Queue queue = (Queue) ctx.lookup("jms/TestJMSQueue");


             // lookup the queue connection factory

             QueueConnectionFactory connFactory = (QueueConnectionFactory) ctx.



             // create a queue connection

             QueueConnection queueConn = connFactory.createQueueConnection();


             // create a queue session

             QueueSession queueSession = queueConn.createQueueSession(false,



             // create a queue sender

             QueueSender queueSender = queueSession.createSender(queue);



             // create a simple message to say "Hello"

             TextMessage message = queueSession.createTextMessage("Hello");


            // send the message



             // print what we did

             System.out.println("sent: " + message.getText());


             // close the queue connection