0 Replies Latest reply on Nov 28, 2012 1:01 PM by lalitawasthi007

    Not able to look up JNDI name using java:comp/env

    lalitawasthi007

      Hello All

       

      I am moving a code from RAD websphere to Jboss developer (JBOSS 5.1)

       

      I am trying to look up JNDI name like Java:comp/env/jdbc/myDB but it simply binds it to "

       

      Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=jdbc/myDB' to JNDI name 'java:jdbc/myDB'

      isstead of this I want this to work like

      "

      Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=jdbc/myDB' to JNDI name 'java:comp/env/jdbc/myDB'"

      Please let me know if anyone can help me in this

      jbossweb.xml

      <

      resource-ref id="ResourceRef_2"

      >

      <

      description></description

      >

      <

      res-ref-name>java:comp/env/jdbc/myDB</res-ref-name

      >

      <

      res-type>javax.sql.DataSource</res-type

      >

      <

      jndi-name>java:/jdbc/myDB</jndi-name

      >

      <

      res-auth>Container</res-auth

      >

      </

      resource-ref>

       

       

      Thanks