Fixed Jaxb2CollectionHttpMessageConverterTests
- Added Woodstox before Aalto in the spring-web build, so that Woodstox is used as StAX implementation, and not the less featured Aalto. - Hardcoded Aalto dependency in XmlEventDecoder, instead of relying on the StAX XMLInputFactory.
This commit is contained in:
committed by
Rossen Stoyanchev
parent
5d1b542698
commit
4390cd0c2b
@@ -77,6 +77,7 @@ configure(allprojects) { project ->
|
||||
ext.tomcatVersion = "8.5.3"
|
||||
ext.tyrusVersion = "1.13"
|
||||
ext.undertowVersion = "1.4.0.CR3"
|
||||
ext.woodstoxVersion = "5.0.2"
|
||||
ext.xmlunitVersion = "1.6"
|
||||
ext.xstreamVersion = "1.4.9"
|
||||
|
||||
@@ -369,7 +370,7 @@ project("spring-core") {
|
||||
optional("io.netty:netty-buffer:${nettyVersion}")
|
||||
testCompile("org.apache.tomcat.embed:tomcat-embed-core:${tomcatVersion}")
|
||||
testCompile("xmlunit:xmlunit:${xmlunitVersion}")
|
||||
testCompile("com.fasterxml.woodstox:woodstox-core:5.0.2") {
|
||||
testCompile("com.fasterxml.woodstox:woodstox-core:${woodstoxVersion}") {
|
||||
exclude group: "stax", module: "stax-api"
|
||||
}
|
||||
}
|
||||
@@ -691,6 +692,9 @@ project("spring-web") {
|
||||
optional("io.reactivex:rxjava:${rxJavaVersion}")
|
||||
optional("io.undertow:undertow-core:1.3.20.Final")
|
||||
optional("io.netty:netty-buffer:${nettyVersion}") // Temporarily for JsonObjectDecoder
|
||||
optional("com.fasterxml.woodstox:woodstox-core:${woodstoxVersion}") { // woodstox before aalto
|
||||
exclude group: "stax", module: "stax-api"
|
||||
}
|
||||
optional("com.fasterxml:aalto-xml:1.0.0")
|
||||
optional("org.apache.httpcomponents:httpclient:${httpclientVersion}")
|
||||
optional("org.apache.httpcomponents:httpasyncclient:${httpasyncVersion}")
|
||||
@@ -725,6 +729,7 @@ project("spring-web") {
|
||||
testCompile("org.eclipse.jetty:jetty-server:${jettyVersion}")
|
||||
testCompile("org.eclipse.jetty:jetty-servlet:${jettyVersion}")
|
||||
testCompile("com.squareup.okhttp3:mockwebserver:3.0.1")
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -30,6 +30,7 @@ import com.fasterxml.aalto.AsyncByteBufferFeeder;
|
||||
import com.fasterxml.aalto.AsyncXMLInputFactory;
|
||||
import com.fasterxml.aalto.AsyncXMLStreamReader;
|
||||
import com.fasterxml.aalto.evt.EventAllocatorImpl;
|
||||
import com.fasterxml.aalto.stax.InputFactoryImpl;
|
||||
import org.reactivestreams.Publisher;
|
||||
import reactor.core.publisher.Flux;
|
||||
import reactor.core.publisher.Mono;
|
||||
@@ -116,8 +117,7 @@ public class XmlEventDecoder extends AbstractDecoder<XMLEvent> {
|
||||
private static class AaltoDataBufferToXmlEvent
|
||||
implements Function<DataBuffer, Publisher<? extends XMLEvent>> {
|
||||
|
||||
private static final AsyncXMLInputFactory inputFactory =
|
||||
(AsyncXMLInputFactory) XmlEventDecoder.inputFactory;
|
||||
private static final AsyncXMLInputFactory inputFactory = new InputFactoryImpl();
|
||||
|
||||
private final AsyncXMLStreamReader<AsyncByteBufferFeeder> streamReader =
|
||||
inputFactory.createAsyncForByteBuffer();
|
||||
|
||||
Reference in New Issue
Block a user