Hi!
I'm trying out the Chat example from O'Reilly's JMS text. I've
configured the jbossmq.xml file to include :-
...
<Topic><Name>beginner</Name></Topic>
and
<User>
<Name>myname</Name>
<Password>mypassword</Password>
</User>
and the source is :-
...
Properties env = new Properties();
env.setProperty("java.naming.factory.initial",
"org.jnp.interfaces.NamingContextFactory");
env.setProperty("java.naming.provider.url", "localhost:1088");
InitialContext jndi = new InitialContext(env);
TopicConnectionFactory conFactory =
(TopicConnectionFactory)jndi.lookup("TopicConnectionFactory");
TopicConnection connection =
conFactory.createTopicConnection(username, password);
TopicSession pubSession = connection.createTopicSession(false,
Session.AUTO_ACKNOWLEDGE);
TopicSession subSession = connection.createTopicSession(false,
Session.AUTO_ACKNOWLEDGE);
Topic chatTopic = (Topic)jndi.lookup(topicName);
When I run it with all required classpath set, the outcome is :-
>java Chat beginner myname mypassword
javax.naming.NameNotFoundException: beginner not bound at
sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(Unknown
Source)
...
It seems "beginner" in jbossmq.xml is not bound into JNDI registry and I
cannot find the DTD for jbossmq.xml.
Can anyone help?
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user