| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // Sync protocol for communication between sync client and server. | 5 // Sync protocol for communication between sync client and server. |
| 6 | 6 |
| 7 // Update proto_value_conversions{.h,.cc,_unittest.cc} if you change | 7 // Update proto_value_conversions{.h,.cc,_unittest.cc} if you change |
| 8 // any fields in this file. | 8 // any fields in this file. |
| 9 | 9 |
| 10 syntax = "proto2"; | 10 syntax = "proto2"; |
| (...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 492 optional bool sync_problem_detected = 8 [default = false]; | 492 optional bool sync_problem_detected = 8 [default = false]; |
| 493 | 493 |
| 494 // Client side state information for debugging purpose. | 494 // Client side state information for debugging purpose. |
| 495 // This is only sent on the first getupdates of every sync cycle, | 495 // This is only sent on the first getupdates of every sync cycle, |
| 496 // as an optimization to save bandwidth. | 496 // as an optimization to save bandwidth. |
| 497 optional DebugInfo debug_info = 10; | 497 optional DebugInfo debug_info = 10; |
| 498 | 498 |
| 499 // Per-client state for use by the server. Sent with every message sent to the | 499 // Per-client state for use by the server. Sent with every message sent to the |
| 500 // server. | 500 // server. |
| 501 optional ChipBag bag_of_chips = 11; | 501 optional ChipBag bag_of_chips = 11; |
| 502 |
| 503 // Google API key. |
| 504 optional string api_key = 12; |
| 502 }; | 505 }; |
| 503 | 506 |
| 504 message CommitResponse { | 507 message CommitResponse { |
| 505 enum ResponseType { | 508 enum ResponseType { |
| 506 SUCCESS = 1; | 509 SUCCESS = 1; |
| 507 CONFLICT = 2; // You're out of date; update and check your data | 510 CONFLICT = 2; // You're out of date; update and check your data |
| 508 // TODO(ncarter): What's the difference between RETRY and TRANSIENT_ERROR? | 511 // TODO(ncarter): What's the difference between RETRY and TRANSIENT_ERROR? |
| 509 RETRY = 3; // Someone has a conflicting, non-expired session open | 512 RETRY = 3; // Someone has a conflicting, non-expired session open |
| 510 INVALID_MESSAGE = 4; // What the client sent was invalid, and trying again | 513 INVALID_MESSAGE = 4; // What the client sent was invalid, and trying again |
| 511 // won't help. | 514 // won't help. |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 685 // is absent then the whole client (all datatypes) is throttled. | 688 // is absent then the whole client (all datatypes) is throttled. |
| 686 repeated int32 error_data_type_ids = 5; | 689 repeated int32 error_data_type_ids = 5; |
| 687 } | 690 } |
| 688 optional Error error = 13; | 691 optional Error error = 13; |
| 689 | 692 |
| 690 // The new per-client state for this client. If set, should be persisted and | 693 // The new per-client state for this client. If set, should be persisted and |
| 691 // sent with any subsequent ClientToServerMessages. | 694 // sent with any subsequent ClientToServerMessages. |
| 692 optional ChipBag new_bag_of_chips = 14; | 695 optional ChipBag new_bag_of_chips = 14; |
| 693 }; | 696 }; |
| 694 | 697 |
| OLD | NEW |