-
Bug
-
Resolution: Done
-
Major
-
JBossAS-4.0.0 Final
-
None
-
None
SourceForge Submitter: shuchan .
With the clustered environment using JBoss 4.0.0/4.0.
1RC1, the HA-JNDI auto-discovery runs into "java.lang.
IllegalArgumentException: hostname can't be null".
A workaround is to configure 'jnp.localAddress' property
before generating an InitialContext object.
A possible fix is to apply a patch in the attachment.
Environments :
[OS] Windows XP Pro SP1
[JDK] Sun J2SDK 1.4.2_06
[Exception stack traces]
Stack traces in the client side are in the attached
file(trace-patch.txt). server.log has no special exception.
[Steps to reproduce the bug]
Run codes like this on a remote jvm :
java.util.Hashtable props = new Hashtable();
props.put(Context.INITIAL_CONTEXT_FACTORY,
"org.jnp.interfaces.NamingContextFactory");
props.put(Context.URL_PKG_PREFIXES,
"org.jboss.naming:org.jnp.interfaces");
javax.naming.Context ctx = new javax.naming.
InitialContext(props);
Object obj = ctx.lookup("Counter");