Details
-
Bug
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
0.16
-
None
-
None
Description
If you post with curl a json payload to oak (oak-run and httpbinding) the jcr:primaryType of root changes from rep:root to nt:unstructured.
Step for reproducing
- Fire oak with oak-run org.apache.jackrabbit.oak.run.Main and parameters: server /path/to/oak-repo
- check the rep:root is fine
curl -u admin:admin -H "Accept: application/json" http://localhost:8080 {"jcr:primaryType":"rep:root","jcr:system":{},"rep:security":{},"oak:index":{}}
- post a json payload for creating /content
curl -u admin:admin -H "Accept: application/json" -H "Content-Type: application/json" -X POST -d "{\"jcr:primaryType\":\"oak:unstructured\"}" http://localhost:8080/content
- check and see the "/" changing to nt:unstructured
curl -u admin:admin -H "Accept: application/json" http://localhost:8080 {"jcr:primaryType":"nt:unstructured","content":{},"jcr:system":{},"rep:security":{},"oak:index":{}}