Remove dependency on javax.xml.bind

This is primarily to make it complient with JDK 11/13, plus we were only using it in one place for logging
This commit is contained in:
Oleg Zhurakousky
2020-04-23 07:37:12 +02:00
parent e76960dbb6
commit e856ca694d
2 changed files with 1 additions and 5 deletions

View File

@@ -21,8 +21,6 @@ import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
import javax.xml.bind.DatatypeConverter;
import org.springframework.integration.support.json.Jackson2JsonObjectMapper;
import org.springframework.messaging.Message;
import org.springframework.messaging.MessageHeaders;
@@ -49,8 +47,7 @@ public abstract class EmbeddedHeaderUtils {
private static final Jackson2JsonObjectMapper objectMapper = new Jackson2JsonObjectMapper();
public static String decodeExceptionMessage(Message<?> requestMessage) {
return "Could not convert message: "
+ DatatypeConverter.printHexBinary((byte[]) requestMessage.getPayload());
return "Could not convert message: " + requestMessage;
}
/**

View File

@@ -133,7 +133,6 @@ public class MessageConverterTests {
catch (Exception e) {
String s = EmbeddedHeaderUtils.decodeExceptionMessage(message);
assertThat(e).isInstanceOf(BufferUnderflowException.class);
assertThat(s).startsWith("Could not convert message: FF63");
}
}