Jagadish,
1. > What type of datasource ? javax.sql.XADS / ConnectionPoolDS / DS ?
I defined the data source using Admin Console using the following settings:
Datasource Classname: oracle.jdbc.pool.OracleDataSource;
Resource Type: javax.sql.DataSource
properties: user, password, URL
default settings for everything else.
2. > Can you check the default autocommit value of the connection in
stand-alone (non-EE) mode ?
In a simple standalone test the connection obtained from
oracle.jdbc.pool.OracleDataSource has autoCommit set to true.
3. > If the datasource is not a XADataSource, can you please enable logging
to FINE for "connector" module and see whether
> "ConnectorXAResource.end() called" is logged for a non-tx connection.
If you tell me how to do it and it's not too time consuming I can do it.
Currently I only have entity-persistence and entity-persistence-tests
sources.
Also I have glassfish installation in publish folder created for running
appserver tests.
Thanks,
Andrei
----- Original Message -----
From: "Jagadish Prasath Ramu" <Jagadish.Ramu_at_Sun.COM>
To: <dev_at_glassfish.dev.java.net>; "Sanjeeb Kumar Sahoo"
<Sanjeeb.Sahoo_at_Sun.COM>
Sent: Thursday, February 01, 2007 1:14 AM
Subject: Re: Problems with container persistence.xml processing and
non-jtaconnection pooling.
> On Wed, 2007-01-31 at 22:35 +0530, Sanjeeb Kumar Sahoo wrote:
>> Andrei Ilitchev wrote:
>> > While fixing issue 2106 I ran upon the following problems in container:
>> > 1. Even though no non-jta data source was specified in persistence.xml
>> > a non-jta data source was created and passed to TopLink to be used for
>> > reading.
>> > That doesn't seem to be spec. complient.
>> Reading the following javadocs comment as specified in section #7.1.4 of
>> JPA spec, I think it is perfectly fine for a container to supply a
>> non-jta-data-source object even if user did not specify a value in p.xml.
>> /**
>> * @return The non-JTA-enabled data source to be used by the
>> * persistence provider for accessing data outside a JTA
>> * transaction.
>> * The data source corresponds to the named <non-jta-data-source>
>> * element in the persistence.xml file or provided at
>> * deployment or by the container.
>> */
>> public DataSource getNonJtaDataSource();
>>
>> > 2. Non-jta connection pool produces connections with autoCommit set to
>> > false.
>> > 3. After connection obtained from non-jta data source is closed it
>> > still holds the locks.
>> Jagadish, can you comment on #2 & #3? FYI, we use
>> /ConnectorRuntime.getRuntime().lookupNonTxResource(DSName)/ to get hold
>> of this data source.
>>>From the tests I have, it works fine. JDBC-RA does not change the
> autocommit value of connections in non-tx mode.
>
> What type of datasource ? javax.sql.XADS / ConnectionPoolDS / DS ?
>
> Can you check the default autocommit value of the connection in
> stand-alone (non-EE) mode ?
>
> If the datasource is not a XADataSource, can you please enable logging
> to FINE for "connector" module and see whether
> "ConnectorXAResource.end() called" is logged for a non-tx connection.
>
> Thanks,
> -Jagadish
>
>>
>> Thanks,
>> Sahoo
>> >
>> > For more details please see
>> > https://glassfish.dev.java.net/issues/show_bug.cgi?id=2106
>> >
>> > Thanks,
>> >
>> > Andrei
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
>> > For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>> >
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>
>