Fix Checkstyle violations
https://build.spring.io/browse/INT-SI43X-192/
This commit is contained in:
@@ -310,14 +310,14 @@ public abstract class AbstractAmqpOutboundEndpoint extends AbstractReplyProducin
|
||||
|
||||
protected MessageChannel getConfirmAckChannel() {
|
||||
if (this.confirmAckChannel == null && this.confirmAckChannelName != null) {
|
||||
this.confirmAckChannel = getChannelResolver().resolveDestination(confirmAckChannelName);
|
||||
this.confirmAckChannel = getChannelResolver().resolveDestination(this.confirmAckChannelName);
|
||||
}
|
||||
return this.confirmAckChannel;
|
||||
}
|
||||
|
||||
protected MessageChannel getConfirmNackChannel() {
|
||||
if (this.confirmNackChannel == null && this.confirmNackChannelName != null) {
|
||||
this.confirmNackChannel = getChannelResolver().resolveDestination(confirmNackChannelName);
|
||||
this.confirmNackChannel = getChannelResolver().resolveDestination(this.confirmNackChannelName);
|
||||
}
|
||||
return this.confirmNackChannel;
|
||||
}
|
||||
|
||||
@@ -43,15 +43,18 @@ public class AmqpMessageHeaderErrorMessageStrategy implements ErrorMessageStrate
|
||||
public static final String AMQP_RAW_MESSAGE = AmqpHeaders.PREFIX + "raw_message";
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public ErrorMessage buildErrorMessage(Throwable throwable, AttributeAccessor context) {
|
||||
Object inputMessage = context == null ? null
|
||||
Object inputMessage = context == null
|
||||
? null
|
||||
: context.getAttribute(ErrorMessageUtils.INPUT_MESSAGE_CONTEXT_KEY);
|
||||
Map<String, Object> headers = Collections.singletonMap(
|
||||
AmqpMessageHeaderErrorMessageStrategy.AMQP_RAW_MESSAGE,
|
||||
context.getAttribute(AmqpMessageHeaderErrorMessageStrategy.AMQP_RAW_MESSAGE));
|
||||
Map<String, Object> headers = context == null
|
||||
? new HashMap<String, Object>()
|
||||
: Collections.singletonMap(AmqpMessageHeaderErrorMessageStrategy.AMQP_RAW_MESSAGE,
|
||||
context.getAttribute(AmqpMessageHeaderErrorMessageStrategy.AMQP_RAW_MESSAGE));
|
||||
|
||||
return inputMessage instanceof Message
|
||||
? new org.springframework.integration.message.EnhancedErrorMessage(throwable, headers,
|
||||
(Message<?>) inputMessage)
|
||||
? new org.springframework.integration.message.EnhancedErrorMessage(throwable, headers, (Message<?>) inputMessage)
|
||||
: new ErrorMessage(throwable, headers);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user