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 acac2bd5d2cd89c54310a8871404035b11d966ce Author: Otavio Rodolfo Piske <[email protected]> AuthorDate: Thu Mar 10 15:41:56 2022 +0100 CAMEL-17763: cleaned up unused exceptions in camel-platform-http --- .../camel/component/platform/http/AbstractPlatformHttpTest.java | 2 +- .../component/platform/http/JettyCustomPlatformHttpConsumer.java | 5 +---- .../org/apache/camel/component/platform/http/PlatformHttpTest.java | 4 ++-- .../platform/http/RestPlatformHttpContextPathConfigurationTest.java | 2 +- 4 files changed, 5 insertions(+), 8 deletions(-) diff --git a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/AbstractPlatformHttpTest.java b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/AbstractPlatformHttpTest.java index 9262821..9265e4a 100644 --- a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/AbstractPlatformHttpTest.java +++ b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/AbstractPlatformHttpTest.java @@ -53,7 +53,7 @@ abstract class AbstractPlatformHttpTest { protected RouteBuilder routes() { return new RouteBuilder() { @Override - public void configure() throws Exception { + public void configure() { } }; } diff --git a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/JettyCustomPlatformHttpConsumer.java b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/JettyCustomPlatformHttpConsumer.java index c790116..182de85 100644 --- a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/JettyCustomPlatformHttpConsumer.java +++ b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/JettyCustomPlatformHttpConsumer.java @@ -17,10 +17,8 @@ package org.apache.camel.component.platform.http; import java.io.BufferedReader; -import java.io.IOException; import java.util.regex.Pattern; -import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; @@ -67,8 +65,7 @@ public class JettyCustomPlatformHttpConsumer extends DefaultConsumer { contextHandler.setHandler(new AbstractHandler() { @Override public void handle( - String s, Request request, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) - throws IOException, ServletException { + String s, Request request, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) { Exchange exchg = null; try { BufferedReader reader = httpServletRequest.getReader(); diff --git a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/PlatformHttpTest.java b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/PlatformHttpTest.java index 5474fe9..cf3e951 100644 --- a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/PlatformHttpTest.java +++ b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/PlatformHttpTest.java @@ -30,7 +30,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; public class PlatformHttpTest extends AbstractPlatformHttpTest { @Test - public void testGet() throws Exception { + public void testGet() { given() .header("Accept", "application/json") .port(port) @@ -61,7 +61,7 @@ public class PlatformHttpTest extends AbstractPlatformHttpTest { protected RouteBuilder routes() { return new RouteBuilder() { @Override - public void configure() throws Exception { + public void configure() { from("platform-http:/get") .setBody().constant("get"); from("platform-http:/post") diff --git a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/RestPlatformHttpContextPathConfigurationTest.java b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/RestPlatformHttpContextPathConfigurationTest.java index 03ce639..9520ec2 100644 --- a/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/RestPlatformHttpContextPathConfigurationTest.java +++ b/components/camel-platform-http/src/test/java/org/apache/camel/component/platform/http/RestPlatformHttpContextPathConfigurationTest.java @@ -41,7 +41,7 @@ public class RestPlatformHttpContextPathConfigurationTest extends AbstractPlatfo protected RouteBuilder routes() { return new RouteBuilder() { @Override - public void configure() throws Exception { + public void configure() { restConfiguration() .component("platform-http") .contextPath("/rest");
