I have an Azure Cloud Script to reset my game's Leaderboard at 2am UTC. The script has been running for 4 months. It normally executes successfully, but every 10-20 days it will fail. When that happens, the leaderboard is not updated and my users play the previous day's game, which is a bad experience.
This happened yesterday:
{
"TaskInstanceId": "DD11FE5A615B4ADF-122",
"TaskIdentifier": {
"Name": "Reset Daily Highest Score 2",
"Id": "DD11FE5A615B4ADF"
},
"StartedAt": "2023-10-28T02:01:13.2659967Z",
"CompletedAt": "2023-10-28T02:21:15.8530709Z",
"Status": "Aborted"
}
And this on October 11:
{
"TaskInstanceId": "DD11FE5A615B4ADF-104",
"TaskIdentifier": {
"Name": "Reset Daily Highest Score 2",
"Id": "DD11FE5A615B4ADF"
},
"StartedAt": "2023-10-11T02:01:10.4123393Z",
"CompletedAt": "2023-10-11T02:01:45.2545085Z",
"Status": "Failed",
"Error": "The function Reset Daily Highest Score Leaderboard 2 was terminated after the maximum execution time limit: 4500ms"
}
What should I do? Should I check for failure of the script's execution and retry until success?
I should mentions that I have been using the Free Tier of PlayFab so far, but have now upgraded to pays-as-you-go. Will that help? (I'm thinking I may have had lower priority in acquiring resources to run the script).
Please help as I'm launching my Title and cannot risk these failures. Happy to provide logs and/or code samples as needed.
Thanks, Fausto