3 Replies Latest reply on Jun 30, 2003 10:27 AM by Adrian Brock

    Look up problem

    csarmiento Newbie

      Dear all:
      I'm trying to run a jms client in a remote machine but i can't, i have Jboss running in another machine,
      I followed the steps that the JMS tutorial describes, (Communicating beetween a j2ee server and a System Not Running a J2eeserver) , i have a jndi.properties file with:
      java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
      java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
      java.naming.provider.url=10.0.37.85:1099

      my class is:
      Properties p = new Properties();
      p.put(Context.INITIAL_CONTEXT_FACTORY,"org.jnp.interfaces.NamingContextFactory");
      p.put(Context.PROVIDER_URL,"jnp://10.0.37.85:1099");
      System.setProperties(p);

      jndiContext =new InitialContext();
      topicConnectionFactory =(TopicConnectionFactory) jndiContext.lookup(conFacName);
      }catch (NamingException e){
      System.err.println("JNDI API lookup failed:"+
      e.toString());
      //System.exit(1);
      }

      i have in my classpath the jbossall-client.jar
      but when i run i receive the following message at lookup line (The initial context is good):
      Exception in thread "main" java.lang.ExceptionInInitializerError
      at sun.rmi.runtime.Log$LoggerLogFactory.createLog(Log.java:155)
      at sun.rmi.runtime.Log.getLog(Log.java:121)
      at sun.rmi.server.LoaderHandler.(LoaderHandler.java:60)
      at java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:629)
      at java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:257)
      at sun.rmi.server.MarshalInputStream.resolveClass(MarshalInputStream.jav
      a:200)
      at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:150
      3)
      at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1425)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1
      616)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1264)
      at java.io.ObjectInputStream.readObject(ObjectInputStream.java:322)
      at java.rmi.MarshalledObject.get(MarshalledObject.java:135)
      at org.jnp.interfaces.NamingContext.getServer(NamingContext.java:200)
      at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1116)
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:478)
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:471)
      at javax.naming.InitialContext.lookup(InitialContext.java:347)
      at MultiplePublisherTopicA.publica(MultiplePublisherTopicA.java:83)
      at MultiplePublisherTopicA.main(MultiplePublisherTopicA.java:167)
      Caused by: java.lang.IllegalArgumentException: Null charset name
      at java.nio.charset.Charset.lookup(Charset.java:376)
      at java.nio.charset.Charset.isSupported(Charset.java:405)
      at sun.nio.cs.StreamEncoder.forOutputStreamWriter(StreamEncoder.java:67)

      at java.io.OutputStreamWriter.(OutputStreamWriter.java:93)
      at java.util.logging.StreamHandler.setOutputStream(StreamHandler.java:11
      6)
      at java.util.logging.StreamHandler.(StreamHandler.java:92)
      at sun.rmi.runtime.Log$InternalStreamHandler.(Log.java:261)
      at sun.rmi.runtime.Log$1.run(Log.java:169)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.rmi.runtime.Log$LoggerLog.(Log.java:165)
      ... 19 more

      do you have any ideas?, please is urgent