summaryrefslogtreecommitdiffstats
path: root/chrome/browser/sync/protocol/client_debug_info.proto
blob: 55ca4f643fbfeb08a17327c24b83f298ff8de5d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// Common sync protocol for encrypted data.

syntax = "proto2";

option optimize_for = LITE_RUNTIME;
option retain_unknown_fields = true;

package sync_pb;

// The additional info here is from SyncerStatus. They get sent when the event
// SYNC_CYCLE_COMPLETED  is sent.
message SyncCycleCompletedEventInfo {
  optional bool syncer_stuck = 1;
  optional int32 num_blocking_conflicts = 2;
  optional int32 num_non_blocking_conflicts = 3;
}

message DebugEventInfo {
  // These events are sent by |SyncManager| class. Note: In the code they each
  // of these events have some additional info but we are not sending them to
  // server.
  enum EventType {
    AUTH_ERROR = 1; // Auth error. Note this gets generated even during
                    // successful auth with the error set to none.
    UPDATED_TOKEN = 2; // Client received an updated token.
    PASSPHRASE_REQUIRED = 3; // Cryptographer needs passphrase.
    PASSPHRASE_ACCEPTED = 4; // Passphrase was accepted by cryptographer.
    INITIALIZATION_COMPLETE = 5; // Sync Initialization is complete.

    // |STOP_SYNCING_PERMANENTLY| event should never be seen by the server in
    // the absence of bugs.
    STOP_SYNCING_PERMANENTLY = 6; // Server sent stop syncing permanently.

    ENCRYPTED_TYPES_CHANGED = 9; // Set of encrypted types has changed.
    ENCRYPTION_COMPLETE = 7; // Client has finished encrypting all data.
    ACTIONABLE_ERROR = 8; // Client received an actionable error.
  }
  optional EventType type = 1;
  optional SyncCycleCompletedEventInfo sync_cycle_completed_event_info = 2;
}

message DebugInfo {
  repeated DebugEventInfo events = 1;

  // Whether cryptographer is ready to encrypt and decrypt data.
  optional bool cryptographer_ready = 2;

  // Cryptographer has pending keys which indicates the correct passphrase
  // has not been provided yet.
  optional bool cryptographer_has_pending_keys = 3;

  // Indicates client has dropped some events to save bandwidth.
  optional bool events_dropped = 4;
}