Aspera

Aspera

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Managing Node API Cache

    Posted 12/13/21 07:43 PM

    Hi all, I am creating an integration with Aspera on Cloud and am trying to fetch metadata for files within a directory immediately after a new file has been uploaded.

    Within postman I'm sending a GET request to {{baseUrl}}/files/:id/files and it is successfully returning metadata for the provided folder.

    The problem I'm seeing is that the results of the request are being cached for some period of time, even if new files have been added to the directory. I would expect to receive up to date results once a new file has been uploaded.

    How can I invalidate the cache when a new file is uploaded? I do see that the Node api is providing the cache info in the "X-Aspera-Node-Cache" response header. I'm not sure what to do with that though.

    Any help would be greatly appreciated.

    Thanks,

    Tim



    #AsperaonCloud
    #Support
    #SupportMigration


  • 2.  RE: Managing Node API Cache
    Best Answer

    Posted 12/14/21 01:33 AM

    Add the following in the GET request header:

    X-Aspera-Cache-Control: no-cache



    #AsperaonCloud
    #Support
    #SupportMigration


  • 3.  RE: Managing Node API Cache
    Best Answer

    Posted 12/14/21 03:20 PM

    Thank you Laurent, this worked for me!



    #AsperaonCloud
    #Support
    #SupportMigration