Avoid throws Exception where possible - Phase I
* Polishing - PR Comments
This commit is contained in:
committed by
Artem Bilan
parent
005bc80680
commit
b187bca36e
@@ -119,7 +119,7 @@ public class CustomObjectNameTests {
|
||||
public static class HandlerWithCustomObjectName extends AbstractMessageHandler {
|
||||
|
||||
@Override
|
||||
public void handleMessageInternal(Message<?> message) throws Exception {
|
||||
public void handleMessageInternal(Message<?> message) {
|
||||
}
|
||||
|
||||
}
|
||||
@@ -153,7 +153,7 @@ public class CustomObjectNameTests {
|
||||
public static class HandlerWithStandardObjectName extends AbstractMessageHandler {
|
||||
|
||||
@Override
|
||||
protected void handleMessageInternal(Message<?> message) throws Exception {
|
||||
protected void handleMessageInternal(Message<?> message) {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -180,7 +180,7 @@ public class NotificationPublishingChannelAdapterParserTests {
|
||||
public static class FooAdvice extends AbstractRequestHandlerAdvice {
|
||||
|
||||
@Override
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) throws Exception {
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) {
|
||||
adviceCalled++;
|
||||
return callback.execute();
|
||||
}
|
||||
|
||||
@@ -159,7 +159,7 @@ public class OperationInvokingChannelAdapterParserTests {
|
||||
public static class FooAdvice extends AbstractRequestHandlerAdvice {
|
||||
|
||||
@Override
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) throws Exception {
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) {
|
||||
adviceCalled++;
|
||||
return callback.execute();
|
||||
}
|
||||
|
||||
@@ -163,7 +163,7 @@ public class OperationInvokingOutboundGatewayTests {
|
||||
public static class FooAdvice extends AbstractRequestHandlerAdvice {
|
||||
|
||||
@Override
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) throws Exception {
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) {
|
||||
adviceCalled++;
|
||||
return callback.execute();
|
||||
}
|
||||
|
||||
@@ -318,12 +318,11 @@ public class IdempotentReceiverIntegrationTests {
|
||||
}
|
||||
|
||||
@Bean
|
||||
public Advice fooAdvice(final AtomicInteger adviceCalled) {
|
||||
public Advice fooAdvice(@SuppressWarnings("unused") final AtomicInteger adviceCalled) {
|
||||
return new AbstractRequestHandlerAdvice() {
|
||||
|
||||
@Override
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message)
|
||||
throws Exception {
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) {
|
||||
adviceCalled.incrementAndGet();
|
||||
return callback.execute();
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ public class TransformerContextTests {
|
||||
public static class FooAdvice extends AbstractRequestHandlerAdvice {
|
||||
|
||||
@Override
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) throws Exception {
|
||||
protected Object doInvoke(ExecutionCallback callback, Object target, Message<?> message) {
|
||||
adviceCalled++;
|
||||
return callback.execute();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user