New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 636140 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Aug 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 2
Type: Feature



Sign in to add a comment

[USS] Allow services to specify a storage key

Project Member Reported by s...@chromium.org, Aug 9 2016

Issue description

Right now the ModelTypeService implementations must use client tag to communicate with the processor. This is bad for a couple reasons

1) Client tag has to be backwards compatible with pre-USS clients.
2) Client tag might be very large, for typed urls this could be many KB each.
3) Client tag is often not easily useful for the service. They may want a composite key that consists of multiple different values, and parsing apart a string with constant prefix is a hassle.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Aug 11 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b9932b5ad0b4632a7d651ae3442241ec759c5293

commit b9932b5ad0b4632a7d651ae3442241ec759c5293
Author: skym <skym@chromium.org>
Date: Thu Aug 11 23:30:47 2016

Introducing the concept for a storage key for ModelTypeServices, which is used to communicate with the processor and independent of client tag and client tag hashes.

Ideally the services will be able to use any object, not just a std::string. My intention is that this can be done in a subsequent change, if we decide we still want to do so.

BUG= 636140 

Review-Url: https://codereview.chromium.org/2222373003
Cr-Commit-Position: refs/heads/master@{#411438}

[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/data_batch.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/entity_change.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/entity_change.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/fake_model_type_service.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/fake_model_type_service.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/metadata_batch.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/metadata_batch.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/metadata_change_list.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/model_type_change_processor.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/api/model_type_service.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/data_batch_impl.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/data_batch_impl.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/data_batch_impl_unittest.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/processor_entity_tracker.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/processor_entity_tracker.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/processor_entity_tracker_unittest.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/shared_model_type_processor.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/shared_model_type_processor.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/core/shared_model_type_processor_unittest.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/test/engine/mock_model_type_worker.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync/test/engine/mock_model_type_worker.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync_driver/device_info_service.cc
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync_driver/device_info_service.h
[modify] https://crrev.com/b9932b5ad0b4632a7d651ae3442241ec759c5293/components/sync_driver/device_info_service_unittest.cc

Comment 2 by s...@chromium.org, Aug 16 2016

Status: Fixed (was: Assigned)
At this point we are going to leave it as a std::string. Services that want complex/multipart keys can serialize a proto into the storage key.

Sign in to add a comment