db-torque-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thomas Vandahl (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (TORQUE-350) Make use of try-with-resources possible with Torque transactions
Date Mon, 27 Aug 2018 08:49:00 GMT

     [ https://issues.apache.org/jira/browse/TORQUE-350?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Thomas Vandahl resolved TORQUE-350.
-----------------------------------
    Resolution: Implemented
      Assignee: Thomas Vandahl

I chose a wrapper instead of a proxy. TorqueException now extends SQLException!

> Make use of try-with-resources possible with Torque transactions
> ----------------------------------------------------------------
>
>                 Key: TORQUE-350
>                 URL: https://issues.apache.org/jira/browse/TORQUE-350
>             Project: Torque
>          Issue Type: Improvement
>          Components: Runtime, Templates
>    Affects Versions: 4.0
>            Reporter: Thomas Vandahl
>            Assignee: Thomas Vandahl
>            Priority: Major
>             Fix For: 4.1
>
>
> We use the java.sql.Connection to wrap database operations into transactions. As of Java7,
Connection is AutoCloseable. I propose to introduce a dynamic proxy to catch the close call
and implement the pattern as described in https://db.apache.org/torque/torque-4.0/documentation/orm-reference/connections-transactions.html




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org


Mime
View raw message