Extended namespaces not well handled by XMLWriter

I’'ve been trying to send in my plugin an IQ through OpenFire. This IQ is a DOM tree with an extended namespace. Exemple:

This is due to how XMLWriter processes the DOM tree. My question is why do you use your own way to serialize the DOM tree instead of using the .asXML() dom4j method ? Is this a matter of performance ?

I’‘ve been a bit deeper in the investigations and finally found (thanks telnet, plain old good technology) that it’'s not OpenFire that sends incorrect IQs but my client (Psi) which interpret them badly. I guess the problem is the same with smack. So, no problem on OpenFire side.

Anyway, that does not explain why you use your own XMLWriter to serialize the Packet object while DOM can do it freely (still guessing that it’'s because of performance matter).