44906965d0809992052e47e11809ec730813d8b0 |
|
09-Jan-2018 |
Sen Jiang <senj@google.com> |
Merge remote-tracking branch 'goog/upstream-master'. The following commits were reverted: 840703a Fix update over cellular network on guest account eaad5d0 Do not merge to AOSP: Fixes the link to brillo-clang-format in CrOS 740efad Reboot even if a system update is not available. Fixed a few sign compare warnings. Had to ifdef out 2 SquashfsFilesystemTest because it depends on unsquashfs -m. Test: update_engine_unittests Change-Id: I6f4ca5003e78c76064ec60d0797505d8c18d00bf Merged-In: I6f4ca5003e78c76064ec60d0797505d8c18d00bf
|
9321f501029e7c0fdca55db3a79c9dcb24e4a767 |
|
07-Sep-2017 |
Aaron Wood <aaronwood@google.com> |
Track bytes received across multiple update files When downloading the packages that comprise a multi-package or multi-app update, the UpdateAttempter receives BytesReceived() callbacks with bytes_received resetting to 0 for each file. This causes the progress calculations to be incorrect. This change tracks the total of the previously downloaded packages within the DownloadAction, so that it properly tracks. Resumed downloads will jump ahead over skipped data, when the payload is incremented. Bug: 65451460 Tests: Added unit tests to directly test the accumulation and the the transition from the previous state to UpdateStatus::DOWNLOADING when the first bytes are received. Change-Id: I3b540df16b9a664b09f53ee3ec962e2cbc8adf1b (cherry picked from commit d6f869dbd9952be8a926e80c4f1e172845ab8d5f)
/system/update_engine/payload_consumer/download_action.h
|
7ecda265a87236e83cf820364947a1618872b6be |
|
12-Jul-2017 |
Amin Hassani <ahassani@google.com> |
Open partitions with O_DSYNC flag only if the update is periodic. Currently when updating we always open the target partition with flag O_DSYNC (CL:562552), but this makes all infrastructure operations like 'cros flash', provisioning, force update, paygen, etc much slower. This changes the update engine to only add O_DSYNC flag if an update is triggered by periodic checks (not interactively forced). This means if the user clicks on 'check for update' it will be an interactive update and O_DSYNC will not be used. This change keeps the AOSP partitions open without O_DSYNC flag. This CL uses non-interactive mode for all unit tests but currently there are no integration test like provisioning for triggering periodic updates. Currently 'parrot' board canaries (only board with rotating HDD) is failing due to timeouts related to slow updates. This CL potentially will clear that problem. TEST=cros_workon_make --test, installed an image with/out the O_DSYCN flag and measured the 'cros flash' time. BUG=chromium:738027 Change-Id: If45fcf5e798b9c9353e09021ad812c859d983a65 Reviewed-on: https://chromium-review.googlesource.com/567360 Commit-Ready: Amin Hassani <ahassani@chromium.org> Tested-by: Amin Hassani <ahassani@chromium.org> Reviewed-by: Grant Grundler <grundler@chromium.org>
/system/update_engine/payload_consumer/download_action.h
|
5ae865b431cc041feed82f1db28a38e99dbd631f |
|
18-Apr-2017 |
Sen Jiang <senj@google.com> |
Resume multiple payloads. DownloadAction will first go through all the already applied payload and only downloading the manifest and filling in partitions info in install plan without applying or downloading any operations. And then resume the partially applied payload using states in prefs. Moved constuction of MultiRangeHttpFetcher from UpdateAttempter to DownloadAction, because we now need to setup the range for every payload, also reduced code duplication. Also fixed download progress for multi payload. Bug: 36252799 Test: stop an update during second payload and resume the update Change-Id: I9ee54a87d15d88c7a14a13575965b19c1773340b (cherry picked from commit 7162b666318cdd6c75b73fa6a0b06b23559de3e5)
/system/update_engine/payload_consumer/download_action.h
|
6c73668ddcd3dd905c976808bfa13609eeef00b9 |
|
11-Mar-2017 |
Sen Jiang <senj@google.com> |
Apply multiple payload in DownloadAction. DownloadAction will now call DeltaPerformer once for each payload. Bug: 36252799 Test: update two payload works! Test: update_engine_unittest Change-Id: Ibd4f3a4af9f701852f2c70b9384ca9d1fedacbeb (cherry picked from commit 7bd9f0b95403664229b701a13dca03c31a46fb49)
/system/update_engine/payload_consumer/download_action.h
|
0affc2c099fac47b999ba39f8f1bacb418e65a97 |
|
11-Feb-2017 |
Sen Jiang <senj@google.com> |
Parse multiple packages from Omaha response. The multi-payload info are stored in OmahaResponse and InstallPlan, but we still can only apply the first payload for now. Bug: 36252799 Test: mma -j Test: update_engine_unittests Change-Id: I5ca63944ae9082670d0e67888409374f140d4245 (cherry picked from commit 2aba8a87d4fac245a2e2d238b3159f8eabce630f)
/system/update_engine/payload_consumer/download_action.h
|
14c0da88a93aa7b1aa71d5e7e923b537f0d419f3 |
|
21-Jul-2016 |
Alex Deymo <deymo@google.com> |
Remove libcurl support from update_engine_sideload. While sideloading an update from recovery we don't need nor want to download payload from HTTP(S) URLs, only local file:// are supported. This patch moves libcurl_http_fetcher and certificate_checker files out of libpayload_consumer dropping the libcurl and libssl dependencies from it and the update_engine_sideload. Bug: 27178350 TEST=build UE for Brillo and Android. Unittests still pass and update_engine_sideload doesn't link to libcurl. Change-Id: Iffefdb094654f7277dc825c041fe55aac9ee8756
/system/update_engine/payload_consumer/download_action.h
|
f28585764e91b7c25a7c2856ff645c8bb22d64a9 |
|
25-Feb-2016 |
Alex Deymo <deymo@google.com> |
Implement suspend, resume and cancel the download. The DownloadAction can now be suspended and resumed, using the existing libcurl hooks to pause the download. For canceling an ongoing update, this patch leverages the existing StopProcessing method previously used in unittest only with a slight change: Stopping the ActionProcessor also removes all the pending actions. The LibcurlHttpFetcher Pause/Unpause methods where improved to support (not crash) if paused in circumstances where there isn't a current connection, like when waiting for the proxy resolver and when trying to reconnect. Finally, the value of ongoing_update_ is now properly set in the UpdateAttempter. Bug: 27047026 TEST=Tested suspending, resuming and canceling the update on a device. TEST=Added unittest for the Pause/Unpause logic. Change-Id: I0df1e1a8cf70a3b736bc9cd4899d37813f381b94
/system/update_engine/payload_consumer/download_action.h
|
1b3556cbe66b3f5be35f6117d4013ddc199b064c |
|
03-Feb-2016 |
Alex Deymo <deymo@google.com> |
Allow null SystemState in the DownloadAction. The SystemState is only defined in the libupdate_engine library, so it may not be defined for other users of libpayload_consumer. This patch allows to pass a nullptr for the SystemState while explicitly passing the other classes defined in libpayload_consumer upon construction. Bug: None TEST=FEATURES=test emerge-link update_engine TEST=`mmma system/update_engine` on aosp_arm-eng and edison-eng Change-Id: I535d0184a85e0a167ac65875f6e7c07832efbf40
/system/update_engine/payload_consumer/download_action.h
|
0103c36caa2e38e034e0d22185736b9ccfb35c58 |
|
20-Jan-2016 |
Alex Vakulenko <avakulenko@google.com> |
update_engine: Update libchrome APIs to r369476 The new libchrome has been ported from Chromium and some APIs have changed. Make necessary changes at call sites. Change-Id: I42e65bda7f1dbdf6f6e0ebf356d2cfea6b729193
/system/update_engine/payload_consumer/download_action.h
|
542c19bf271011913a9f352f58e140224c936736 |
|
03-Dec-2015 |
Alex Deymo <deymo@google.com> |
Remove SystemState references from DeltaPerformer. DeltaPerformer is used as part of the DownloadAction and had references to the global SystemState. The common references to BootControlInterface (to query the partitions based on the names from the payload) and the HardwareInterface (for dev-mode bits) are now referenced directly from the DeltaPerformer. The calls to UpdateAttempter and PayloadState were moved to the DownloadActionDelegate since these calls are received by classes outside the payload_consumer. Bug: 25773375 TEST=FEATURES=test emerge-link update_engine Change-Id: Id2e81d5ccf835cad22f03b069c681dcce104c456
/system/update_engine/payload_consumer/download_action.h
|
22ad86121ba56c576bfcaa23e085dab881bd4ff5 |
|
20-Nov-2015 |
Alex Deymo <deymo@google.com> |
Delete DownloadActionDelegate::SetDownloadStatus() method. This method is only used by the caller to detect a programming error in the DownloadAction (calling BytesReceived when not downloading) and log a message. This patch removes the method from the delegate interface and makes sure it doesn't issue a call to BytesReceived when not activelly downloading. Bug: 25773375 TEST=FEATURES=test emerge-link update_engine Change-Id: I8ff5c53f1fd40c0777b3f6523703a8bee71c019d
/system/update_engine/payload_consumer/download_action.h
|
39910dcd1d68987ccee7c3031dc269233a8490bb |
|
10-Nov-2015 |
Alex Deymo <deymo@google.com> |
Split payload application code into a subdirectory. This patch splits from the main libupdate_engine code the part that is strictly used to download and apply a payload into a new static library, moving the code to subdirectories. The new library is divided in two subdirectories: common/ and payload_consumer/, and should not depend on other update_engine files outside those two subdirectories. The main difference between those two is that the common/ tools are more generic and not tied to the payload consumer process, but otherwise they are both compiled together. There are still dependencies from the new libpayload_consumer library into the main directory files and DBus generated files. Those will be addressed in follow up CLs. Bug: 25197634 Test: FEATURES=test emerge-link update_engine; `mm` on Brillo. Change-Id: Id8d0204ea573627e6e26ca9ea17b9592ca95bc23
/system/update_engine/payload_consumer/download_action.h
|