forked from Azure/iot-hub-device-update
-
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.
Merge 'main' into 'develop' and update version number to 1.1.0 (Azure…
…#594) * Merge 'develop' into 'main' (Azure#243) Fix issue in reboot/restart flow and race condition in D2C messaging util (Azure#242) - Fix an issue for image-based update scenario where the device doesn't reboot after the new image is installed. - Add ADUC_D2C_Message_Type_Device_Properties to avoid a race condition. Note | These changes passed e2e verification internally. * Update issue templates * Update issue templates * Update issue templates * Patch 1.0.1 Release (Azure#340) * Fix issue in reboot/restart flow and race condition in D2C messaging util (Azure#242) * - Fix an issue for image-based update scenario where the device doesn't reboot after the new image is installed. - Add ADUC_D2C_Message_Type_Device_Properties to avoid a race condition. * Update steps_handler.cpp * Update steps_handler.cpp * Update workflow_utils.c Remove comment * Address PR feedback * Update how-to-build-agent-code.md * Manually integrate PR Azure#58 Co-authored-by: Pierrick Arsenault <[email protected]> * revert clang-format.sh to avoid issues when pipe in staged content * Disable clangformat in precommit hook due to cross ver compat * Fix install-deps issue when --work-folder used on ubuntu 20.04 * Cleanup sandbox on start of deployment processing (Azure#247) * Added README section for Azure CLI (Azure#254) * Merge 'develop' into 'main' (Azure#243) (Azure#262) (Azure#264) Fix issue in reboot/restart flow and race condition in D2C messaging util (Azure#242) - Fix an issue for image-based update scenario where the device doesn't reboot after the new image is installed. - Add ADUC_D2C_Message_Type_Device_Properties to avoid a race condition. Note | These changes passed e2e verification internally. Co-authored-by: Nox-MSFT <[email protected]> Co-authored-by: Nox-MSFT <[email protected]> * Use 'bool' instead of '_Bool' (Azure#268) * sort paths before asserting in systemutils_forEachDir tests (Azure#265) * sort paths before asserting in systemutils_forEachDir tests * Revamp test to fully utilize test fixture instance and have bare minimum test code * clang-format * Remove stale debug trace from main() (Azure#257) * Fix many memory leaks and reenable UT (Azure#283) * fix memleak in workflow_get_workfolder * Fix leak of hash array in workflow_get_update_file * remove unused include in steps_handler * clang-format steps_handler * Remove unused include in file_test_utils * memleak, use workflow_free in AutoWorkflowHandle * split autoopendir impl, throw on opendir failure * make findFilesInDir iterative, guard non-dir arg * uncomment source_update_cache_utils unit tests * Fix many memleaks (valgrind) in MoveToUpdateCache * Remove curl dependency in https_proxy_utils (Bug 42504722) (Azure#282) * Remove curl dependency in https_proxy_utils * PR comments * Remove mallocAndStrcpy_s header * Update encoded test * log result.ResultCode instead of result on nested edge startup failure (Azure#280) * remove do dep packages * fix install_aduc_deps * Handle errors when download handler plugin symbol missing (Azure#284) * Make DH Factory LoadDownloadHandler noexcept * Make DH Plugin noexcept * throw plugin exception, extract DH extmgr helper * Fix ProcessDownloadHandlerExtensibility docs * Add missing Log_Error for caught PluginException * create erc for each dh export and rmv catch in ADUC_DownloadHandlerPlugin_OnUpdateWorkflowCompleted * Bug 42442896: zlog - incorrect threadproc signature (Azure#287) * Removed log message for retrieving connection information from connection string (Azure#292) * Updated doxygen version (Azure#289) * Updated doxygen version * Changed product name to reflect documentation and removed pre-version * Changed install-deps to clean up after itself (Azure#295) * Updated install-deps to remove old files and cleanup after itself * Fixed script errors * one line fix (Azure#297) * use helper for recursive mkdir (Azure#301) * Try to reconnect to IoT Hub on bad credential or expired SAS token (when using AIS) (Azure#298) * Fix undefined references error in adu-shell (Azure#305) * Took Jeff's suggestion for removing the pthread_cancel calls (Azure#302) * Turn d2c_messaging unit tests into functional tests and skipped by default. (Azure#306) * use TestCaseFixture ptr, not void ptr (Azure#308) * fix zlog file handle leak (Azure#310) * fix zlog file handle leak * set ret=1 upfront and ret 1 when RunAsDesiredUser returns false * rmv last ret=1 straggler * CP: Fix up issues with d2c_messaging. Working on WIOT. Needs to be brought to develop. (Azure#314) Co-authored-by: Jeff Miller <[email protected]> * Fix build pipeline by fixing cpp-tidy errors (Azure#313) * Fix deadlock in zlog flush deinit (Azure#315) * Fix deadlock in zlog finish flush * rmv flush thread * use zlog_flush_buffer and init zlog_last_flushed to 0 * Fix regression in ADUC_Logging_Init to allow agent to start (Azure#317) * Update cached workfolder when processing replacement workflow (Azure#322) Fixes issue where replacement workflow processing uses the previous workflow's workfolder sandbox that was in the property cache. * Update README.md (Azure#294) * Moved the output of catch from cout to cerr for all CATCH_CONFIG_RUNNER unit tests (Azure#323) * Mark test case "30 retries - httpStatus 401" as functional - takes 30s to run (Azure#325) Co-authored-by: Jeff Miller <[email protected]> * cherry-pick from wiot-s1 feature branch: GetConnectionInfoFromConnectionString crashes on failure. (Azure#324) (Azure#326) Co-authored-by: Jeff Miller <[email protected]> * Fix overwrite of contract maj ver in downloaders and comp enumerator (Azure#327) * fix contract majVer overwrite with minVer in content downloaders and content enumerator * fix contract comparison logic * Fixes the E2E Pipeline so all tests pass and scenarios are run (Azure#329) * Removing the cppcheck and clang-tidy to see if that is what is causing the pipeline builds to fail * Making linking changes to see if that fixes the build error * Adding debug lines * Added timeout failures * Added call to set device name when configuring agent through config file - fixes diagnostics * Removed output of the connection string during test * Added input params checks to ConnectionStringUtils_IsNestedEdge to prevent test failures (Azure#330) * Added input params check to prevent bad access * Changed null check to IsNullOrEmpty() * Upgraded patch version (Azure#331) * Fix bug in swupdate-handler v2 example (Azure#333) * Solving merge conflicts main to develop (Azure#338) * Merge 'develop' into 'main' (Azure#243) Fix issue in reboot/restart flow and race condition in D2C messaging util (Azure#242) - Fix an issue for image-based update scenario where the device doesn't reboot after the new image is installed. - Add ADUC_D2C_Message_Type_Device_Properties to avoid a race condition. Note | These changes passed e2e verification internally. * Update issue templates * Update issue templates * Update issue templates Co-authored-by: Nox-MSFT <[email protected]> Co-authored-by: Esha Shah <[email protected]> Co-authored-by: Nox-MSFT <[email protected]> Co-authored-by: Takashi Matsuoka <[email protected]> Co-authored-by: jw-msft <[email protected]> Co-authored-by: Pierrick Arsenault <[email protected]> Co-authored-by: Andrew Brown <[email protected]> Co-authored-by: Jeff Miller <[email protected]> Co-authored-by: Shiyi Peng <[email protected]> Co-authored-by: shiyi-peng <[email protected]> Co-authored-by: Esha Shah <[email protected]> * Release Patch 1.0.2 (Azure#376) Co-authored-by: Pierrick Arsenault <[email protected]> Co-authored-by: Nox-MSFT <[email protected]> Co-authored-by: Jeff Miller <[email protected]> Co-authored-by: Esha Shah <[email protected]> Co-authored-by: Takashi Matsuoka <[email protected]> Co-authored-by: jw-msft <[email protected]> Co-authored-by: Andrew Brown <[email protected]> Co-authored-by: Shiyi Peng <[email protected]> Co-authored-by: shiyi-peng <[email protected]> Co-authored-by: Nicholas Hemstreet <[email protected]> Co-authored-by: JoergZeidler <[email protected]> * Update Pipelines Build README.md (Azure#300) Currently says Debian 9 arm32 is a supported pipeline build, but the adu-debian-arm32-build.yml file has the targetOS as Debian 10 - and as far as I am aware this is actually the supported build. Updating to reflect this. * update links (Azure#131) Co-authored-by: Nox-MSFT <[email protected]> * null terminate after strncpy of jws header (Azure#417) (Azure#426) - Cherry-Pick the following commit to main from develop branch: Azure@e40b7e3 - Originally reported by github issue Azure#406 * Update swupdate handler v2 document (Azure#441) * Update DU Agent documents (Azure#433) * Fix broken link in how-to-build-agent-code.md (Azure#501) * chg read count arg to one less-than buf size to avoid nul term write past buffer (Azure#531) * Update agent version to 1.1.0 * Update agent version in build ymls to 1.1.0 Regenerate result.h * Fix bad merge in install-deps.sh Fix bad merge in agent_workflow.c * Fix version number in arm32 build ymls * Fix WinIoT build error --------- Co-authored-by: Esha Shah <[email protected]> Co-authored-by: Nicholas Hemstreet <[email protected]> Co-authored-by: Takashi Matsuoka <[email protected]> Co-authored-by: jw-msft <[email protected]> Co-authored-by: Pierrick Arsenault <[email protected]> Co-authored-by: Andrew Brown <[email protected]> Co-authored-by: Jeff Miller <[email protected]> Co-authored-by: Shiyi Peng <[email protected]> Co-authored-by: shiyi-peng <[email protected]> Co-authored-by: JoergZeidler <[email protected]> Co-authored-by: GeorgeSiggins <[email protected]> Co-authored-by: Dane Walton <[email protected]>
- Loading branch information
1 parent
9b088ad
commit 85c541e
Showing
22 changed files
with
55 additions
and
90 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,22 @@ | ||
# Proxy Updates and multi-component updating | ||
|
||
This document describes how Proxy Updates can support updating multiple **component(s)** on the target IoT device by using the multi-step ordered execution feature introduced in the Public Preview Refresh Release. | ||
|
||
Proxy updates can target over-the-air updates to multiple components on the target IoT device or multiple sensors connected to the target IoT device. Use cases where proxy updates is applicable include: | ||
This document explains how Proxy Updates, using the multi-step ordered execution (MSOE) feature, can update multiple components on the IoT device or sensors connected to it. The Device Update agent on the main device facilitates the update process for the connected sensors since they cannot connect to the IoT hub directly. Proxy Updates are useful in scenarios where multiple components or sensors require updates. Examples of such scenarios include: | ||
|
||
* Targeting specific update files to different partitions on the device. | ||
* Targeting specific update files to different apps/components on the device | ||
* Targeting specific update files to sensors connected to IoT devices over a network protocol (e.g., USB, CANbus etc.). | ||
|
||
In order to update a component or components that connected to a IoTHub-Connected target IoT Device (also referred in the documentation as '**Host Device**' from here on), the device builder must register a custom **Component Enumerator Extension** that is built specifically for their IoT devices. This is required so that the Device Update Agent can map a **'child update'** with a specific component, or group of components, which the update is intended for. | ||
To update components on an IoT device that is connected to an IoTHub, also known as the **Host Device** in this document, the device builder needs to register a custom **Component Enumerator Extension** designed for their device. This registration is necessary for the Device Update Agent to associate a 'child update' with a specific component or group of components targeted for the update. | ||
|
||
> Note: It's important to understand that Device Update service does not know anything about **component(s)** on the target device. | ||
It's crucial to note that the Device Update service does not have any knowledge of the specific components on the target device since it's designed to be device agnostic. Therefore, the device builder must provide the necessary information to the Device Update Agent. This information includes a collection of components such as root file system partitions, firmware partitions, boot partition, or any applications or group of applications that are modeled virtually as a 'component'. The device builder can provide this information to the Agent by developing a Component Enumerator extension and registering it with the Agent. | ||
|
||
> Note: Multi-step ordered execution feature allow for granular update controls including an install order, pre-install, install and post-install steps. Use cases include | ||
> a required preinstall check that is needed to validate the device state before starting an update, etc. Learn more about [multi-step ordered execution](../agent-reference/update-manifest-v4-schema.md). | ||
## How to register multiple components with the Component Enumerator Extension | ||
## Implementing the Component Enumerator Extension | ||
|
||
See [Contoso Component Enumerator](../../src/extensions/component_enumerators/examples/contoso_component_enumerator/README.md) for example on how to implement and register a custom Component Enumerator extension. | ||
To provide information about components on the target device to the Device Update Agent, you can refer to the [Contoso Component Enumerator example](../../src/extensions/component_enumerators/examples/contoso_component_enumerator/README.md). This example provides guidance on how to implement and register a custom Component Enumerator extension. | ||
|
||
## Example Proxy Update | ||
## Proxy Update Example | ||
|
||
See [tutorial using the Device Update agent to do Proxy Updates](../../src/extensions/component_enumerators/examples/contoso_component_enumerator/demo/README.md) with sample updates for components connected to a Contoso Virtual Vacuum device. |
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
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