Uploaded image for project: 'JBoss Transaction Manager'
  1. JBoss Transaction Manager
  2. JBTM-3070

Quickstart for transaction driver should not be using reflection

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Done
    • Minor
    • 5.9.5.Final
    • None
    • None
    • None

    Description

      Currently the quickstart of transaction driver standalone uses reflection for forcibly closing H2 connection. It was used as a way to overcome the H2 issues with XA connection.

      As the quickstart tests recovery it arbitrary throws an exception. This makes issue for H2 as it consider the connection as unfinished but if we close it it does not care and sets autocommit to true and let all the changes being immediately propagated to database.
      That's what we don't want as we test recovery and we expect recovery to finish the in-doubt data.
      The issue is only for H2 behaviour. "Normal" databases as PostgreSQL makes checks on unfinished transaction in jdbc driver and their decisions are based on it.

      Nevertheless using reflection is not a good habit and it's a hacky. For quickstarts it should not be the case. There needs to be a way how to avoid it.

      Attachments

        Activity

          People

            ochaloup@redhat.com Ondrej Chaloupka (Inactive)
            ochaloup@redhat.com Ondrej Chaloupka (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: