-
Type: Bug
-
Status: Resolved
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Component/s: Rest API
-
Tags:
-
Team:PLATFORM
-
Sprint:nxplatform #95, nxplatform #96
-
Story Points:3
When using CloudFront and activating the download URL follow redirect property with:
<require>org.nuxeo.ecm.core.io.download.DownloadService</require> <extension target="org.nuxeo.runtime.ConfigurationService" point="configuration"> <property name="org.nuxeo.download.url.follow.redirect">true</property> </extension>
Adding a new blob to a blobs list through the REST API is removing the existing blobs from the list as Nuxeo cannot retrieve a Blob from a CloudFront URL.
Trying to update the files:files property using a PUT request with:
... "files:files": { "file": { "upload-batch": "BATCH_ID", "upload-fileId": "0" }, "file": { ... data: "https://d1vng3nadiklf1.cloudfront.net/binaries/eb621c0b4..." } } ...
will end up with the following result:
... "files:files": { "file": { ... data: "https://d1vng3nadiklf1.cloudfront.net/binaries/NEW_BINARY..." }, null } ...
Nuxeo server cannot retrieve a Blob from the CloudFront URL and so returns null, which will override the existing blob in the blobs list. This is working as expected by ignoring the Blob update for single-valued Blob property (such as file:content).
A solution would be to always add a new field in the Blob JSON, like blobUrl, that will be used to store the Blob URL on the Nuxeo Server. This field can then be read by the server to correctly retrieve the underlying blob, even if using CloudFront in the data field value.
- causes
-
WEBUI-1203 Multiple metadata attachment not working in cloud server with custom config
- Resolved