Uploaded image for project: 'Nuxeo Java Client'
  1. Nuxeo Java Client
  2. JAVACLIENT-105

Fix wrong filename when attaching blob

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0, 2.1
    • Fix Version/s: 1.2, 2.2
    • Component/s: API

      Description

      1. create a document in nuxeo
      2. try the following code to attach a picture (see attachments):
        Blob fileBlob = new Blob(new File("/Users/ffischer/Downloads/breakout2600_2.png"));
                	Blob blob = nuxeoClient.automation().newRequest("Blob.AttachOnDocument")
                			.param("document", "/default-domain/workspaces/testWorkspaceSUPNXP18115/myTestFile1")
                			.input(fileBlob).execute();
        
      3. This uploads the file and attach it to the document using a temporary name (.tmp).
      4. Using the following CURL command it works fine:
        curl -X POST -F request='{"params":{"document":"/default-domain/workspaces/testWorkspaceSUPNXP18115/myTestFile1"},"context":{}}' -F input=@breakout2600_2.png -u Administrator:Administrator http://localhost:8080/nuxeo/site/automation/Blob.Attach
        

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 day
                  1d