-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[udp-proxy] track Mesh-Local prefix in UdpProxyClient (#188)
Previous implementation requires the caller of the Commissioner library to set Mesh-Local prefix before initiating MGMT commands. it is error-prone and breaks backward compatibility: we need to first fetch the Active Operational Dataset and set the Mesh-Local Prefix to the commissioner library before sending other MGMT_* commands. This commit refactors the UDP Proxy to have it manage the Mesh-Local prefix inside the ProxyClient class. 1. The Mesh-Local prefix is lazily requested from the Border Agent before sending the first MGMT command (if no Mesh-Local prefix is cached). 2. The cached Mesh-Local prefix is cleared when the commissioner receives MGMT_DATASET_CHANGED.ntf so that the latest Mesh-Local prefix will be fetched before next MGMT command. 3. The cached Mesh-Local prefix is cleared when the commissioner is disconnected. In this way, the user doesn't need to be aware of the Mesh-Local prefix and no changes are required.
- Loading branch information
Showing
9 changed files
with
153 additions
and
126 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
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
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
Oops, something went wrong.