Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(312)

Issue 9460047: sync: remove use of protobuf extensions in protocol to reduce static init overhead. (Closed)

Created:
8 years, 10 months ago by tim (not reviewing)
Modified:
8 years, 9 months ago
CC:
chromium-reviews, ncarter (slow), akalin, Raghu Simha, mihaip+watch_chromium.org, Aaron Boodman, dhollowa+watch_chromium.org, Yoyo Zhou, Mattias Nissler (ping if slow), GeorgeY, Nico
Visibility:
Public.

Description

sync: remove use of protobuf extensions in protocol to reduce static init overhead. Instead, we now use optional fields in EntitySpecifics. Because the tag numbers remain the same, this is a wire-format compatible change. This incurs a (#datatypes * sizeof(void*))*#sync_items memory cost, due to storing extra pointers. In practice, for a typical account on windows this amounts to < 200k, and the static init cost is believed to be greater. Note - upcoming features in protobufs may let us eliminate this extra memory overhead. Also: The testserver tests were broken on ToT due to a bug in _SaveEntry's saving of mtime which is fixed in this patch. TBR=yoz@chromium.org TBR=mnissler@chromium.org TBR=pkasting@chromium.org TBR=georgey@chromium.org BUG=94992, 94925 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=124912

Patch Set 1 : init #

Patch Set 2 : testserver changes #

Patch Set 3 : fix nigori access in testserver #

Total comments: 4

Patch Set 4 : fix chromiumsync_test.py #

Patch Set 5 : renames #

Patch Set 6 : nick's comment #

Total comments: 8

Patch Set 7 : fred's review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+472 lines, -605 lines) Patch
M chrome/browser/extensions/app_notification_manager.cc View 4 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/extensions/app_notification_manager_sync_unittest.cc View 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/extensions/extension_service_unittest.cc View 1 2 3 4 7 chunks +7 lines, -12 lines 0 comments Download
M chrome/browser/extensions/extension_sync_data.cc View 3 chunks +7 lines, -9 lines 0 comments Download
M chrome/browser/extensions/extension_sync_data_unittest.cc View 8 chunks +9 lines, -11 lines 0 comments Download
M chrome/browser/extensions/settings/setting_sync_data.cc View 1 2 3 1 chunk +6 lines, -6 lines 0 comments Download
M chrome/browser/extensions/settings/settings_sync_util.cc View 1 2 3 3 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/prefs/pref_model_associator.cc View 1 2 3 5 chunks +5 lines, -6 lines 0 comments Download
M chrome/browser/search_engines/template_url_service.cc View 4 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/search_engines/template_url_service_sync_unittest.cc View 2 chunks +4 lines, -6 lines 0 comments Download
M chrome/browser/sync/abstract_profile_sync_service_test.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/api/sync_change_unittest.cc View 6 chunks +6 lines, -9 lines 0 comments Download
M chrome/browser/sync/api/sync_data.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/engine/apply_updates_command_unittest.cc View 1 2 3 4 11 chunks +12 lines, -16 lines 0 comments Download
M chrome/browser/sync/engine/build_commit_command.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/engine/clear_data_command_unittest.cc View 1 2 3 1 chunk +0 lines, -1 line 0 comments Download
M chrome/browser/sync/engine/conflict_resolver.cc View 1 2 3 1 chunk +5 lines, -7 lines 0 comments Download
M chrome/browser/sync/engine/download_updates_command_unittest.cc View 1 2 3 4 1 chunk +0 lines, -1 line 0 comments Download
M chrome/browser/sync/engine/nigori_util_unittest.cc View 1 2 3 4 3 chunks +6 lines, -5 lines 0 comments Download
M chrome/browser/sync/engine/process_commit_response_command_unittest.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/engine/store_timestamps_command.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/engine/syncapi_internal.cc View 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/sync/engine/syncer_proto_util.cc View 1 2 3 4 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/sync/engine/syncer_unittest.cc View 1 2 3 4 17 chunks +32 lines, -42 lines 0 comments Download
M chrome/browser/sync/engine/syncer_util.cc View 1 2 3 4 3 chunks +5 lines, -7 lines 0 comments Download
M chrome/browser/sync/engine/verify_updates_command_unittest.cc View 1 2 3 4 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/sync/glue/password_change_processor.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/glue/session_change_processor.cc View 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/sync/glue/typed_url_change_processor.cc View 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/sync/internal_api/base_node.cc View 1 2 3 4 7 chunks +16 lines, -16 lines 0 comments Download
M chrome/browser/sync/internal_api/change_record_unittest.cc View 1 2 3 4 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/sync/internal_api/syncapi_unittest.cc View 1 2 3 4 17 chunks +25 lines, -30 lines 0 comments Download
M chrome/browser/sync/internal_api/write_node.cc View 1 2 3 4 9 chunks +16 lines, -16 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_autofill_unittest.cc View 1 2 3 3 chunks +3 lines, -4 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_preference_unittest.cc View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_session_unittest.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/protocol/app_notification_specifics.proto View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/app_setting_specifics.proto View 2 chunks +0 lines, -4 lines 0 comments Download
M chrome/browser/sync/protocol/app_specifics.proto View 2 chunks +0 lines, -4 lines 0 comments Download
M chrome/browser/sync/protocol/autofill_specifics.proto View 2 chunks +0 lines, -6 lines 0 comments Download
M chrome/browser/sync/protocol/bookmark_specifics.proto View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/extension_setting_specifics.proto View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/extension_specifics.proto View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/nigori_specifics.proto View 2 chunks +0 lines, -4 lines 0 comments Download
M chrome/browser/sync/protocol/password_specifics.proto View 2 chunks +0 lines, -4 lines 0 comments Download
M chrome/browser/sync/protocol/preference_specifics.proto View 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/proto_enum_conversions.h View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/sync/protocol/proto_value_conversions.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/protocol/proto_value_conversions.cc View 1 2 3 4 5 6 3 chunks +21 lines, -21 lines 0 comments Download
M chrome/browser/sync/protocol/proto_value_conversions_unittest.cc View 1 2 3 4 1 chunk +19 lines, -19 lines 0 comments Download
M chrome/browser/sync/protocol/search_engine_specifics.proto View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/session_specifics.proto View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/sync.proto View 1 2 3 4 5 6 5 chunks +49 lines, -14 lines 0 comments Download
M chrome/browser/sync/protocol/theme_specifics.proto View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/protocol/typed_url_specifics.proto View 2 chunks +0 lines, -6 lines 0 comments Download
M chrome/browser/sync/syncable/directory_backing_store.cc View 1 2 3 4 3 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/sync/syncable/directory_backing_store_unittest.cc View 1 2 3 4 chunks +34 lines, -39 lines 0 comments Download
M chrome/browser/sync/syncable/model_type.h View 1 2 3 4 3 chunks +9 lines, -9 lines 0 comments Download
M chrome/browser/sync/syncable/model_type.cc View 1 2 3 4 2 chunks +49 lines, -49 lines 0 comments Download
M chrome/browser/sync/syncable/syncable.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/sync/syncable/syncable_unittest.cc View 1 2 3 4 7 chunks +14 lines, -16 lines 0 comments Download
M chrome/browser/sync/test/engine/mock_connection_manager.cc View 1 2 3 4 3 chunks +4 lines, -4 lines 0 comments Download
D chrome/browser/sync/test/engine/proto_extension_validator.h View 1 chunk +0 lines, -55 lines 0 comments Download
M chrome/browser/sync/test/integration/sync_test.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/webdata/autocomplete_syncable_service.cc View 4 chunks +5 lines, -4 lines 0 comments Download
M chrome/browser/webdata/autofill_profile_syncable_service.cc View 4 chunks +4 lines, -3 lines 0 comments Download
M chrome/browser/webdata/autofill_profile_syncable_service_unittest.cc View 1 2 3 4 5 6 2 chunks +4 lines, -6 lines 0 comments Download
M net/tools/testserver/chromiumsync.py View 1 2 3 4 5 11 chunks +45 lines, -44 lines 0 comments Download
M net/tools/testserver/chromiumsync_test.py View 1 2 3 4 5 6 3 chunks +9 lines, -8 lines 0 comments Download

Messages

Total messages: 15 (0 generated)
tim (not reviewing)
Ready for a peek. I added Nick for chromiumsync.py changes in case his protobuf fu ...
8 years, 9 months ago (2012-02-28 05:31:25 UTC) #1
tim (not reviewing)
Note: I just remembered I have a pile of comments to update all over the ...
8 years, 9 months ago (2012-02-28 05:33:35 UTC) #2
ncarter (slow)
http://codereview.chromium.org/9460047/diff/14001/net/tools/testserver/chromiumsync.py File net/tools/testserver/chromiumsync.py (right): http://codereview.chromium.org/9460047/diff/14001/net/tools/testserver/chromiumsync.py#newcode9 net/tools/testserver/chromiumsync.py:9: """ Did you run chromiumsync_test.py? It has pretty good ...
8 years, 9 months ago (2012-02-28 18:45:08 UTC) #3
tim (not reviewing)
Think this is ready for a good look now! Thanks for patience. http://codereview.chromium.org/9460047/diff/14001/net/tools/testserver/chromiumsync.py File net/tools/testserver/chromiumsync.py ...
8 years, 9 months ago (2012-03-01 22:07:01 UTC) #4
ncarter (slow)
Python stuff LGTM with one nit. http://codereview.chromium.org/9460047/diff/32002/net/tools/testserver/chromiumsync_test.py File net/tools/testserver/chromiumsync_test.py (right): http://codereview.chromium.org/9460047/diff/32002/net/tools/testserver/chromiumsync_test.py#newcode17 net/tools/testserver/chromiumsync_test.py:17: from google.protobuf import ...
8 years, 9 months ago (2012-03-01 22:13:05 UTC) #5
akalin
LGTM after nits you may need to add OWNERS http://codereview.chromium.org/9460047/diff/32002/chrome/browser/sync/protocol/proto_value_conversions.cc File chrome/browser/sync/protocol/proto_value_conversions.cc (right): http://codereview.chromium.org/9460047/diff/32002/chrome/browser/sync/protocol/proto_value_conversions.cc#newcode95 chrome/browser/sync/protocol/proto_value_conversions.cc:95: ...
8 years, 9 months ago (2012-03-02 23:56:49 UTC) #6
tim (not reviewing)
adding tbr's to cc thakis, should I be updating perf_expectations.json with this patch or afterwards?
8 years, 9 months ago (2012-03-03 03:09:49 UTC) #7
Nico
Afterwards. Thanks for doing this! (Since our perf infra measures files w static initializers and ...
8 years, 9 months ago (2012-03-03 03:34:54 UTC) #8
Peter Kasting
On 2012/03/03 03:09:49, timsteele wrote: > adding tbr's to cc If we're going to be ...
8 years, 9 months ago (2012-03-03 06:37:18 UTC) #9
tim (not reviewing)
On 2012/03/03 06:37:18, Peter Kasting wrote: > On 2012/03/03 03:09:49, timsteele wrote: > > adding ...
8 years, 9 months ago (2012-03-03 21:49:30 UTC) #10
Peter Kasting
Thanks! search_engines LGTM
8 years, 9 months ago (2012-03-04 00:49:33 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tim@chromium.org/9460047/36001
8 years, 9 months ago (2012-03-04 21:19:42 UTC) #12
commit-bot: I haz the power
Change committed as 124912
8 years, 9 months ago (2012-03-04 23:33:39 UTC) #13
pliard
Thanks very much for doing that! On Sat, Mar 3, 2012 at 4:34 AM, Nico ...
8 years, 9 months ago (2012-03-05 08:13:53 UTC) #14
Mattias Nissler (ping if slow)
8 years, 9 months ago (2012-03-12 14:14:14 UTC) #15
LGTM FWIW :)

Powered by Google App Engine
This is Rietveld 408576698