CCM-17397: Update mesh-poll Timeout Buffer#315
Open
gareth-allan wants to merge 1 commit intomainfrom
Open
Conversation
Co-authored-by: Copilot <copilot@github.com>
simonlabarere
approved these changes
Apr 27, 2026
tdroza-nhs
approved these changes
Apr 27, 2026
aidenvaines-cgi
approved these changes
Apr 27, 2026
sidnhs
approved these changes
Apr 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR updates the mesh-poll lambda's
MAXIMUM_RUNTIME_MILLISECONDSenvironment variable so it is now calledLAMBDA_TIMEOUT_BUFFER_MILLISECONDSand sets the value to60000(it was originally240000).Context
The original variable name was confusing, as it reads like it represents the maximum total time the lambda will run for, but it is actually used as a value to compare the remaining time the lambda has to run against and if there is less time left to run no more messages are processes (see
processor.py).The current value appears to have been set based on the erroneous expectation that it represents the total time the lambda runs for (it's set to 4 minutes), but we saw from the recent performance test that it is actually resulting in the lambda running for only 1 minute (the timeout of 5 mins - 4 mins) before declaring it doesn't have enough time left to process messages and then sitting idle for another 4 minutes until the schedule invokes it again.
Setting this value to 60000ms (1 minute) means that the lambda will now actually process messages for 4 minutes, then leave a minute for the mesh-download lambda to acknowledge them before starting processing again.
Validation
Type of changes
Checklist
Sensitive Information Declaration
To ensure the utmost confidentiality and protect your and others privacy, we kindly ask you to NOT including PII (Personal Identifiable Information) / PID (Personal Identifiable Data) or any other sensitive data in this PR (Pull Request) and the codebase changes. We will remove any PR that do contain any sensitive information. We really appreciate your cooperation in this matter.