Special Characters in JSON cause failure in custom MetadataSchema Form



Can someone confirm if this is a defect or a work-around for the following special characters issue?

Created a new MetadataSchema and added a Dropdown object when building the form.

The issue is that if you source the values for the drop-down from a JSON object (set the JSON Path in the field settings) then if the JSON contains certain special characters it causes the form to fail.

If the JSON source contains a slash (/) or a colon (:) in the text property then the slash causes it to create corrupt nodes under the form.  The colon causes it AEM to throw a namespace exception.  (Sample JSON below).

Why is the text property being "evaluated" in this way?  It prevents you from using these characters in the dropdown options which is a reasonable requirement.

NOTE:  Additionally, to use a JSON source like this requires you to set the JSON Path, save the form, reopen the form, then resave before the JSON options are reflected in the Metadata Form. 


// Rights Management { "options": [ { "value": "royalty_free", "text": "Royalty / Free" }, { "value": "rights_managed", "text": "Rights:Managed" }, { "value": "restricted", "text": "Restricted" } ] }






Can you tell me what path you put in for the JSON Path field and how you placed the JSON file in AEM? I saw the JSON Path field today and I'm not sure how to use it.