We have been seeing multiple issues witht he SAX Parser and with the TransformStreamWithCompiledXSL methods in the XML.XSLT>Transformer class.
Sample XML:
<ns1:QUQI_IN444211QD xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance" xmlns:ns1="urn:hl7-org:v3" ITSVersion="XML_1.0"><ns1:id e
xtension="541970483"/></ns1:QUQI_IN444211QD>
I run the following commands:
Set IncomingStream = ##Class(%FileCharacterStream).%New()
Do IncomingStream.Write(IncomingRequest)
do IncomingStream.Rewind()
Set writer = ##Class(%XML.Writer).%New()
Set writer.Charset="UTF-8"
Do writer.OutputToStream(.NewStream)
Set Resolver = ##Class(%XML.SAX.EntityResolver).%New()
Do ##class(%XML.TextReader).ParseStream(IncomingStream ,.reader, Resolver, 31)
Is adding: <?xml version="1.0" encoding="UTF-8"?>_$C(13,10) to the Beginning of my XML? Any idea on what flags I can send through to stop this?After removing this line from my stream, I pass this stream to:
Set status = ##class(%XML.XSLT.Transformer).TransformStreamWithCompiledXSL(NewStream, gObjXsl, .StreamObj)).
This Method is choking on the following:
<
ns1:QUQI_IN444211QD> (The preceding ns1 tag).
This is "Valid" XML? Why is cache choking on this? (FYI: If I remove the ns1:, it works fine)Any help would be Greatly appreciated!!!!