Eric Dalquist opened SPR-7621 and commented
AbstractStaxContentHandler tracks the currently in-scope namespaces and sets them on every StartElement and EndElement event. According to the StAX APIs it is only necessary to send the NamespaceContext when it is changing (a new namespaces comes into or goes out of scope). The current functionality results with namespace attributes attached to every element in the document.
The fix is to track when a namespace prefix has been added or removed and only send the NamespaceContext at that time.
Affects: 3.0.4
Attachments:
Referenced from: commits ab21dba, 35da7bd