JNDI Lookup Failing
jim_b_o Jul 28, 2013 12:55 PMRunning WildFly 8.0.0.Alpha3. Can connect successfully to http://localhost:8080 in web browser, but when trying JNDI lookup I have no luck. Here's everything I believe to be relevant:
<dependency>
<groupId>org.wildfly</groupId>
<artifactId>wildfly-ejb-client-bom</artifactId>
<version>8.0.0.Alpha3</version>
<type>pom</type>
<scope>compile</scope>
</dependency>
Properties env = new Properties();
env.put(Context.INITIAL_CONTEXT_FACTORY, org.jboss.naming.remote.client.InitialContextFactory.class.getName());
env.put(Context.PROVIDER_URL, "remote://localhost:8080");
InitialContext context = new InitialContext(env);
context.lookup("jms/RemoteConnectionFactory");
INFO: XNIO Version 3.1.0.CR3
Jul 28, 2013 5:46:40 PM org.xnio.nio.NioXnio <clinit>
INFO: XNIO NIO Implementation Version 3.1.0.CR3
Jul 28, 2013 5:46:40 PM org.jboss.remoting3.EndpointImpl <clinit>
INFO: JBoss Remoting version 4.0.0.Beta1
Exception in thread "main" javax.naming.NamingException: Failed to connect to any server. Servers tried: [remote://localhost:8080]
at org.jboss.naming.remote.client.HaRemoteNamingStore.failOverSequence(HaRemoteNamingStore.java:213)
at org.jboss.naming.remote.client.HaRemoteNamingStore.namingStore(HaRemoteNamingStore.java:144)
at org.jboss.naming.remote.client.HaRemoteNamingStore.namingOperation(HaRemoteNamingStore.java:125)
at org.jboss.naming.remote.client.HaRemoteNamingStore.list(HaRemoteNamingStore.java:295)
at org.jboss.naming.remote.client.RemoteContext.list(RemoteContext.java:119)
at org.jboss.naming.remote.client.RemoteContext.list(RemoteContext.java:123)
at javax.naming.InitialContext.list(InitialContext.java:455)
at WildFlyLookup.main(WildFlyLookup.java:26)
Any ideas?