<@U9D2H3SBV> In this case that is not a reliable a...
# suitescript
a
@ehcanadian In this case that is not a reliable approach, I'm building a Package Builder Suitelet where the User enter a distribution group which could have 1000 Sales Orders with a 1000 Item Fulfillments, I need to generate package details and info for each IF and after that I need to get 1000 Shipping Labels from the EDI/ASN provider...
e
Hrm yeah, maybe not the best approach - just thinking about how to alleviate the user having to submit more than one job
h
@alien4u How about this? Can you put all that in one json file (you can create a map with group of records to process) and store it in file cabinet then start a task map reduce and pass that file id to that M/R and M/R will call a restlet to process it in chunks
a
@Hubert The limitation I have is not about not being able to handle it with a Map Reduce, is about the unavailability of a reliable Sleep/Wait function server side... because IIS is not allowing more than 255 request in a period of time...
h
so I was thinking that you can divide that into chunks and call restlet from M/R to process each chunk with 255 request
a
@Hubert Dividing by chunks would not make it any slower the amount of request per given period of time is gonna be more than 255 because is fast... very fast, actually in the other side they are thinking I'm sending Asynchronously and is not the case because you can't do that from server side, but NetSuite server is so fast sending request to their server that they think is being Asynchronously.
e
I don't think sleep/wait would be reliable because what happens if their side craps out/crashes/doesn't respond?
ya, that's a tough one to solve
h
@alien4u do you get "too many requests" from that server ?
a
No I don't because I'm not fully debugging it, I just double check with the guys who handle that server...
e
Can you do your requests via a restlet in chunks? The restlet would handle the response and you'd know what batch to send next.
Sorry if i'm missing somethign
h
because if you get that response you can just restart that task for that chunk again