Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Jul 4th, 2012  |  syntax: None  |  size: 0.35 KB  |  hits: 15  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Sending JMS message using Java
  2. InitialContext iniCtx = new InitialContext();
  3. Object tmp = iniCtx.lookup("ConnectionFactory");
  4. TopicConnectionFactory tcf = (TopicConnectionFactory) tmp;
  5. conn = tcf.createTopicConnection();
  6. topic = (Topic) iniCtx.lookup("topic/testTopic");
  7. session = conn.createTopicSession(false, TopicSession.AUTO_ACKNOWLEDGE);
  8. conn.start();