Details
-
Improvement
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
The JSON Renderer in the Sling GET Servlet does not export binary properties and prints the length instead of the data:
{ "jcr:primaryType": "nt:resource", ":jcr:data": 20127 }
Note that the names of binary properties are prefixed with a colon.
I would like to introduce an OSGi flag to enable exporting binaries in base64. If enabled, the output would look something like
{ "jcr:primaryType": "nt:resource", ":jcr:data": "iVBORw0KGgoA...." }
The default is false which means existing consumers will keep getting the length.
There is a related ticket https://issues.apache.org/jira/browse/SLING-11891 to make sense of the base64 data when importing from JSON.
This change will improve symmetry between export and import in Sling GET/POST servlets and make round-trips more reliable.
The PR is coming
Attachments
Issue Links
- links to