doesnt work for me & i fail to see the error here. 

jboss-4.0.1sp1
winxp
jdk 1.4.x

-----------------------------------------------------------------

jboss-web.xml

  | <?xml version="1.0" encoding="UTF-8"?>
  | <jboss-web>
  |     <resource-ref>
  |         <res-ref-name>jdbc/dev</res-ref-name>        
  |         <jndi-name>java:dev</jndi-name>
  |     </resource-ref>
  | </jboss-web>
  | 

mssql-ds.xml

  | <?xml version="1.0" encoding="UTF-8"?>
  | <datasources>
  |               <local-tx-datasource>
  |     <jndi-name>dev</jndi-name>
  |     <use-java-context>true</use-java-context>
  |     <connection-url>...</connection-url>
  |     <driver-class>net.sourceforge.jtds.jdbc.Driver</driver-class>
  |             <user-name>sa</user-name>
  |             <password></password>
  |             <min-pool-size>5</min-pool-size>
  |             <max-pool-size>20</max-pool-size>
  |             <idle-timeout-minutes>0</idle-timeout-minutes>
  |     </local-tx-datasource>
  | </datasources>
  | 

web.xml

  |     <resource-ref>
  |             <description>The default DS</description>
  |             <res-ref-name>jdbc/dev</res-ref-name>
  |             <res-type>javax.sql.DataSource</res-type>
  |             <res-auth>Container</res-auth>
  |     </resource-ref>
  | 

java code

  | Context initCtx = new InitialContext();
  | Context envCtx = (Context) initCtx.lookup("java:comp/env");
  | DataSource ds = (DataSource) envCtx.lookup("jdbc/dev);
  | conn = ds.getConnection();
  | 


----------------------------------------------------------------------

im sure it would work if i did the lookup the jboss way, but this should really 
be portable across containers (the java code does work in tomcat 5.x).  

yes, i can see the mbean & ive tried all sorts of ways to get this to work, so 
if anyone knows the answer to this, please let me know.  


i like jboss but this is just stupid--maybe im missing something, but it 
shouldn't be this much of a hassle.  judging by the number of posts on this 
subject & the jca moderator's comments, it appears that im not the only one 
having this problem.



View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3875441#3875441

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3875441


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to