I'm getting a timeout on saving a record transform...
# suitescript
r
I'm getting a timeout on saving a record transformation (item receipt on a transfer order), SSS_REQUEST_TIME_EXCEEDED, which I understand is 45 seconds. My only thought to get around this, is to use a SuiteLet and call this to perform the transform instead of doing it within a Scheduled Script. Is there another way of defeating the 45 seconds?
b
if you arent actually make the https request, then a user event is
in which case its fairly likely that the suitelet would also encounter the same problem since it also triggers user events
r
hmm, so if I bypass the user events that should resolve the issue. I think i can do that by using a role that skips the events.
the timeout is happening on the record.transform().save()
b
that error code is associated with nlapiRequestURL, or the N/https module
if you arent making the https request, something else is
make the effort to find out which script is throwing the error to determine how necessary the script is
r
ok I think I'm following now. The record.save() is invoking a User Event Script on the transaction record being saved is the problem. If I could have the scheduled script 'run as' I could bypass the user event scripts I have. The only other option I can think of is to figure out the calling context of the user event when "record.save" is called and ignore running.
The other odd bit, it works on an item fulfillment, just not the item receipt
Another interesting note, the transform of the transfer order to item fulfillment worked, but the item receipt is giving the timeout.
Why is there a difference in the "save" time of an IR over an IF? Note, both are using the exact same code (with defaultvalues and record creation type different in the transform)
b
one has a slow user event deployed to it, the other doesnt
r
Bingo, killed those made progress, lost progress on item fulfillment now with a reversing transfer order on the issueinventorynumber step.