Hello, i’ve been trying to understand the recurring schedules events behavior but i find it inconsistent at times, specially when the recurring event repeats itself a couple of times, i do know that the recommended time for a schedule to be created and then executed is at least 5 minutes and i’ve ran tests using that configuration and got the same results; i ran a test logging the time every minute in a recurring schedule to show the warning i’ve been getting:
“(node:692) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 done listeners added to [HtmlReport]. Use emitter.setMaxListeners() to increase limit”
After i get this warning the recurring schedule usually gets inconsistent, sometimes stopping and sometimes logging information later than expected, the event does log the correct time, so that implies that the event is executed at the correct time but the logs are not. The real question is, is this behavior/warning to be expected? Maybe my handler is doing something unexpected or i’m doing something wrong.
This is the code i’ve been running for the tests. It’s a modified version of the marketplace-sample-apps\Freshworks-Samples\App-Development-Features\Serverless-Features\scheduled_events\scheduled_event_one_time that i found on the Freshworks GitHub.
createSchedule function and handler.