Torque
  1. Torque
  2. TORQUE-196

Make transaction handling pluggable

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0-beta1
    • Component/s: Runtime
    • Labels:
      None

      Description

      Currently, the transaction management cannot be changed by the user on a general basis (i.e. it is possible to handle transactions totally outside Torque by passing a database connection into the methods, but there is no place to plug in an own transaction management into torque).This makes using external transaction management systems (e.g. Spring's @Transactional annotation) difficult.
      To achieve pluggability, the Transaction class should pass all method calls to an implementation class which can be exchanged by an entry in the Torque runtime configuration.

      There are no Sub-Tasks for this issue.

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Resolved Resolved
        1d 23h 43m 1 Thomas Fox 27/Apr/12 03:31
        Resolved Resolved Closed Closed
        150d 4h 35m 1 Thomas Fox 24/Sep/12 08:06
        Thomas Fox made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Thomas Fox made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Thomas Fox [ tfischer ]
        Fix Version/s 4.0 [ 12312102 ]
        Resolution Fixed [ 1 ]
        Hide
        Thomas Fox added a comment -

        The idea is to leave the pubblic interface of the transaction class as and where it is, but make it a holder which delegates all calls to an implementation class which implements an interface TransactionManager (with the same methods as the Transaction class but non-static).
        The default implementation class would be TransactionManagerImpl and would be set in the init method of Torque. Other implementation classes can be specified in the runtime using the key torque.transactionManager

        Show
        Thomas Fox added a comment - The idea is to leave the pubblic interface of the transaction class as and where it is, but make it a holder which delegates all calls to an implementation class which implements an interface TransactionManager (with the same methods as the Transaction class but non-static). The default implementation class would be TransactionManagerImpl and would be set in the init method of Torque. Other implementation classes can be specified in the runtime using the key torque.transactionManager
        Thomas Fox created issue -

          People

          • Assignee:
            Thomas Fox
            Reporter:
            Thomas Fox
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development