[jboss-user] [JBoss Seam] - Re: Embedded EJB Testing Woes

hsoldier do-not-reply at jboss.com
Tue Aug 21 17:36:10 EDT 2007


Hi Mike

your problem is that you are missing a JDBC data source bound in JNDI as "java:/ICTRCoreDatasource"

You will need a data source definition XML file (*-ds.xml) defined and deployed in to $JBOSS_SERVER/server//deploy directory.

The following is an example:


  | <?xml version="1.0" encoding="UTF-8"?>
  | <!DOCTYPE datasources
  |     PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
  |     "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
  | <datasources>
  | 	<local-tx-datasource>
  | 		<jndi-name>ICTRCoreDatasource</jndi-name>
  | 		<connection-url>
  | 			jdbc:mysql://de01.gcrc.umn.edu/mwkohout_ictrcore
  | 		</connection-url>
  | 		<driver-class>com.mysql.jdbc.Driver</driver-class>
  | 		<transaction-isolation>
  | 			TRANSACTION_READ_COMMITTED
  | 		</transaction-isolation>
  | 		<user-name>mwkohout</user-name>
  | 		<password>password</password>
  | 		<min-pool-size>10</min-pool-size>
  | 		<max-pool-size>10</max-pool-size>
  | 		<exception-sorter-class-name>
  | 		org.jboss.resource.adapter.jdbc.vendor.MySQLExceptionSorter
  | 		</exception-sorter-class-name>
  | 		<metadata>
  | 			<type-mapping>mySQL</type-mapping>
  | 		</metadata>		
  | 	</local-tx-datasource>
  | </datasources>
  | 

As far as I know, with JBoss Seam 2.0.0.BETA1 and AS 4.2.0.GA, you no longer need the jboss-beans.xml file. My application does certainly work without one (both in TestNG/Embedded and real deployments).

Hope this helps.

Regards:
Peter


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

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



More information about the jboss-user mailing list