GH-2197: Rely on the Document creation for Source
Resolves https://github.com/spring-projects/spring-integration/issues/2197 Sometime we would like to avoid some XML definition features (e.g. loading of the DTD). The `XmlValidatingMessageSelector` doesn't allow to do that easily because it doesn't rely on the `Document` creation via `DocumentBuilderFactory`, but directly manipulates with `Source` * Change `DefaultXmlPayloadConverter.convertToSource()` to fallback to the `convertToDocument()` for non-Document payloads. This way we can configure `DefaultXmlPayloadConverter` with custom `DocumentBuilderFactory` and bypass DTD loading, for example * Expose `xml-converter` option for the `<int-xml:validating-filter>` component
This commit is contained in:
committed by
Gary Russell
parent
6c62af53f4
commit
d79e70c6df
@@ -812,6 +812,18 @@
|
||||
</xsd:appinfo>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="xml-converter" type="xsd:string">
|
||||
<xsd:annotation>
|
||||
<xsd:documentation>
|
||||
Reference to a custom 'org.springframework.integration.xml.XmlPayloadConverter' strategy
|
||||
</xsd:documentation>
|
||||
<xsd:appinfo>
|
||||
<tool:annotation kind="ref">
|
||||
<tool:expected-type type="org.springframework.integration.xml.XmlPayloadConverter" />
|
||||
</tool:annotation>
|
||||
</xsd:appinfo>
|
||||
</xsd:annotation>
|
||||
</xsd:attribute>
|
||||
<xsd:attribute name="schema-location"/>
|
||||
<xsd:attribute name="schema-type" default="xml-schema">
|
||||
<xsd:simpleType>
|
||||
|
||||
Reference in New Issue
Block a user