This is an automated email from the ASF dual-hosted git repository.

orpiske pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 9f550dc8b3d70cd39c35f754af74afead161a337
Author: Otavio Rodolfo Piske <[email protected]>
AuthorDate: Tue Apr 12 16:46:44 2022 +0200

    CAMEL-17763: cleaned up unused exceptions in camel-jt400
---
 .../Jt400ComponentDefaultConnectionPoolTest.java   |  2 +-
 ...00ComponentDefaultSecureConnectionPoolTest.java |  2 +-
 .../camel/component/jt400/Jt400ComponentTest.java  |  2 +-
 .../jt400/Jt400MultipleConsumersRouteTest.java     |  4 +--
 .../camel/component/jt400/Jt400PgmRouteTest.java   |  4 +--
 .../camel/component/jt400/Jt400RouteTest.java      |  4 +--
 .../component/jt400/MockAS400ConnectionPool.java   |  6 ++---
 .../jt400/MockAS400SecureConnectionPool.java       | 29 +++++++++-------------
 8 files changed, 24 insertions(+), 29 deletions(-)

diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultConnectionPoolTest.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultConnectionPoolTest.java
index 60b78ef1979..210fc223839 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultConnectionPoolTest.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultConnectionPoolTest.java
@@ -46,7 +46,7 @@ public class Jt400ComponentDefaultConnectionPoolTest extends 
Jt400TestSupport {
 
     @Override
     @AfterEach
-    public void tearDown() throws Exception {
+    public void tearDown() {
         if (component != null) {
             component.stop();
         }
diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultSecureConnectionPoolTest.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultSecureConnectionPoolTest.java
index 3a0d4a59d71..85404502188 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultSecureConnectionPoolTest.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentDefaultSecureConnectionPoolTest.java
@@ -46,7 +46,7 @@ public class Jt400ComponentDefaultSecureConnectionPoolTest 
extends Jt400TestSupp
 
     @Override
     @AfterEach
-    public void tearDown() throws Exception {
+    public void tearDown() {
         if (component != null) {
             component.stop();
         }
diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentTest.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentTest.java
index 2b942560649..697879aca74 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentTest.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400ComponentTest.java
@@ -66,7 +66,7 @@ public class Jt400ComponentTest extends Jt400TestSupport {
      * Test exception when trying to access any other object type on AS/400
      */
     @Test
-    public void testCreateEndpointForOtherObjectType() throws Exception {
+    public void testCreateEndpointForOtherObjectType() {
         try {
             
component.createEndpoint("jt400://user:password@host/qsys.lib/library.lib/program.xxx");
             fail("Exception should been thrown when trying to create an 
endpoint for an unsupported object type");
diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400MultipleConsumersRouteTest.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400MultipleConsumersRouteTest.java
index d77d9cfce11..6ef64a1895b 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400MultipleConsumersRouteTest.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400MultipleConsumersRouteTest.java
@@ -47,11 +47,11 @@ public class Jt400MultipleConsumersRouteTest extends 
CamelTestSupport {
     }
 
     @Override
-    protected RouteBuilder createRouteBuilder() throws Exception {
+    protected RouteBuilder createRouteBuilder() {
         return new RouteBuilder() {
 
             @Override
-            public void configure() throws Exception {
+            public void configure() {
                 if (SYSTEM != null) {
                     String uri = 
String.format("jt400://%s:%s@%s/QSYS.LIB/%s.LIB/%s.DTAQ", USER, PASSWORD,
                             SYSTEM, LIBRARY, QUEUE);
diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400PgmRouteTest.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400PgmRouteTest.java
index 63f15b47733..bb5a3abfd8b 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400PgmRouteTest.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400PgmRouteTest.java
@@ -75,11 +75,11 @@ public class Jt400PgmRouteTest extends CamelTestSupport {
     }
 
     @Override
-    protected RouteBuilder createRouteBuilder() throws Exception {
+    protected RouteBuilder createRouteBuilder() {
         return new RouteBuilder() {
 
             @Override
-            public void configure() throws Exception {
+            public void configure() {
                 if (SYSTEM != null) {
                     String uri = String
                             
.format("jt400://%s:%s@%s/QSYS.LIB/%s.LIB/%s.pgm?outputFieldsIdx=%s&fieldsLength=%s",
diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400RouteTest.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400RouteTest.java
index a67eb4243b7..c88c4d14ed9 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400RouteTest.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/Jt400RouteTest.java
@@ -47,11 +47,11 @@ public class Jt400RouteTest extends CamelTestSupport {
     }
 
     @Override
-    protected RouteBuilder createRouteBuilder() throws Exception {
+    protected RouteBuilder createRouteBuilder() {
         return new RouteBuilder() {
 
             @Override
-            public void configure() throws Exception {
+            public void configure() {
                 if (SYSTEM != null) {
                     String uri = 
String.format("jt400://%s:%s@%s/QSYS.LIB/%s.LIB/%s.DTAQ", USER, PASSWORD,
                             SYSTEM, LIBRARY, QUEUE);
diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400ConnectionPool.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400ConnectionPool.java
index 0e9099d10e4..9c8dcce1b5b 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400ConnectionPool.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400ConnectionPool.java
@@ -36,18 +36,18 @@ public class MockAS400ConnectionPool extends 
AS400ConnectionPool {
 
     @Deprecated
     @Override
-    public AS400 getConnection(String systemName, String userID) throws 
ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID) {
         throw new UnsupportedOperationException();
     }
 
     @Deprecated
     @Override
-    public AS400 getConnection(String systemName, String userID, int service) 
throws ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID, int service) {
         throw new UnsupportedOperationException();
     }
 
     @Override
-    public AS400 getConnection(String systemName, String userID, String 
password) throws ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID, String 
password) {
         return new AS400(systemName, userID, password);
     }
 
diff --git 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400SecureConnectionPool.java
 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400SecureConnectionPool.java
index 492b17ee45b..00d1c6fb44f 100644
--- 
a/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400SecureConnectionPool.java
+++ 
b/components/camel-jt400/src/test/java/org/apache/camel/component/jt400/MockAS400SecureConnectionPool.java
@@ -20,7 +20,6 @@ import java.util.Locale;
 
 import com.ibm.as400.access.AS400;
 import com.ibm.as400.access.AS400ConnectionPool;
-import com.ibm.as400.access.ConnectionPoolException;
 import com.ibm.as400.security.auth.ProfileTokenCredential;
 
 /**
@@ -34,70 +33,66 @@ public class MockAS400SecureConnectionPool extends 
AS400ConnectionPool {
     }
 
     @Override
-    public AS400 getSecureConnection(String systemName, String userID, String 
password) throws ConnectionPoolException {
+    public AS400 getSecureConnection(String systemName, String userID, String 
password) {
         return new AS400(systemName, userID, password);
     }
 
     @Deprecated
     @Override
-    public AS400 getSecureConnection(String systemName, String userID) throws 
ConnectionPoolException {
+    public AS400 getSecureConnection(String systemName, String userID) {
         throw new UnsupportedOperationException();
     }
 
     @Override
-    public AS400 getSecureConnection(String systemName, String userID, String 
password, int i) throws ConnectionPoolException {
+    public AS400 getSecureConnection(String systemName, String userID, String 
password, int i) {
         return new AS400(systemName, userID, password);
     }
 
     @Deprecated
     @Override
-    public AS400 getSecureConnection(String systemName, String userID, int i) 
throws ConnectionPoolException {
+    public AS400 getSecureConnection(String systemName, String userID, int i) {
         throw new UnsupportedOperationException();
     }
 
     @Override
-    public AS400 getSecureConnection(String systemName, String userID, 
ProfileTokenCredential profileTokenCredential)
-            throws ConnectionPoolException {
+    public AS400 getSecureConnection(String systemName, String userID, 
ProfileTokenCredential profileTokenCredential) {
         return new AS400(systemName, userID);
     }
 
     @Override
-    public AS400 getSecureConnection(String systemName, String userID, 
ProfileTokenCredential profileTokenCredential, int i)
-            throws ConnectionPoolException {
+    public AS400 getSecureConnection(String systemName, String userID, 
ProfileTokenCredential profileTokenCredential, int i) {
         return new AS400(systemName, userID);
     }
 
     @Deprecated
     @Override
-    public AS400 getConnection(String systemName, String userID) throws 
ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID) {
         throw new UnsupportedOperationException();
     }
 
     @Deprecated
     @Override
-    public AS400 getConnection(String systemName, String userID, int service) 
throws ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID, int service) {
         throw new UnsupportedOperationException();
     }
 
     @Override
-    public AS400 getConnection(String systemName, String userID, String 
password) throws ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID, String 
password) {
         throw new UnsupportedOperationException();
     }
 
     @Override
-    public AS400 getConnection(String systemName, String userID, String 
password, int service) throws ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID, String 
password, int service) {
         throw new UnsupportedOperationException();
     }
 
     @Override
-    public AS400 getConnection(String systemName, String userID, String 
password, int service, Locale locale)
-            throws ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID, String 
password, int service, Locale locale) {
         throw new UnsupportedOperationException();
     }
 
     @Override
-    public AS400 getConnection(String systemName, String userID, String 
password, Locale locale)
-            throws ConnectionPoolException {
+    public AS400 getConnection(String systemName, String userID, String 
password, Locale locale) {
         throw new UnsupportedOperationException();
     }
 

Reply via email to