7 Replies Latest reply on Apr 18, 2013 5:58 AM by ataylor

    exception while sending message to remote hornetQ

    a4arjun

      Hi all,

       

      i am trying to send a message to a remote hornetq.

       

      this is the properties i am setting in my client.

       

      final Properties env = new Properties();

      env.put(Context.INITIAL_CONTEXT_FACTORY, "org.jboss.naming.remote.client.InitialContextFactory");

      env.put(Context.PROVIDER_URL, "remote://localhost:4447");

      Context context = new InitialContext(env);

      ConnectionFactory cf = (ConnectionFactory) context.lookup("jms/RemoteConnectionFactory");

      Destination destination = (Destination) context.lookup("/queue/dataJMS");

       

       

      but when i am sending message exception is coming

       

       

      (http--0.0.0.0-8080-1) sendMessage NamingException JBAS011843: Failed instantiate InitialContextFactory org.jboss.naming.remote.client.InitialContextFactory from classloader ModuleClassLoader for Module "deployment.xxx.war:main" from Service Module Loader

       

       

      is this because of jnp-client.jar?

       

      if so how will i include this as a module in jboss.

      please help.

       

      thanks in advance.