Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-2953

Dump the information about rollbacks of the global transaction (introduced in DERBY-2220 and DERBY-2432) to derby.log

    Details

    • Type: Improvement
    • Status: In Progress
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: JDBC
    • Urgency:
      Low

      Description

      When the global transaction is going to be rolled back that information should be dumped to derby.log so that users can find out what happened.

      1. d2953.stat
        0.6 kB
        Julius Stroffek
      2. d2953.diff
        11 kB
        Julius Stroffek

        Issue Links

          Activity

          Hide
          kmarsden Kathey Marsden added a comment -

          Unassigning due to inactivity.

          Show
          kmarsden Kathey Marsden added a comment - Unassigning due to inactivity.
          Hide
          kmarsden Kathey Marsden added a comment -

          Julius, Are you still working on this issue? Can you unassign yourself if you are not?

          Show
          kmarsden Kathey Marsden added a comment - Julius, Are you still working on this issue? Can you unassign yourself if you are not?
          Hide
          dyret Dyre Tjeldvoll added a comment -

          Is this issue a true subset of DERBY-2871?

          When I apply the patch for this issue and sort out the conflicts, the only difference I see is that CancelXATransactionTask.run() now catches only XAExceptions, whereas in DERBY-2871 it catches Throwable. Normally it is not a good idea to catch Throwable, but I don't know if uncaught exceptions from the run()-method of a timer gets reported elsewhere... does anyone know?

          Show
          dyret Dyre Tjeldvoll added a comment - Is this issue a true subset of DERBY-2871 ? When I apply the patch for this issue and sort out the conflicts, the only difference I see is that CancelXATransactionTask.run() now catches only XAExceptions, whereas in DERBY-2871 it catches Throwable. Normally it is not a good idea to catch Throwable, but I don't know if uncaught exceptions from the run()-method of a timer gets reported elsewhere... does anyone know?
          Hide
          julo Julius Stroffek added a comment -

          I removed fix-version info.

          Show
          julo Julius Stroffek added a comment - I removed fix-version info.
          Hide
          dyret Dyre Tjeldvoll added a comment -

          This issue is targeted for 10.4, but has not been updated in 2008. Should the fix-version be changed/removed?

          Show
          dyret Dyre Tjeldvoll added a comment - This issue is targeted for 10.4, but has not been updated in 2008. Should the fix-version be changed/removed?
          Hide
          dyret Dyre Tjeldvoll added a comment -

          Hi Julio,

          I could still apply the patch, and both test suites ran successfully for me. Overall the patch looks good. I'm just a bit curious about why some of the new methods have javadoc and some do not. Some have a good description that is not valid javadoc (e.g. without any tags). Was this intentional? I'm never sure when javadoc is required and when it is optional.

          Show
          dyret Dyre Tjeldvoll added a comment - Hi Julio, I could still apply the patch, and both test suites ran successfully for me. Overall the patch looks good. I'm just a bit curious about why some of the new methods have javadoc and some do not. Some have a good description that is not valid javadoc (e.g. without any tags). Was this intentional? I'm never sure when javadoc is required and when it is optional.
          Hide
          julo Julius Stroffek added a comment -

          I ran derbyall and suites.All.

          In derbyall the wisconsin test failed which is happening also on daily tests.

          In suites.All the lang.LangScripts test failed. The same failure occurs to me also on plain trunk. I have posted details to derby-dev.

          Except the messages being logged I also changed to code in DRDAXAProtocol that it will indirectly use the XATransactionState.cancel method to cancel the transaction. This will lead to the atomic transaction disassociation and rollback being performed in one synchronized block on the corresponding XATransactionState instance.

          The best way which I found to do that is to add a method cancelXATransaction to ResourceAdapter which will find the appropriate XATransactionState instance and will call the cancel method. The reference to the ResourceAdapter is kept in drda.XADatabase object instance.

          Show
          julo Julius Stroffek added a comment - I ran derbyall and suites.All. In derbyall the wisconsin test failed which is happening also on daily tests. In suites.All the lang.LangScripts test failed. The same failure occurs to me also on plain trunk. I have posted details to derby-dev. — Except the messages being logged I also changed to code in DRDAXAProtocol that it will indirectly use the XATransactionState.cancel method to cancel the transaction. This will lead to the atomic transaction disassociation and rollback being performed in one synchronized block on the corresponding XATransactionState instance. The best way which I found to do that is to add a method cancelXATransaction to ResourceAdapter which will find the appropriate XATransactionState instance and will call the cancel method. The reference to the ResourceAdapter is kept in drda.XADatabase object instance.
          Hide
          julo Julius Stroffek added a comment -

          I think this is the work that will help to find out what is going on (went wrong) in the test.

          Show
          julo Julius Stroffek added a comment - I think this is the work that will help to find out what is going on (went wrong) in the test.

            People

            • Assignee:
              Unassigned
              Reporter:
              julo Julius Stroffek
            • Votes:
              1 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:

                Development