diff --git a/src/main/java/org/springframework/integration/aws/support/AbstractMessageAttributesHeaderMapper.java b/src/main/java/org/springframework/integration/aws/support/AbstractMessageAttributesHeaderMapper.java index f0bc1a8..e387f4e 100644 --- a/src/main/java/org/springframework/integration/aws/support/AbstractMessageAttributesHeaderMapper.java +++ b/src/main/java/org/springframework/integration/aws/support/AbstractMessageAttributesHeaderMapper.java @@ -1,5 +1,5 @@ /* - * Copyright 2018-2022 the original author or authors. + * Copyright 2018-2023 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -41,13 +41,15 @@ import io.awspring.cloud.messaging.core.MessageAttributeDataTypes; * The {@link #toHeaders(Map)} is not supported. * * @param the target message attribute type. + * * @author Artem Bilan * @author Christopher Smith + * * @since 2.0 */ public abstract class AbstractMessageAttributesHeaderMapper implements HeaderMapper> { - private static final Log logger = LogFactory.getLog(SqsHeaderMapper.class); + protected final Log logger = LogFactory.getLog(getClass()); private volatile String[] outboundHeaderNames = { "!" + MessageHeaders.ID, @@ -104,10 +106,10 @@ public abstract class AbstractMessageAttributesHeaderMapper implements Header getBinaryMessageAttribute(ByteBuffer.wrap((byte[]) messageHeaderValue))); } else { - if (logger.isWarnEnabled()) { - logger.warn(String.format( + if (this.logger.isWarnEnabled()) { + this.logger.warn(String.format( "Message header with name '%s' and type '%s' cannot be sent as" - + " message attribute because it is not supported by SQS.", + + " message attribute because it is not supported by the current AWS service.", messageHeaderName, messageHeaderValue.getClass().getName())); } }