Skip to content

Commit 2437055

Browse files
committed
Migrated javax.transaction to jakarta.transaction
1 parent 4cf27d6 commit 2437055

18 files changed

+79
-60
lines changed

pom.xml

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,19 @@
8888
<dependency>
8989
<groupId>jakarta.transaction</groupId>
9090
<artifactId>jakarta.transaction-api</artifactId>
91-
<version>1.3.3</version>
91+
<version>2.0.1</version>
92+
</dependency>
93+
<dependency>
94+
<groupId>jakarta.enterprise</groupId>
95+
<artifactId>jakarta.enterprise.cdi-api</artifactId>
96+
<version>4.1.0</version>
97+
<scope>provided</scope>
98+
</dependency>
99+
<dependency>
100+
<groupId>jakarta.interceptor</groupId>
101+
<artifactId>jakarta.interceptor-api</artifactId>
102+
<version>2.2.0</version>
103+
<scope>provided</scope>
92104
</dependency>
93105
<!-- tomcat naming jars for jndi reference tests -->
94106
<dependency>
@@ -105,10 +117,11 @@
105117
</dependency>
106118
<!-- for testing of managed connections -->
107119
<dependency>
108-
<groupId>org.apache.geronimo.modules</groupId>
120+
<groupId>org.apache.geronimo.components</groupId>
109121
<artifactId>geronimo-transaction</artifactId>
110-
<version>2.2.1</version>
122+
<version>3.1.5</version>
111123
<scope>test</scope>
124+
<classifier>jakarta</classifier>
112125
<exclusions>
113126
<exclusion>
114127
<artifactId>org.junit.jupiter</artifactId>
@@ -136,7 +149,13 @@
136149
<groupId>org.jboss.narayana.jta</groupId>
137150
<artifactId>narayana-jta</artifactId>
138151
<!-- Versions >= 5.13.0 require Java 11 -->
139-
<version>5.12.7.Final</version>
152+
<version>6.0.3.Final</version>
153+
<scope>test</scope>
154+
</dependency>
155+
<dependency>
156+
<groupId>jakarta.el</groupId>
157+
<artifactId>jakarta.el-api</artifactId>
158+
<version>5.0.1</version>
140159
<scope>test</scope>
141160
</dependency>
142161
<dependency>

src/main/java/org/apache/commons/dbcp2/managed/BasicManagedDataSource.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020

2121
import javax.sql.DataSource;
2222
import javax.sql.XADataSource;
23-
import javax.transaction.TransactionManager;
24-
import javax.transaction.TransactionSynchronizationRegistry;
23+
import jakarta.transaction.TransactionManager;
24+
import jakarta.transaction.TransactionSynchronizationRegistry;
2525

2626
import org.apache.commons.dbcp2.BasicDataSource;
2727
import org.apache.commons.dbcp2.ConnectionFactory;

src/main/java/org/apache/commons/dbcp2/managed/DataSourceXAConnectionFactory.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525
import javax.sql.PooledConnection;
2626
import javax.sql.XAConnection;
2727
import javax.sql.XADataSource;
28-
import javax.transaction.TransactionManager;
29-
import javax.transaction.TransactionSynchronizationRegistry;
28+
import jakarta.transaction.TransactionManager;
29+
import jakarta.transaction.TransactionSynchronizationRegistry;
3030
import javax.transaction.xa.XAResource;
3131

3232
import org.apache.commons.dbcp2.Utils;

src/main/java/org/apache/commons/dbcp2/managed/LocalXAConnectionFactory.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020
import java.sql.SQLException;
2121
import java.util.Objects;
2222

23-
import javax.transaction.TransactionManager;
24-
import javax.transaction.TransactionSynchronizationRegistry;
23+
import jakarta.transaction.TransactionManager;
24+
import jakarta.transaction.TransactionSynchronizationRegistry;
2525
import javax.transaction.xa.XAException;
2626
import javax.transaction.xa.XAResource;
2727
import javax.transaction.xa.Xid;

src/main/java/org/apache/commons/dbcp2/managed/SynchronizationAdapter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
*/
1717
package org.apache.commons.dbcp2.managed;
1818

