5 Replies Latest reply on Apr 1, 2004 1:58 PM by Matthew S. Ring

    MBean to be a topic subscriber, how?

    alanc_yang Newbie

      Trying to be a topic subscriber from MBean, the following encountered exception:

      InitialContext iniCtx = new InitialContext();
      Object tmp = iniCtx.lookup("ConnectionFactory");
      TopicConnectionFactory tcf = (TopicConnectionFactory) tmp;

      javax.naming.NameNotFoundException: ConnectionFactory not bound
      at org.jnp.server.NamingServer.getBinding(NamingServer.java:495)
      at org.jnp.server.NamingServer.getBinding(NamingServer.java:503)
      at org.jnp.server.NamingServer.getObject(NamingServer.java:509)

      how to subscribe to a topic that MBean can receive the message?

      Thanks a lot for your help.