synapse-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pierce Wetter (Created) (JIRA)" <>
Subject [jira] [Created] (SYNAPSE-823) Support multi root json (simple fix suggested)
Date Thu, 08 Dec 2011 18:37:41 GMT
Support multi root json (simple fix suggested)

                 Key: SYNAPSE-823
             Project: Synapse
          Issue Type: Improvement
          Components: Core
            Reporter: Pierce Wetter 

For rest <-> rest mediation Json is much more common lately than XML.  Unless you use
binary relay, synapse mangles json with multiple roots by grabbing only the first key because
XML requires a single root. While the workaround is to modify the json to have a single root
if its not your API its not your choice  

It would be better to detect this case and supply an artificial root during the builder and
remove it during the formatter. 

I.e. if you get json that has: roota, rootb, rootc turn this into Synapse_json_root( roota,
rootb, rootc ) before translating it into XML. When converting that back to json detect the
presence of synapse_json_root and restore the json to roota, rootb, rootc. 

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message