[jboss-user] [Beginners Corner] - Re: Deployment order and MYSQL Driver class issues

zparticle do-not-reply at jboss.com
Tue Aug 26 14:28:32 EDT 2008


Okay the hang was, of course, caused by a bug in my logic. The JNDI look up is working now. Unforutnately the app is still loading ahead the JNDI data source getting created.

applicationContext.xml
	<bean id="photositeDataSource" class="org.springframework.jndi.JndiObjectFactoryBean">
  | 		<property name="jndiName" value="java:photosite"/>
  | 		<property name="resourceRef" value="false"></property>
  | 	</bean>

jboss-web.xml
	<resource-ref>
  | 		<res-ref-name>photosite</res-ref-name>
  | 		<jndi-name>photosite</jndi-name>
  | 		<res-type>javax.sql.DataSource</res-type>
  | 	</resource-ref>
  | 

web.xml

  | 	<resource-ref>
  | 		<description>DB Connection</description>
  | 		<res-ref-name>photosite</res-ref-name>
  | 		<res-type>javax.sql.DataSource</res-type>
  | 		<res-auth>Container</res-auth>
  | 	</resource-ref>

photosite-ds.xml

  | <datasources>
  |     <local-tx-datasource>
  |         <jndi-name>photosite</jndi-name>
  |         <connection-url>jdbc:mysql://localhost:3306/photosite</connection-url>
  |         <driver-class>com.mysql.jdbc.Driver</driver-class>
  |         <user-name>zxcbvzxcv</user-name>
  |         <password>asfgasdfgqsd</password>
  | 	  <min-pool-size>1</min-pool-size>
  |         <max-pool-size>5</max-pool-size>
  |     </local-tx-datasource>
  | </datasources>
  | 



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

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



More information about the jboss-user mailing list