I'm trying to establish a database connection from a swing application (oracle 10g) which resides in a different VM,
env.put("java.naming.provider.url", "ormi://localhost");
env.put("java.naming.factory.initial",
"com.evermind.server.ApplicationClientInitialContextFactory") Context ic = new InitialContext (env);
Object dataSource = ic.lookup("jdbc/datasource");
System.out.println("Retrieved "+dataSource );
The application is throwing the following exception
Exception javax.naming.NamingException: META-INF/application-client.xml resource not found (see
J2EE spec, application-client chapter for requirements and format of the file)
javax.naming.NamingException: META-INF/application-client.xml resource not found (see J2EE spec, application-client chapter for requirements and format of the file)
at com.evermind.server.ApplicationClientInitialContextFactory.getInitialContext(ApplicationClientInitialContextFactory.java:86)
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
at javax.naming.InitialContext.init(InitialContext.java:219)
at javax.naming.InitialContext.<init>(InitialContext.java:195)
at com.tasq.team.util.TestConnection.main(TestConnection.java:61)
I have defined the datasource in the application-client.xml and moved it the config of the oracle app server.Any Help would be appreciated!!!