From 5938ca9a7c77a20d7670e806e4d09c910a97d70d Mon Sep 17 00:00:00 2001 From: Arjen Poutsma Date: Mon, 14 Jan 2019 11:48:41 +0100 Subject: [PATCH] Deprecate JiBX marshaller Resolves #22249 --- .../oxm/config/JibxMarshallerBeanDefinitionParser.java | 4 +++- .../java/org/springframework/oxm/jibx/JibxMarshaller.java | 4 +++- .../resources/org/springframework/oxm/config/spring-oxm.xsd | 2 +- .../org/springframework/oxm/jibx/JibxMarshallerTests.java | 5 +++-- .../org/springframework/oxm/jibx/JibxUnmarshallerTests.java | 3 ++- 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/spring-oxm/src/main/java/org/springframework/oxm/config/JibxMarshallerBeanDefinitionParser.java b/spring-oxm/src/main/java/org/springframework/oxm/config/JibxMarshallerBeanDefinitionParser.java index 1ba7e975b3..753ae4add5 100644 --- a/spring-oxm/src/main/java/org/springframework/oxm/config/JibxMarshallerBeanDefinitionParser.java +++ b/spring-oxm/src/main/java/org/springframework/oxm/config/JibxMarshallerBeanDefinitionParser.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2013 the original author or authors. + * Copyright 2002-2019 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. @@ -25,7 +25,9 @@ import org.springframework.beans.factory.xml.AbstractSimpleBeanDefinitionParser; * * @author Arjen Poutsma * @since 3.0 + * @deprecated as of Spring Framework 5.1.5, due to the lack of activity on the JiBX project */ +@Deprecated class JibxMarshallerBeanDefinitionParser extends AbstractSimpleBeanDefinitionParser { @Override diff --git a/spring-oxm/src/main/java/org/springframework/oxm/jibx/JibxMarshaller.java b/spring-oxm/src/main/java/org/springframework/oxm/jibx/JibxMarshaller.java index f74860908c..9775f8878d 100644 --- a/spring-oxm/src/main/java/org/springframework/oxm/jibx/JibxMarshaller.java +++ b/spring-oxm/src/main/java/org/springframework/oxm/jibx/JibxMarshaller.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2018 the original author or authors. + * Copyright 2002-2019 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. @@ -81,7 +81,9 @@ import org.springframework.util.xml.StaxUtils; * @since 3.0 * @see org.jibx.runtime.IMarshallingContext * @see org.jibx.runtime.IUnmarshallingContext + * @deprecated as of Spring Framework 5.1.5, due to the lack of activity on the JiBX project */ +@Deprecated public class JibxMarshaller extends AbstractMarshaller implements InitializingBean { private static final String DEFAULT_BINDING_NAME = "binding"; diff --git a/spring-oxm/src/main/resources/org/springframework/oxm/config/spring-oxm.xsd b/spring-oxm/src/main/resources/org/springframework/oxm/config/spring-oxm.xsd index 046cd88148..a1c82ef566 100644 --- a/spring-oxm/src/main/resources/org/springframework/oxm/config/spring-oxm.xsd +++ b/spring-oxm/src/main/resources/org/springframework/oxm/config/spring-oxm.xsd @@ -50,7 +50,7 @@ - Defines a JiBX Marshaller. + Defines a JiBX Marshaller. Deprecated as of Spring Framework 5.1.5! diff --git a/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxMarshallerTests.java b/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxMarshallerTests.java index 32ba19acd9..12951092df 100644 --- a/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxMarshallerTests.java +++ b/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxMarshallerTests.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2016 the original author or authors. + * Copyright 2002-2019 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. @@ -26,7 +26,7 @@ import org.junit.Test; import org.springframework.oxm.AbstractMarshallerTests; import static org.junit.Assert.*; -import static org.xmlunit.matchers.CompareMatcher.*; +import static org.xmlunit.matchers.CompareMatcher.isSimilarTo; /** * NOTE: These tests fail under Eclipse/IDEA because JiBX binding does not occur by @@ -35,6 +35,7 @@ import static org.xmlunit.matchers.CompareMatcher.*; * @author Arjen Poutsma * @author Sam Brannen */ +@Deprecated public class JibxMarshallerTests extends AbstractMarshallerTests { @BeforeClass diff --git a/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxUnmarshallerTests.java b/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxUnmarshallerTests.java index 39f5a66f00..dec1f4f777 100644 --- a/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxUnmarshallerTests.java +++ b/spring-oxm/src/test/java/org/springframework/oxm/jibx/JibxUnmarshallerTests.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2016 the original author or authors. + * Copyright 2002-2019 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. @@ -34,6 +34,7 @@ import static org.junit.Assert.*; * @author Arjen Poutsma * @author Sam Brannen */ +@Deprecated public class JibxUnmarshallerTests extends AbstractUnmarshallerTests { protected static final String INPUT_STRING_WITH_SPECIAL_CHARACTERS =