forked from project-chip/connectedhomeip
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a timer to track whether we have received BDX init after a query … (
project-chip#24777) * Add a timer to track whether we have received BDX init after a query image was successful - Currently if an ota requester has a successful query image and an image it available but if for any reason, the ota requester doesn't send BDX init, the provider will be stuck until we reboot the resident. In order to have a fail safe, we are adding a timer that starts after query image returns image available and waits for a BDX init to come. In case BDX init doesn't come, it times out and resets state - Add code to reset state if any API fails on the provider once we prepare for BDX transfer - Stop polling when BDX transfer reset is called - Return QueryImageResponse status busy instead of general failure if the sdk is busy and gets a sexond query image so accessory can handle the error correctly and retry until the sdk is done - When we send a message, handle the case where if an error happens in sending the message close the exchange context and reset state. If the message is a status report and it succeeds, null out the exchange and reset state * Update src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.mm Co-authored-by: Boris Zbarsky <[email protected]> * Update src/darwin/Framework/CHIP/MTROTAProviderDelegateBridge.mm Co-authored-by: Boris Zbarsky <[email protected]> * Reset mStopPolling to false when we call PrepareForTransfer to start polling again - This covers the use case where we have an image available but the requestor rejects the transfer for some reason. On the next query image the requestor is able to continue with the BDX transfer. The provider state was not being reset for this scenario due to the polling flag not being reset. - Fixes project-chip#23573 * Addressed review comments * Fix the handling of the use case when hasUpdate is false we need to send the response as is - Log the error if the BDX timer fails to start --------- Co-authored-by: Boris Zbarsky <[email protected]>
- Loading branch information
1 parent
38f510c
commit 2e24269
Showing
2 changed files
with
157 additions
and
78 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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