Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] JTA and driver class name

It's exactly what we wanted. Thanks.

Zdnek Machac

Dne 25.2.2010 17:44, Andrei Ilitchev napsal(a):
Consider overriding org.eclipse.persistence.sessions.JNDIConnector class
and setting the custom connector into the session in SessionCustomizer:
// Set a new Connector for writing
session.getLogin().setConnector(new MyJNDIConnector());
// Set a new Connector for reading
((DatabaseLogin)((ServerSession)session).getReadConnectionPool().getLogin()).setConnector(new
MyJNDIConnector());
----- Original Message ----- From: "Zdenek Machac" <xmachac2@xxxxxxxx>
To: <eclipselink-users@xxxxxxxxxxx>
Sent: Thursday, February 25, 2010 11:15 AM
Subject: Re: [eclipselink-users] JTA and driver class name


Hi,

internal user/password is not used for creating connection to DB (it's
other user/password
registered in server configuration of connection pool), but for
obtaining DataSource from
JNDI (JNDI resource is protected).

Zdenek Machac


Dne 25.2.2010 15:46, Andrei Ilitchev napsal(a):
You can use the original JTA datasource and specify userName and
password - then Eclipselink will obtain connections using
ds.getConnection(userName, password).
----- Original Message ----- From: "Zdenek Machac" <xmachac2@xxxxxxxx>
To: "EclipseLink User Discussions" <eclipselink-users@xxxxxxxxxxx>
Sent: Thursday, February 25, 2010 6:42 AM
Subject: [eclipselink-users] JTA and driver class name


Hallo,

we use OpenJPA implementation in Weblogic 10.3 cluster environment but
we want to migrate to EclipseLink (Oracle TopLink). But there is one
stopper.

We use DB connection (DataSource) maped as global JNDI with custom
user access (only one internal user can access this JNDI resource).
Therefore we can not use direct JNDI string in persistence.xml becase
only described user can obtain connection instance from JNDI.

If we try use JTA and specify driver name EclipseLink JPA says:

"PersistenceUnitInfo ProjektPU has transactionType JTA, but doesnt
have jtaDataSource"

Is there any way to specify transaction-type="JTA" without
jta-data-source and use property

<property name="eclipselink.jdbc.driver" value=" ... "/>

with own implementation driver class name which wrap obtaining DB
connection from JNDI?

Thanks.

Zdenek Machac

_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users


_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users


_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users


_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users




Back to the top