users@glassfish.java.net

Junit test case works only in jdbc/__default datasource

From: <forums_at_java.net>
Date: Tue, 22 Nov 2011 09:58:15 -0600 (CST)

I wrote a testcase with embedded GlassFish for testing an EJB.

When I tried to test it using jdbc/mydb as datasource (in persistence.xml) I
got the following error

Exception while preparing the app : Invalid resource : jdbc/mydb__pm
com.sun.appserv.connectors.internal.api.ConnectorRuntimeException: Invalid
resource : jdbc/mydb__pm
When I changed the datasource to jdbc/__default with the same connection pool
as of jdbc/mydb it worked perfect.

Why is it so? What is the difference between these two datasources?


--
[Message sent by forum member 'abinmd']
View Post: http://forums.java.net/node/866706