Use Case: Customer has a scheduled script with an infinite loop in 'Processing' status or a wrong logic that causes the script to run endlessly.
Answer: User cannot stop a currently processing script. If the scheduled script does not include an nlapiYieldScript API call, the scheduled script with the infinite loop execution time can be up to one (1) hour before it's terminated by other monitoring system processes. The status of the script is set to 'Failed' and this is logged in the Execution Log subtab on the script deployment record.
The script will be terminated and an SSS_INSTRUCTION_COUNT_EXCEEDED error message is thrown.
- Should the user receive this error, NetSuite recommends that user examines the for loops in the script to ensure that they contain either a terminating condition or a condition that can be met.
There are possible instances where the infinite loop may also lead to exceeding SuiteScript Governance Limit when API calls are made within the loop. A SSS_USAGE_LIMIT_EXCEEDED error will be thrown in this scenario.
- In cases where governance on script logging is exceeded, NetSuite will change the offending script's log level to the next level higher. The offending script will continue its execution, however, its log level will go from Debug to Audit, or Audit to Error, or Error to Emergency, depending on the script.
For more information, kindly visit the following related SuiteAnswers articles:
- 10492 SuiteScript Governance
- 24233 Governance on Script Logging
- 35876 Canceling a 'Processing' Scheduled Script from rescheduling itself using nlapiYieldScript 10279 Scheduling APIs
Post a Comment