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

Side by Side Diff: sync/internal_api/attachments/proto/attachment_store.proto

Issue 690723004: Add per attachment metadata records. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 syntax = "proto2"; 5 syntax = "proto2";
6 6
7 option optimize_for = LITE_RUNTIME; 7 option optimize_for = LITE_RUNTIME;
8 option retain_unknown_fields = true; 8 option retain_unknown_fields = true;
9 9
10 package attachment_store_pb; 10 package attachment_store_pb;
11 11
12 // Metadata for leveldb attachment store database. 12 // Metadata for leveldb attachment store database.
13 message AttachmentStoreMetadata { 13 message AttachmentStoreMetadata {
14 // |schema_version| indicates format in which data is written in attachment 14 // |schema_version| indicates format in which data is written in attachment
15 // store. Needed for upgrade and to prevent newer data from being loaded by 15 // store. Needed for upgrade and to prevent newer data from being loaded by
16 // older code that doesn't understand it. 16 // older code that doesn't understand it.
17 optional int32 schema_version = 1; 17 optional int32 schema_version = 1;
18 } 18 }
19
20 // Metadata for attachment in attachemnt store. Storing metadata in separate
21 // record from actual data allows to enumerate attachments in the store without
maniscalco 2014/10/30 16:40:20 allows to -> allows us to (and again later in this
pavely 2014/10/30 18:28:36 Done.
22 // incurring cost to read actual data. It also allows to update attachment
23 // metadata independent of the data.
24 message AttachmentRecordMetadata {
maniscalco 2014/10/30 16:40:20 I remember that we already have a proto called Att
pavely 2014/10/30 18:28:36 This proto file already declares attachment_store_
maniscalco 2014/10/30 18:33:09 SGTM
25 // Size of attachment data. Useful for attachment store space management.
26 optional int64 attachment_size = 2;
maniscalco 2014/10/30 16:40:20 2 not 1?
pavely 2014/10/30 18:28:36 Sorry, I started with CRC, but reverted it.
27 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698