Node.js crashes when using long interval in setinterval

前端 未结 2 2025
闹比i
闹比i 2020-12-15 16:29
function createSasTokenTimer() {    
    console.log(\"Hello\");
}

setInterval(createSasTokenTimer, 3000000);

I run this code and after 50 minutes

2条回答
  •  暖寄归人
    2020-12-15 17:04

    To me this looks like a non standard modual that you are using instead of the native modual. Look at global.process.moduleLoadList it should have the entries

     'NativeModule timers',
     'Binding timer_wrap',
    

    And check your code that you are not importing 3rd party timers.js

提交回复
热议问题