e5f6f2571d43eb65e0b27dd8d50f2c1f0b3fe30f |
|
20-Apr-2017 |
Daniel Erat <derat@chromium.org> |
update_engine: Use org.chromium.NetworkProxyService. Make update_engine call Chrome's new org.chromium.NetworkProxyService D-Bus service to resolve network proxies instead of using org.chromium.LibCrosService. The new service supports asynchronous replies instead of responding via D-Bus signals. BUG=chromium:446115,chromium:703217 TEST=unit tests pass; also added debug logging and verified that chrome's proxy settings are used (cherry picked from commit 941cf235c5e56eddc6e4f2de2f38bee032a4dead) Cherry-pick updated to resolve conflicts with existing code in AOSP. Change-Id: I8c0704482e9988fe9ed14d32797b3a5b8da3d46a Reviewed-on: https://chromium-review.googlesource.com/497491 Commit-Ready: Dan Erat <derat@chromium.org> Tested-by: Dan Erat <derat@chromium.org> Reviewed-by: Ben Chan <benchan@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
3582194c10c47ffcda9ad7881e7fa6eed2404406 |
|
05-Feb-2017 |
Alex Deymo <deymo@google.com> |
Allow to cancel a proxy resolution request. After calling GetProxiesForUrl(), there was no way to prevent the proxy resolver from calling the passed callback once the response is ready. This implies that the object passed in the callback (normally as the "data" pointer) must be kept alive until the callback comes back. This patch allows to cancel an ongoing request and converts the passed callback to a base::Callback instead of using a raw pointer. Bug: 34178297 Test: Added unittests. Change-Id: Ie544d0230fd0c2dc85c6b9eaca9b5b13702516fa
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
80f70ff45f8ea9a679c0c3ed0dc143dd2fe2b63e |
|
11-Feb-2016 |
Alex Deymo <deymo@google.com> |
Build unittests in Brillo. Many unittests do not pass for simple reasons that will be addressed later. This CL includes all the changes to make the unittests build. In particular, the generated DBus mocks, required to build several unittests are now included here. The dbus-constants.h files were moved to the system_api repo, so they can be removed from here. The unittest build is only enabled for Brillo targets, since non-Brillo targets don't even build DBus. Bug: 26955860 TEST=`mmma` on edison-eng (and aosp_arm-eng). Change-Id: Ib38241f0a6eb99b1d60d72db6bcfd125d38e3fad
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
3f39d5cc753905874d8d93bef94f857b8808f19e |
|
13-Oct-2015 |
Alex Vakulenko <avakulenko@google.com> |
update_engine: Rename "chromeos" -> "brillo" in include paths and namespaces libchromeos is transitioning to libbrillo and chromeos namespaces and include directory is changing to brillo. Bug: 24872993 Change-Id: I770659a95be380a50fe3b2ba9f91d65818f40945
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
b8803bbfe96abce0ae792a93bc975d478d98d16a |
|
20-Aug-2015 |
Alex Deymo <deymo@google.com> |
Split DBus client proxies into separated headers. Each daemon we talk to should expose its own DBus library. This patch splits the DBus proxies we generate from other daemon's .xml files into separated header files so we can then replace them with libraries. BUG=b:23084776 TEST=FEATURES=test emerge-link update_engine Change-Id: Idbf1671eb7fc4259d493dbe2c8bcc8dad5b8784f
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
aea4c1cea20dda7ae7e85fc8924a2d784f70d806 |
|
20-Aug-2015 |
Alex Deymo <deymo@google.com> |
Re-license update_engine to Apache2 This patch automatically replaced the license on all text files from Chromium OS (BSD style) to AOSP (Apache2), keeping the original year as a reference. The license header was added to .gyp and .gypi files, the NOTICE was replaced with a copy of the Apache2 license and MODULE_LICENSE_* file was updated. BUG=b/23084294 TEST=grep 'Chromium OS Authors' doesn't find anything. Change-Id: Ie5083750755f5180a8a785b24fe67dbf9195cd10
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
305345001d85ca2282112c2a30fe75c7a4773491 |
|
21-Jul-2015 |
Alex Deymo <deymo@chromium.org> |
update_engine: Switch to chrome-dbus for client requests in update_engine update_engine daemon acts as DBus client to send DBus calls to shill, power_manager and chrome, and to listen for signals from shill, chrome and login_manager. This patch migrates these calls and signals to use chrome-dbus framework instead of dbus-glib. All references to dbus-glib code are removed. BUG=chromium:419827 TEST=Updated unittest. Deployed on a link device and tested interactions with shill and chromium. Change-Id: I31b389e0d1690cccb115ff3b6539c876ba81bd0e Reviewed-on: https://chromium-review.googlesource.com/290990 Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Alex Deymo <deymo@chromium.org> Commit-Queue: Alex Deymo <deymo@chromium.org> Trybot-Ready: Alex Deymo <deymo@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
60ca1a7bca7cc804ec80b510483081ef894de4cd |
|
19-Jun-2015 |
Alex Deymo <deymo@chromium.org> |
update_engine: Migrate time-based glib main loop calls to MessageLoop. This patch replaces most calls to g_idle_add* and g_timeout_add* with the equivalent MessageLoop::Post*Task(). To maintain compatibility with unittests running the main loop and doing I/O we instantiate a GlibMessageLoop for those tests. BUG=chromium:499886 TEST=unittests still pass. Change-Id: Ic87ba69bc47391ac3c36d1bfc3ca28d069666af1 Reviewed-on: https://chromium-review.googlesource.com/281197 Reviewed-by: Alex Vakulenko <avakulenko@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org> Commit-Queue: Alex Deymo <deymo@chromium.org> Trybot-Ready: Alex Deymo <deymo@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
aab50e31f0b80ed53a9b8d5dbabcf943974bd32c |
|
11-Nov-2014 |
Alex Deymo <deymo@chromium.org> |
Include the implemented header first in all projects. The Google C++ style guide dictates that foo.cc and foo_unittest.cc should include foo.h in the first place, so missing headers in foo.h are detected with a compile error of the module implementing them and not when another module uses them. This CL sweeps across all the .cc file in platform2 enforcing this. BUG=None TEST=cbuildbot amd64-generic Change-Id: I41835835caba13f54c3c844ecf552eb0e47efa9d Reviewed-on: https://chromium-review.googlesource.com/228894 Tested-by: Alex Deymo <deymo@chromium.org> Reviewed-by: Alex Deymo <deymo@chromium.org> Commit-Queue: Alex Vakulenko <avakulenko@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
f329b933db41d26644a97afef928eb1b319d6d99 |
|
30-Oct-2014 |
Alex Deymo <deymo@chromium.org> |
update_engine: Fix all the "using" declaration usage. This patch removes unused "using" declarations, that is, declarations included in a .cc file at a global scope such that "using foo::bar" that later don't use the identifier "bar" at all. This also unifies the usage of these identifiers in the .cc files in favor of using the short name defined by the using declaration. For example, in several cases the .h refer to a type like "std::string" because using declarations are forbidden in header files while the .cc includes "using std::string;" with the purpose of just writting "string" in the .cc file. Very rarely, the full identifier is used when a local name ocludes it, for example, StringVectorToGStrv() and StringVectorToString() in utils.cc named its argument just "vector" need to refer to std::vector with the full name. This patch renames those arguments instead. Finally, it also sorts a few lists of using declarations that weren't in order. BUG=None TEST=FEATURES=test emerge-link update_engine Change-Id: I30f6b9510ecb7e03640f1951c48d5bb106309840 Reviewed-on: https://chromium-review.googlesource.com/226423 Reviewed-by: Alex Vakulenko <avakulenko@chromium.org> Commit-Queue: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
d2779df63aaad8b65fc5d4badee7dbc9bed7f2b6 |
|
16-Jun-2014 |
Alex Vakulenko <avakulenko@chromium.org> |
update_engine: fixed warnings from cpplint Fixed all the cpplint warnings in update engine. BUG=None TEST=Unit tests still pass. Change-Id: I285ae858eec8abe0b26ff203b99a42a200ceb71c Reviewed-on: https://chromium-review.googlesource.com/204027 Reviewed-by: Alex Vakulenko <avakulenko@chromium.org> Tested-by: Alex Vakulenko <avakulenko@chromium.org> Commit-Queue: Alex Vakulenko <avakulenko@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
3d21b12092a0108f77c3332b85eaf81524fe7c32 |
|
29-May-2014 |
Alex Deymo <deymo@chromium.org> |
Fix memory leak on ChromeBrowserProxyResolverTest. ChromeBrowserProxyResolverTest.SuccessTest was creating a duplicate of the string returned by DBusMessageGetArgs_3() when the mocked Chrome returns a proxy response. The caller of this interface should not delete the returned pointers (as they are pointers to the dbus message) so the test ended up leaking those strings. This patch fixes that and uses a StrickMock for the dbus interface to catch some unexpected calls also included on this fix. Finally, testing::SetArgumentPointee() was deprecated in favor of testing::SetArgPointee(). BUG=chromium:378548 TEST=`FEATURES="test" USE="clang asan" emerge-link update_engine` doesn't complain about ChromeBrowserProxyResolverTest. Change-Id: Ie348eeab964fbfdeaafa68db9016d7ab36835552 Reviewed-on: https://chromium-review.googlesource.com/202071 Reviewed-by: Alex Vakulenko <avakulenko@chromium.org> Reviewed-by: David Zeuthen <zeuthen@chromium.org> Commit-Queue: Alex Deymo <deymo@chromium.org> Tested-by: Alex Deymo <deymo@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
1b9d6ae00b3c3badf9785584c2c867710f214a62 |
|
03-Mar-2014 |
Gilad Arnold <garnold@chromium.org> |
Further cleanup around DBus interface classes. * Removed the "Glib" part from the various DbusGlib class name and added "Wrapper" instead: only part of the methods here declared have anything to do with Glib; in essence, this is an interface containing wrappers for various DBus functions. * Changed "Dbus" to "DBus", to comply with the rest of the world. * Renamed the actual implementation "RealDBusWrapper" (instead of "Concrete"). * Separated out RealDBusWrapper into its own header file. Client code, which often only cares about the abstract class, does not need to pull it unless specifically requiring it. * Cleaned up the includes in these headers. Aside from all that, also renamed system_state.cc into real_system_state.cc, as this is what this file contains. BUG=None TEST=Unit tests. Change-Id: I015c407cbc159aba8b5925eb0e916ba604c829cd Reviewed-on: https://chromium-review.googlesource.com/189373 Reviewed-by: Gilad Arnold <garnold@chromium.org> Tested-by: Gilad Arnold <garnold@chromium.org> Commit-Queue: Gilad Arnold <garnold@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
b752fb342f2d8f9766f13764e4747a50a1195308 |
|
03-Mar-2014 |
Gilad Arnold <garnold@chromium.org> |
Cleanup DBus interface. Prior to importing the DBus interface into the Policy Manager, this removes some clutter and fixes some behaviors. * Switch from using dbus_g_proxy_new_for_name_owner() to using dbus_g_proxy_new_for_name() instead. This has been advised in the past (see chromium:209102) as the _owner version is mostly used for binding to interfaces that do not retain the well-known name. It is not appropriate for our use cases, where the provider inhibits the well-known location constantly, nor is it a good thing given that providers (e.g. Chrome) could get recycled. * More consistent abstraction for variadic DBus functions: (a) We now distinguish between different numbers of input/output arguments by appending these numbers to the names of interface functions (e.g. ProxyCall_3_0 delegates 3 input arguments and zero outputs); (b) We drop G_TYPE arguments and embed them as constants in the delegating code. This makes more sense because these types are constants and depend on the actual values, which are bound to predetermined C/C++ types anyway; (c) It is still possible to override such functions by variating the types of actual arguments (currently not exercised). * The above also shortens the argument list for several DBus interface functions, saving us from needing to prune them to fit in mock methods with a maximum of 10 arguments (as was previously necessary). * Removed an unnecessary #include; better comments; more descriptive argument names. Other notable changes in client code: * Some cleaup in chrome_browser_proxy_resolver.cc, removing unnecessary functions and reverting the proxy reacquisition logic introduced in CL:15693, which is now redundant. BUG=None TEST=Unit tests. Change-Id: I8063bb3e35c34212a8be1ae507834c931ee5a0b0 Reviewed-on: https://chromium-review.googlesource.com/188560 Tested-by: Gilad Arnold <garnold@chromium.org> Reviewed-by: David Zeuthen <zeuthen@chromium.org> Reviewed-by: Alex Deymo <deymo@chromium.org> Commit-Queue: Gilad Arnold <garnold@chromium.org>
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
518502acf1261c9b6ad2a84ee5d429077847ec18 |
|
14-Mar-2011 |
Andrew de los Reyes <adlr@chromium.org> |
AU: Handle inability to get proxy servers from Chrome better. Rather than have the proxy resolve fail immediately if Chrome can't be contacted, asynchronously return kNoProxy so that update will continue w/o proxy servers. This makes the new Chrome Browser Proxy Resolver behave like the other proxy resolvers. BUG=chromium-os:13039 TEST=unittest; initctl stop ui; do an update Review URL: http://codereview.chromium.org/6681042 Change-Id: I757df5e221ae3311f7d0f507fbf054176e3fa418
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|
000d895da247697f4e4e0c67a3a847f71fca8eb9 |
|
03-Mar-2011 |
Andrew de los Reyes <adlr@chromium.org> |
AU: Full proxy support This CL Introduces a new proxy resolver that queries Chrome browser for all URLs. This means the updater now works with Proxy AutoConfiguration (PAC) files and automatic proxy detection. BUG=chromium-os:9478 TEST=performed update, unittests Review URL: http://codereview.chromium.org/6594025 Change-Id: I2c169aec06109e3eabc4011e0b536685dfd13f79
/system/update_engine/chrome_browser_proxy_resolver_unittest.cc
|