db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lily Wei (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-4314) With derby client setTransactionIsolation executes and commits even if isolation has not changed
Date Fri, 18 Sep 2009 03:13:57 GMT

    [ https://issues.apache.org/jira/browse/DERBY-4314?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12756932#action_12756932

Lily Wei commented on DERBY-4314:

Thanks Kristian. I apply the patch. I don't know about your question to DRDA standard. 
I run it against the repro from DERBY-4343 TestConnReuser.java. I got the ASSERT failure with
defaultisolation change. This is my output from running TestConnReuse.java
$ java TestConnReuse
count = 22
Seccond Connection. Reuse Connection
Third Connection. Set same isolation
Exception in thread "main" org.apache.derby.shared.common.sanity.AssertFailure:
        at org.apache.derby.shared.common.sanity.SanityManager.ASSERT(SanityMana
        at org.apache.derby.client.am.Connection.setTransactionIsolationX(Connec
        at org.apache.derby.client.am.Connection.setTransactionIsolation(Connect
        at org.apache.derby.client.am.LogicalConnection.setTransactionIsolation(
        at TestConnReuse.main(TestConnReuse.java:33)
Stack traces for all live threads:
Thread name=Finalizer id=3 priority=8 state=WAITING isdaemon=true
        java.lang.Object.wait(Native Method)
        java.lang.ref.ReferenceQueue.remove(Unknown Source)
        java.lang.ref.ReferenceQueue.remove(Unknown Source)
        java.lang.ref.Finalizer$FinalizerThread.run(Unknown Source)

Thread name=main id=1 priority=5 state=RUNNABLE isdaemon=false
        java.lang.Thread.dumpThreads(Native Method)
        java.lang.Thread.getAllStackTraces(Unknown Source)
        sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        java.lang.reflect.Method.invoke(Unknown Source)

Do you think I am missing something?

> With derby client setTransactionIsolation executes and commits even if isolation has
not changed 
> -------------------------------------------------------------------------------------------------
>                 Key: DERBY-4314
>                 URL: https://issues.apache.org/jira/browse/DERBY-4314
>             Project: Derby
>          Issue Type: Improvement
>          Components: JDBC, Network Client
>    Affects Versions:,,,,,
>            Reporter: Kathey Marsden
>            Priority: Minor
>         Attachments: DERBY-4314-2.diff, DERBY-4314-3.diff, DERBY-4314-5.diff, derby-4314-6a-initial_piggybacking.diff,
derby-4314-6a-initial_piggybacking.stat, DERBY-4314.diff
> With in EmbedConnection.setIsolation() we have a check to see if the isolation level
is the same and if so just return without doing a commit:
>   public void setTransactionIsolation(int level) throws SQLException {
> 		if (level == getTransactionIsolation())
> 			return;
> with org.apache.derby.client.am.Connection we have no such check. It would be good if
the client driver acted like embedded.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message