-
Type: Bug
-
Status: Open
-
Priority: Minor
-
Resolution: Unresolved
-
Affects Version/s: 10.10
-
Fix Version/s: QualifiedToSchedule
-
Component/s: Rest API
What
binary stored with null filename causes issues at least with Drive in JSF (computing of Direct Edit URL) and Drive client (the client desktop cannot save a null filename file)
How to create the condition
Take a binary document named Support.docx
Use the following scripted entries:
curl -u Administrator:Administrator -X POST http://localhost:8080/nuxeo/api/v1/upload > upload.txt echo batchId=`grep "batchId" upload.txt|sed -e 's/{"batchId":"//g' -e 's/"}//' ` echo ${batchId} # NOTICE below the X-File-Name header is providing no value curl -u Administrator:Administrator -X POST -H "X-File-Name:" -H "X-File-Type:application/msword" -T Support.docx http://localhost:8080/nuxeo/api/v1/upload/${batchId}/0 echo curl -u Administrator:Administrator -G http://localhost:8080/nuxeo/api/v1/upload/${batchId} echo data=`echo -n '{"entity-type": "document", "name": "newDoc", "type": "File", "properties": {"dc:title": "My New Doc", "file:content": {"upload-batch": "'; echo -n ${batchId} ; echo -n '", "upload-fileId": "0"}}}'` echo ${data} curl -X POST -H 'Content-Type: application/json' -u Administrator:Administrator -d "${data}" http://localhost:8080/nuxeo/api/v1/path/default-domain/workspaces/Start%20Creating%20Your%20Cont/PA echo
This will create a Document entitled My New Doc
Add Drive and JSF and WebUI to the configuration
Current results
- This chokes while displaying the document as in JSF not able to compute the document Direct Edit URL
- In WebUI, display the document and attempt to Direct Edit it with Drive => Drive client cannot open a file with no name.
Expected Result
Refusing to store a null filename for a binary would enable seamless work with Drive and other client technologies