| 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 551 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 562 // server. | 562 // server. |
| 563 optional ChipBag bag_of_chips = 11; | 563 optional ChipBag bag_of_chips = 11; |
| 564 | 564 |
| 565 // Google API key. | 565 // Google API key. |
| 566 optional string api_key = 12; | 566 optional string api_key = 12; |
| 567 | 567 |
| 568 // Client's self-reported state. | 568 // Client's self-reported state. |
| 569 // The client should set this on every message sent to the server, though its | 569 // The client should set this on every message sent to the server, though its |
| 570 // member fields may often be unset. | 570 // member fields may often be unset. |
| 571 optional ClientStatus client_status = 13; | 571 optional ClientStatus client_status = 13; |
| 572 |
| 573 // The ID that our invalidation client used to identify itself to the server. |
| 574 // Sending the ID here allows the server to not send notifications of our own |
| 575 // changes to our invalidator. |
| 576 optional string invalidator_client_id = 14; |
| 572 }; | 577 }; |
| 573 | 578 |
| 574 message CommitResponse { | 579 message CommitResponse { |
| 575 enum ResponseType { | 580 enum ResponseType { |
| 576 SUCCESS = 1; | 581 SUCCESS = 1; |
| 577 CONFLICT = 2; // You're out of date; update and check your data | 582 CONFLICT = 2; // You're out of date; update and check your data |
| 578 // TODO(ncarter): What's the difference between RETRY and TRANSIENT_ERROR? | 583 // TODO(ncarter): What's the difference between RETRY and TRANSIENT_ERROR? |
| 579 RETRY = 3; // Someone has a conflicting, non-expired session open | 584 RETRY = 3; // Someone has a conflicting, non-expired session open |
| 580 INVALID_MESSAGE = 4; // What the client sent was invalid, and trying again | 585 INVALID_MESSAGE = 4; // What the client sent was invalid, and trying again |
| 581 // won't help. | 586 // won't help. |
| (...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 760 // is absent then the whole client (all datatypes) is throttled. | 765 // is absent then the whole client (all datatypes) is throttled. |
| 761 repeated int32 error_data_type_ids = 5; | 766 repeated int32 error_data_type_ids = 5; |
| 762 } | 767 } |
| 763 optional Error error = 13; | 768 optional Error error = 13; |
| 764 | 769 |
| 765 // The new per-client state for this client. If set, should be persisted and | 770 // The new per-client state for this client. If set, should be persisted and |
| 766 // sent with any subsequent ClientToServerMessages. | 771 // sent with any subsequent ClientToServerMessages. |
| 767 optional ChipBag new_bag_of_chips = 14; | 772 optional ChipBag new_bag_of_chips = 14; |
| 768 }; | 773 }; |
| 769 | 774 |
| OLD | NEW |