tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jaime Geovane Marcondes <jaime.marcon...@gmail.com>
Subject LocalInitialContextFactory - DataSource JNDI
Date Wed, 18 Jun 2008 14:34:55 GMT

Hello!

    OpenEJB is amazing to boost the development of EJB3.0.
    I tried to configure OpenEJB to run in Local Mode, for debugging
purposes. When it runs, the log shows:

    javax.naming.NameNotFoundException: Name "jdbc_SecurityDS" not found

    I then tried to configure in ejb-jar.xml, but it didn't work.
    But the log shows:

   2008-06-18 11:22:57,671 - INFO  - Creating Resource(id=jdbc_SecurityDS)

    And then:
2008-06-18 11:22:58,125 - DEBUG - finished invoking method getMovement with
exception java.sql.SQLException: Name "jdbc_SecurityDS" not found.

    My openejb.conf:
<openejb>
	<Resource id="jdbc/SecurityDS" type="DataSource">
	    JdbcDriver  oracle.jdbc.driver.OracleDriver
	    JdbcUrl     jdbc:oracle:thin:@xxx.xx.xx.xxx:9921:source
	    UserName    sec_usr
	    Password    sec_usr
	</Resource>

	
	<Deployments dir="C:\projects\Services\classes\" />
	<Deployments jar="C:\temp\deploy\Services.jar" />
</openejb>


    My ejb-jar.xml:    
<?xml version="1.0" encoding="UTF-8"?>
<ejb-jar>
	<enterprise-beans>
		<session>
			<ejb-name>AccountService</ejb-name>
			<remote>
				acme.com.accountservices.both.iface.AccountServices
			</remote>
			<ejb-class>
				acme.com.accountservices.server.ejb.AccountServicesBean
			</ejb-class>
			<session-type>Stateless</session-type>
			<transaction-type>Container</transaction-type>
			<resource-ref>
				<res-ref-name>jdbc/SegurancaDS</res-ref-name>
				<res-type>javax.sql.DataSource</res-type>
				<auth-type>Container</auth-type>
			</resource-ref>
		</session>
	</enterprise-beans>
</ejb-jar>


    Thank's for help!

-- 
View this message in context: http://www.nabble.com/LocalInitialContextFactory---DataSource-JNDI-tp17984063p17984063.html
Sent from the OpenEJB User mailing list archive at Nabble.com.


Mime
View raw message