This topic contains 1 reply, has 0 voices, and was last updated by starlingMark 5 years, 10 months ago.

  • Author
    Posts
  • #17900 Score: 0

    jmacdonald
    • Contributions: 0
    • Level 1

    Hello,

    I have been asked to find the best way to get a file from the NetSuite file cabinet and send this to an external system using a HTTPS POST request. The issue is that these files can be up to 25MB so I’m hesitant to do this with a single request as NetSuite limit the outbound connection time to 45 seconds and I believe that these requests would take longer than the limit to get the response.

    I was thinking about splitting the file in to smaller sized chunks and sending these over using multiple requests, does anyone have any experience solving this problem and have any advice? I’m just looking to see if their are any gotchas in my preferred method of splitting the file or if I’m missing any better solutions?

    Some things I have thought about to ensure that splitting the file and sending multiple requests will be successful:Specify the total number of requests in the initial request with the first part of the file, specify an ID in each request so we can verify all parts are part of the same file.
    Send an Index with each request so we can verify each part has been received.
    Potentially hashing the data contents of each request to verify data integrity.
    Any advice or information would be appreciated.

    Thanks
    This is a cached copy. Click here to see the original post.

  • #17901 Score: 0

    starlingMark
    • Contributions: 0
    • Level 1

    Hi jmacdonald,

    I’ve come across this request before. A couple of other thoughts for you:

    1.) Web services would probably handle such a request more robustly.

    2.) Is there any way to grab the external URL of the file and instead ask the other side to perform a GET?

    3.) Middleware – something like a small node app that can download the file with a GET and then POST it to the destination.

    If you come up with another solution I’d love to hear about it as well!

You must be logged in to reply to this topic.