[JNDI and Naming] - Re: Why datasource JNDI name has to start with 'java:/' or 'java:jboss/ in AS 7.1
blake ong <[email protected]> Thu, 15 Aug 2013 06:03:47 -0400
| Newsgroups | gmane.comp.java.jboss.user |
|---|---|
| Message-ID | <[email protected]> |
blake ong [https://community.jboss.org/people/blake] created the discussion "Re: Why datasource JNDI name has to start with 'java:/' or 'java:jboss/ in AS 7.1" To view the discussion, visit: https://community.jboss.org/message/832744#832744 -------------------------------------------------------------- Our development team uses maven jetty plugin for our local environment, and our production uses JBoss EAP 6.1 All you need to do is to create a jboss-web.xml in your WEB-INF with something like below: <resource-ref> <res-ref-name>jdbc/MyDS</res-ref-name> <jndi-name>java:jboss/jdbc/MyDS</jndi-name> </resource-ref> In our web.xml we have something like this: <resource-ref> <res-ref-name>jdbc/MyDS</res-ref-name> <res-type>javax.sql.DataSource</res-type> <res-auth>Container</res-auth> </resource-ref> -------------------------------------------------------------- Reply to this message by going to Community [https://community.jboss.org/message/832744#832744] Start a new discussion in JNDI and Naming at Community [https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2083] _______________________________________________ jboss-user mailing list [email protected] https://lists.jboss.org/mailman/listinfo/jboss-user