19-
import javax.transaction.Synchronization;
19+
import jakarta.transaction.Synchronization;
2020

2121
/**
2222
* Implements {@link Synchronization} for subclasses.

src/main/java/org/apache/commons/dbcp2/managed/TransactionContext.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@
2121
import java.sql.SQLException;
2222
import java.util.Objects;
2323

24-
import javax.transaction.RollbackException;
25-
import javax.transaction.Status;
26-
import javax.transaction.Synchronization;
27-
import javax.transaction.SystemException;
28-
import javax.transaction.Transaction;
29-
import javax.transaction.TransactionSynchronizationRegistry;
24+
import jakarta.transaction.RollbackException;
25+
import jakarta.transaction.Status;
26+
import jakarta.transaction.Synchronization;
27+
import jakarta.transaction.SystemException;
28+
import jakarta.transaction.Transaction;
29+
import jakarta.transaction.TransactionSynchronizationRegistry;
3030
import javax.transaction.xa.XAResource;
3131

3232
/**

src/main/java/org/apache/commons/dbcp2/managed/TransactionRegistry.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222
import java.util.Objects;
2323
import java.util.WeakHashMap;
2424

25-
import javax.transaction.SystemException;
26-
import javax.transaction.Transaction;
27-
import javax.transaction.TransactionManager;
28-
import javax.transaction.TransactionSynchronizationRegistry;
25+
import jakarta.transaction.SystemException;
26+
import jakarta.transaction.Transaction;
27+
import jakarta.transaction.TransactionManager;
28+
import jakarta.transaction.TransactionSynchronizationRegistry;
2929
import javax.transaction.xa.XAResource;
3030

3131
import org.apache.commons.dbcp2.DelegatingConnection;

src/test/java/org/apache/commons/dbcp2/managed/TestBasicManagedDataSource.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ Licensed to the Apache Software Foundation (ASF) under one or more
2828
import java.sql.SQLException;
2929

3030
import javax.sql.XADataSource;
31-
import javax.transaction.TransactionManager;
32-
import javax.transaction.TransactionSynchronizationRegistry;
31+
import jakarta.transaction.TransactionManager;
32+
import jakarta.transaction.TransactionSynchronizationRegistry;
3333
import javax.transaction.xa.XAException;
3434

3535
import org.apache.commons.dbcp2.BasicDataSource;

src/test/java/org/apache/commons/dbcp2/managed/TestConnectionWithNarayana.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ Licensed to the Apache Software Foundation (ASF) under one or more
2828
import java.sql.Timestamp;
2929
import java.time.Duration;
3030

31-
import javax.transaction.RollbackException;
32-
import javax.transaction.Status;
31+
import jakarta.transaction.RollbackException;
32+
import jakarta.transaction.Status;
3333

3434
import org.apache.commons.dbcp2.Utils;
3535
import org.junit.jupiter.api.AfterEach;

src/test/java/org/apache/commons/dbcp2/managed/TestManagedConnection.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,13 @@ Licensed to the Apache Software Foundation (ASF) under one or more
2626
import java.time.Duration;
2727
import java.util.Properties;
2828

29-
import javax.transaction.HeuristicMixedException;
30-
import javax.transaction.HeuristicRollbackException;
31-
import javax.transaction.RollbackException;
32-
import javax.transaction.Synchronization;
33-
import javax.transaction.SystemException;
34-
import javax.transaction.Transaction;
35-
import javax.transaction.TransactionManager;
29+
import jakarta.transaction.HeuristicMixedException;
30+
import jakarta.transaction.HeuristicRollbackException;
31+
import jakarta.transaction.RollbackException;
32+
import jakarta.transaction.Synchronization;
33+
import jakarta.transaction.SystemException;
34+
import jakarta.transaction.Transaction;
35+
import jakarta.transaction.TransactionManager;
3636
import javax.transaction.xa.XAResource;
3737

3838
import org.apache.commons.dbcp2.ConnectionFactory;

0 commit comments

Comments
 (0)