[jboss-user] [Clustering/JBoss] - HA-JMS objects lookup in a Cluster
schaefera
do-not-reply at jboss.com
Tue Feb 20 18:40:50 EST 2007
I have a cluster setup with a HA-JMS and now I am trying to lookup a Connection Factory or Destination from within an EJB deployed on that cluster. Create an Initial Context like this:
lProperties.put( Context.INITIAL_CONTEXT_FACTORY, "org.jnp.interfaces.NamingContextFactory" );
lProperties.put( Context.URL_PKG_PREFIXES, "jboss.naming:org.jnp.interfaces" );
lProperties.put( "jnp.partitionName", "DefaultPartition" ); // partition name.
it works fine when using a Global Namespace JNDI name but when using a Resource Reference ('java:comp/env') it cannot find that object.
Using the default InitialContext (new InitialContext()) I can find the Resource Reference (the JNDI link) but it will not find the JMS resource on the HA-JMS when the EJB on a slave node it called because it is not contacting the HAJNDI but the local JNDI server.
Is there a way to lookup a JMS resource through an EJB resource reference with the default Initial Context?
Thanx - Andy
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4019609#4019609
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4019609
More information about the jboss-user
mailing list