Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-30241

Fix upload of a Google Drive shared file

    XMLWordPrintable

    Details

    • Release Notes Summary:
      Files shared among Google Drive accounts are correctly uploaded with LiveConnect
    • Tags:
    • Backlog priority:
      850

      Description

      Pre-requisite: install nuxeo-liveconnect addon and configure it as describe at https://doc.nuxeo.com/nxdoc/1010/nuxeo-live-connect/#configuration

      And ask someone (from another Google organization) to share a file with your Google account.

       

      Steps to reproduce:

      1. go to your personal workspace
      2. click on the + button in WebUI
      3. fill the title
      4. click on the Google Drive link
      5. the GDrive popup opens
      6. search for the file 9100182304006_WDF2018022214534900.4035275.tif and select the first result
      7. the popup closes and a message indicates that the File is upload
      8. Note that the file name and size are correct
      9. Click on the Create button to finish

      Observe that :

      • the attached file is now error.bin with size = 0 bytes
      • the preview failed with this message
      {"entity-type":"exception","status":500,"message":"com.google.api.client.googleapis.json.GoogleJsonResponseException: 404 Not Found\n{\n  \"code\" : 404,\n  \"errors\" : [ {\n    \"domain\" : \"global\",\n    \"location\" : \"file\",\n    \"locationType\" : \"other\",\n    \"message\" : \"File not found: 13Jmk09OWyUIgLvllWTrVVt1MhoDCzr4N\",\n    \"reason\" : \"notFound\"\n  } ],\n  \"message\" : \"File not found: 13Jmk09OWyUIgLvllWTrVVt1MhoDCzr4N\"\n}"} 

      The logs are full of this error

      2021-03-08T19:28:53,493 ERROR [http-nio-0.0.0.0-8080-exec-2] [org.nuxeo.ecm.liveconnect.core.AbstractLiveConnectBlobProvider] Failed to access file: LiveConnectFileInfo{user=tmartins@nuxeo.com, fileId=13Jmk09OWyUIgLvllWTrVVt1MhoDCzr4N}
      com.google.api.client.googleapis.json.GoogleJsonResponseException: 404 Not Found
      {
        "code" : 404,
        "errors" : [ {
          "domain" : "global",
          "location" : "file",
          "locationType" : "other",
          "message" : "File not found: 13Jmk09OWyUIgLvllWTrVVt1MhoDCzr4N",
          "reason" : "notFound"
        } ],
        "message" : "File not found: 13Jmk09OWyUIgLvllWTrVVt1MhoDCzr4N"
      }
              at com.google.api.client.googleapis.json.GoogleJsonResponseException.from(GoogleJsonResponseException.java:150) ~[google-api-client-1.25.0.jar:1.25.0]
              at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:113) ~[google-api-client-1.25.0.jar:1.25.0]
              at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:40) ~[google-api-client-1.25.0.jar:1.25.0]
              at com.google.api.client.googleapis.services.AbstractGoogleClientRequest$1.interceptResponse(AbstractGoogleClientRequest.java:321) ~[google-api-client-1.25.0.jar:1.25.0]
              at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1049) ~[google-http-client-1.19.0.jar:1.19.0]
              at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:419) ~[google-api-client-1.25.0.jar:1.25.0]
              at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:352) ~[google-api-client-1.25.0.jar:1.25.0]
              at org.nuxeo.ecm.liveconnect.google.drive.GoogleDriveBlobProvider.executeAndCache(GoogleDriveBlobProvider.java:577) ~[nuxeo-liveconnect-google-drive-core-10.10.jar:?]
              at org.nuxeo.ecm.liveconnect.google.drive.GoogleDriveBlobProvider.getDriveFile(GoogleDriveBlobProvider.java:541) ~[nuxeo-liveconnect-google-drive-core-10.10.jar:?]
              at org.nuxeo.ecm.liveconnect.google.drive.GoogleDriveBlobProvider.retrieveFile(GoogleDriveBlobProvider.java:520) ~[nuxeo-liveconnect-google-drive-core-10.10.jar:?]
       

        Attachments

          Activity

            People

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

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - Not Specified
                Not Specified
                Logged:
                Time Spent - 4 hours
                4h