On 2009/09/24, at 16:41, Jack Moffitt wrote:
If you have a namespace prefix in one stream header, it must be in another where it is used. So if you allow arbitrary XML like you have proposed there, then every server will have to translate from one representation to another. This means a complete parse and reserialization cycle at each point.
+1.
If we all agree on a default namespace, this is not required, and is a huge gain in efficiency. Now XMPP servers don't even have to parse stanzas. They can simply regex out the to/from attributes and pass the stanza on as a bag of bytes.
-1 :)You still need to at least lex it to make sure that it is well-formed XML.
But yes, after that you should be able to pass along the entire string buffer.
The <stream:stream> prefixes aren't really that big of a deal because they are only between two endpoints and don't leak out to other places, which is why I think it's ok to relax those.
Also, by placing the stanzas that do cross XML streams (presence, message, and iq) in the default namespace, you can transport the string buffer without further processing.
That another reason not to declare extra namespaces in the <stream> opening node that would be used inside stanzas.
Best
Note Well: Messages sent to this mailing list are the opinions of the senders and do not imply endorsement by the IETF.