Description
CachingXmlEventWriter.NSContext supports only one prefix for a namespace. As a result we have DOUBLE declaration of the SAMEprefix in an element (output xml). We use xmlbeans binding so that org.apache.cxf.xmlbeans.DataWriterImpl uses StaxUtils.copy. This StaxUtils.copy.writeStartElement writes namespaces from elements and attributes. If we have many different prefixes for the same namespace and the prefixes are used also in attributes then StaxUtils.copy.writeStartElement outputs DOUBLE declaration:
input
<a:elem1 a:xmlns="test" b:xmlns="test" a:attr1="value">
output
<a:elem1 a:xmlns="test" b:xmlns="test" a:attr1="value" a:xmlns="test">
invalid: double a:xmlns="test" declaration