github.com/cockroachdb/cockroach@v20.2.0-alpha.1+incompatible/c-deps/libroach/protos/util/tracing/recorded_span.pb.cc (about)

     1  // Generated by the protocol buffer compiler.  DO NOT EDIT!
     2  // source: util/tracing/recorded_span.proto
     3  
     4  #include "util/tracing/recorded_span.pb.h"
     5  
     6  #include <algorithm>
     7  
     8  #include <google/protobuf/stubs/common.h>
     9  #include <google/protobuf/stubs/port.h>
    10  #include <google/protobuf/io/coded_stream.h>
    11  #include <google/protobuf/wire_format_lite_inl.h>
    12  #include <google/protobuf/io/zero_copy_stream_impl_lite.h>
    13  // This is a temporary google only hack
    14  #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
    15  #include "third_party/protobuf/version.h"
    16  #endif
    17  // @@protoc_insertion_point(includes)
    18  
    19  namespace protobuf_google_2fprotobuf_2fany_2eproto {
    20  extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fany_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Any;
    21  }  // namespace protobuf_google_2fprotobuf_2fany_2eproto
    22  namespace protobuf_google_2fprotobuf_2fduration_2eproto {
    23  extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fduration_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Duration;
    24  }  // namespace protobuf_google_2fprotobuf_2fduration_2eproto
    25  namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto {
    26  extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2ftimestamp_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Timestamp;
    27  }  // namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto
    28  namespace protobuf_util_2ftracing_2frecorded_5fspan_2eproto {
    29  extern PROTOBUF_INTERNAL_EXPORT_protobuf_util_2ftracing_2frecorded_5fspan_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_LogRecord_Field;
    30  extern PROTOBUF_INTERNAL_EXPORT_protobuf_util_2ftracing_2frecorded_5fspan_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_NormalizedSpan_TagsEntry_DoNotUse;
    31  extern PROTOBUF_INTERNAL_EXPORT_protobuf_util_2ftracing_2frecorded_5fspan_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_RecordedSpan_BaggageEntry_DoNotUse;
    32  extern PROTOBUF_INTERNAL_EXPORT_protobuf_util_2ftracing_2frecorded_5fspan_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_RecordedSpan_TagsEntry_DoNotUse;
    33  extern PROTOBUF_INTERNAL_EXPORT_protobuf_util_2ftracing_2frecorded_5fspan_2eproto ::google::protobuf::internal::SCCInfo<2> scc_info_LogRecord;
    34  extern PROTOBUF_INTERNAL_EXPORT_protobuf_util_2ftracing_2frecorded_5fspan_2eproto ::google::protobuf::internal::SCCInfo<4> scc_info_NormalizedSpan;
    35  }  // namespace protobuf_util_2ftracing_2frecorded_5fspan_2eproto
    36  namespace cockroach {
    37  namespace util {
    38  namespace tracing {
    39  class LogRecord_FieldDefaultTypeInternal {
    40   public:
    41    ::google::protobuf::internal::ExplicitlyConstructed<LogRecord_Field>
    42        _instance;
    43  } _LogRecord_Field_default_instance_;
    44  class LogRecordDefaultTypeInternal {
    45   public:
    46    ::google::protobuf::internal::ExplicitlyConstructed<LogRecord>
    47        _instance;
    48  } _LogRecord_default_instance_;
    49  class RecordedSpan_BaggageEntry_DoNotUseDefaultTypeInternal {
    50   public:
    51    ::google::protobuf::internal::ExplicitlyConstructed<RecordedSpan_BaggageEntry_DoNotUse>
    52        _instance;
    53  } _RecordedSpan_BaggageEntry_DoNotUse_default_instance_;
    54  class RecordedSpan_TagsEntry_DoNotUseDefaultTypeInternal {
    55   public:
    56    ::google::protobuf::internal::ExplicitlyConstructed<RecordedSpan_TagsEntry_DoNotUse>
    57        _instance;
    58  } _RecordedSpan_TagsEntry_DoNotUse_default_instance_;
    59  class RecordedSpanDefaultTypeInternal {
    60   public:
    61    ::google::protobuf::internal::ExplicitlyConstructed<RecordedSpan>
    62        _instance;
    63  } _RecordedSpan_default_instance_;
    64  class NormalizedSpan_TagsEntry_DoNotUseDefaultTypeInternal {
    65   public:
    66    ::google::protobuf::internal::ExplicitlyConstructed<NormalizedSpan_TagsEntry_DoNotUse>
    67        _instance;
    68  } _NormalizedSpan_TagsEntry_DoNotUse_default_instance_;
    69  class NormalizedSpanDefaultTypeInternal {
    70   public:
    71    ::google::protobuf::internal::ExplicitlyConstructed<NormalizedSpan>
    72        _instance;
    73  } _NormalizedSpan_default_instance_;
    74  }  // namespace tracing
    75  }  // namespace util
    76  }  // namespace cockroach
    77  namespace protobuf_util_2ftracing_2frecorded_5fspan_2eproto {
    78  static void InitDefaultsLogRecord_Field() {
    79    GOOGLE_PROTOBUF_VERIFY_VERSION;
    80  
    81    {
    82      void* ptr = &::cockroach::util::tracing::_LogRecord_Field_default_instance_;
    83      new (ptr) ::cockroach::util::tracing::LogRecord_Field();
    84      ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
    85    }
    86    ::cockroach::util::tracing::LogRecord_Field::InitAsDefaultInstance();
    87  }
    88  
    89  ::google::protobuf::internal::SCCInfo<0> scc_info_LogRecord_Field =
    90      {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsLogRecord_Field}, {}};
    91  
    92  static void InitDefaultsLogRecord() {
    93    GOOGLE_PROTOBUF_VERIFY_VERSION;
    94  
    95    {
    96      void* ptr = &::cockroach::util::tracing::_LogRecord_default_instance_;
    97      new (ptr) ::cockroach::util::tracing::LogRecord();
    98      ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
    99    }
   100    ::cockroach::util::tracing::LogRecord::InitAsDefaultInstance();
   101  }
   102  
   103  ::google::protobuf::internal::SCCInfo<2> scc_info_LogRecord =
   104      {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 2, InitDefaultsLogRecord}, {
   105        &protobuf_google_2fprotobuf_2ftimestamp_2eproto::scc_info_Timestamp.base,
   106        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_LogRecord_Field.base,}};
   107  
   108  static void InitDefaultsRecordedSpan_BaggageEntry_DoNotUse() {
   109    GOOGLE_PROTOBUF_VERIFY_VERSION;
   110  
   111    {
   112      void* ptr = &::cockroach::util::tracing::_RecordedSpan_BaggageEntry_DoNotUse_default_instance_;
   113      new (ptr) ::cockroach::util::tracing::RecordedSpan_BaggageEntry_DoNotUse();
   114    }
   115    ::cockroach::util::tracing::RecordedSpan_BaggageEntry_DoNotUse::InitAsDefaultInstance();
   116  }
   117  
   118  ::google::protobuf::internal::SCCInfo<0> scc_info_RecordedSpan_BaggageEntry_DoNotUse =
   119      {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsRecordedSpan_BaggageEntry_DoNotUse}, {}};
   120  
   121  static void InitDefaultsRecordedSpan_TagsEntry_DoNotUse() {
   122    GOOGLE_PROTOBUF_VERIFY_VERSION;
   123  
   124    {
   125      void* ptr = &::cockroach::util::tracing::_RecordedSpan_TagsEntry_DoNotUse_default_instance_;
   126      new (ptr) ::cockroach::util::tracing::RecordedSpan_TagsEntry_DoNotUse();
   127    }
   128    ::cockroach::util::tracing::RecordedSpan_TagsEntry_DoNotUse::InitAsDefaultInstance();
   129  }
   130  
   131  ::google::protobuf::internal::SCCInfo<0> scc_info_RecordedSpan_TagsEntry_DoNotUse =
   132      {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsRecordedSpan_TagsEntry_DoNotUse}, {}};
   133  
   134  static void InitDefaultsRecordedSpan() {
   135    GOOGLE_PROTOBUF_VERIFY_VERSION;
   136  
   137    {
   138      void* ptr = &::cockroach::util::tracing::_RecordedSpan_default_instance_;
   139      new (ptr) ::cockroach::util::tracing::RecordedSpan();
   140      ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
   141    }
   142    ::cockroach::util::tracing::RecordedSpan::InitAsDefaultInstance();
   143  }
   144  
   145  ::google::protobuf::internal::SCCInfo<6> scc_info_RecordedSpan =
   146      {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 6, InitDefaultsRecordedSpan}, {
   147        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_RecordedSpan_BaggageEntry_DoNotUse.base,
   148        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_RecordedSpan_TagsEntry_DoNotUse.base,
   149        &protobuf_google_2fprotobuf_2ftimestamp_2eproto::scc_info_Timestamp.base,
   150        &protobuf_google_2fprotobuf_2fduration_2eproto::scc_info_Duration.base,
   151        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_LogRecord.base,
   152        &protobuf_google_2fprotobuf_2fany_2eproto::scc_info_Any.base,}};
   153  
   154  static void InitDefaultsNormalizedSpan_TagsEntry_DoNotUse() {
   155    GOOGLE_PROTOBUF_VERIFY_VERSION;
   156  
   157    {
   158      void* ptr = &::cockroach::util::tracing::_NormalizedSpan_TagsEntry_DoNotUse_default_instance_;
   159      new (ptr) ::cockroach::util::tracing::NormalizedSpan_TagsEntry_DoNotUse();
   160    }
   161    ::cockroach::util::tracing::NormalizedSpan_TagsEntry_DoNotUse::InitAsDefaultInstance();
   162  }
   163  
   164  ::google::protobuf::internal::SCCInfo<0> scc_info_NormalizedSpan_TagsEntry_DoNotUse =
   165      {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsNormalizedSpan_TagsEntry_DoNotUse}, {}};
   166  
   167  static void InitDefaultsNormalizedSpan() {
   168    GOOGLE_PROTOBUF_VERIFY_VERSION;
   169  
   170    {
   171      void* ptr = &::cockroach::util::tracing::_NormalizedSpan_default_instance_;
   172      new (ptr) ::cockroach::util::tracing::NormalizedSpan();
   173      ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
   174    }
   175    ::cockroach::util::tracing::NormalizedSpan::InitAsDefaultInstance();
   176  }
   177  
   178  ::google::protobuf::internal::SCCInfo<4> scc_info_NormalizedSpan =
   179      {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 4, InitDefaultsNormalizedSpan}, {
   180        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_NormalizedSpan_TagsEntry_DoNotUse.base,
   181        &protobuf_google_2fprotobuf_2ftimestamp_2eproto::scc_info_Timestamp.base,
   182        &protobuf_google_2fprotobuf_2fduration_2eproto::scc_info_Duration.base,
   183        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_LogRecord.base,}};
   184  
   185  void InitDefaults() {
   186    ::google::protobuf::internal::InitSCC(&scc_info_LogRecord_Field.base);
   187    ::google::protobuf::internal::InitSCC(&scc_info_LogRecord.base);
   188    ::google::protobuf::internal::InitSCC(&scc_info_RecordedSpan_BaggageEntry_DoNotUse.base);
   189    ::google::protobuf::internal::InitSCC(&scc_info_RecordedSpan_TagsEntry_DoNotUse.base);
   190    ::google::protobuf::internal::InitSCC(&scc_info_RecordedSpan.base);
   191    ::google::protobuf::internal::InitSCC(&scc_info_NormalizedSpan_TagsEntry_DoNotUse.base);
   192    ::google::protobuf::internal::InitSCC(&scc_info_NormalizedSpan.base);
   193  }
   194  
   195  }  // namespace protobuf_util_2ftracing_2frecorded_5fspan_2eproto
   196  namespace cockroach {
   197  namespace util {
   198  namespace tracing {
   199  
   200  // ===================================================================
   201  
   202  void LogRecord_Field::InitAsDefaultInstance() {
   203  }
   204  #if !defined(_MSC_VER) || _MSC_VER >= 1900
   205  const int LogRecord_Field::kKeyFieldNumber;
   206  const int LogRecord_Field::kValueFieldNumber;
   207  #endif  // !defined(_MSC_VER) || _MSC_VER >= 1900
   208  
   209  LogRecord_Field::LogRecord_Field()
   210    : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
   211    ::google::protobuf::internal::InitSCC(
   212        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_LogRecord_Field.base);
   213    SharedCtor();
   214    // @@protoc_insertion_point(constructor:cockroach.util.tracing.LogRecord.Field)
   215  }
   216  LogRecord_Field::LogRecord_Field(const LogRecord_Field& from)
   217    : ::google::protobuf::MessageLite(),
   218        _internal_metadata_(NULL) {
   219    _internal_metadata_.MergeFrom(from._internal_metadata_);
   220    key_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   221    if (from.key().size() > 0) {
   222      key_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.key_);
   223    }
   224    value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   225    if (from.value().size() > 0) {
   226      value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.value_);
   227    }
   228    // @@protoc_insertion_point(copy_constructor:cockroach.util.tracing.LogRecord.Field)
   229  }
   230  
   231  void LogRecord_Field::SharedCtor() {
   232    key_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   233    value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   234  }
   235  
   236  LogRecord_Field::~LogRecord_Field() {
   237    // @@protoc_insertion_point(destructor:cockroach.util.tracing.LogRecord.Field)
   238    SharedDtor();
   239  }
   240  
   241  void LogRecord_Field::SharedDtor() {
   242    key_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   243    value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   244  }
   245  
   246  void LogRecord_Field::SetCachedSize(int size) const {
   247    _cached_size_.Set(size);
   248  }
   249  const LogRecord_Field& LogRecord_Field::default_instance() {
   250    ::google::protobuf::internal::InitSCC(&protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_LogRecord_Field.base);
   251    return *internal_default_instance();
   252  }
   253  
   254  
   255  void LogRecord_Field::Clear() {
   256  // @@protoc_insertion_point(message_clear_start:cockroach.util.tracing.LogRecord.Field)
   257    ::google::protobuf::uint32 cached_has_bits = 0;
   258    // Prevent compiler warnings about cached_has_bits being unused
   259    (void) cached_has_bits;
   260  
   261    key_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   262    value_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   263    _internal_metadata_.Clear();
   264  }
   265  
   266  bool LogRecord_Field::MergePartialFromCodedStream(
   267      ::google::protobuf::io::CodedInputStream* input) {
   268  #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
   269    ::google::protobuf::uint32 tag;
   270    ::google::protobuf::internal::LiteUnknownFieldSetter unknown_fields_setter(
   271        &_internal_metadata_);
   272    ::google::protobuf::io::StringOutputStream unknown_fields_output(
   273        unknown_fields_setter.buffer());
   274    ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
   275        &unknown_fields_output, false);
   276    // @@protoc_insertion_point(parse_start:cockroach.util.tracing.LogRecord.Field)
   277    for (;;) {
   278      ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
   279      tag = p.first;
   280      if (!p.second) goto handle_unusual;
   281      switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
   282        // string key = 1;
   283        case 1: {
   284          if (static_cast< ::google::protobuf::uint8>(tag) ==
   285              static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
   286            DO_(::google::protobuf::internal::WireFormatLite::ReadString(
   287                  input, this->mutable_key()));
   288            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   289              this->key().data(), static_cast<int>(this->key().length()),
   290              ::google::protobuf::internal::WireFormatLite::PARSE,
   291              "cockroach.util.tracing.LogRecord.Field.key"));
   292          } else {
   293            goto handle_unusual;
   294          }
   295          break;
   296        }
   297  
   298        // string value = 2;
   299        case 2: {
   300          if (static_cast< ::google::protobuf::uint8>(tag) ==
   301              static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
   302            DO_(::google::protobuf::internal::WireFormatLite::ReadString(
   303                  input, this->mutable_value()));
   304            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   305              this->value().data(), static_cast<int>(this->value().length()),
   306              ::google::protobuf::internal::WireFormatLite::PARSE,
   307              "cockroach.util.tracing.LogRecord.Field.value"));
   308          } else {
   309            goto handle_unusual;
   310          }
   311          break;
   312        }
   313  
   314        default: {
   315        handle_unusual:
   316          if (tag == 0) {
   317            goto success;
   318          }
   319          DO_(::google::protobuf::internal::WireFormatLite::SkipField(
   320              input, tag, &unknown_fields_stream));
   321          break;
   322        }
   323      }
   324    }
   325  success:
   326    // @@protoc_insertion_point(parse_success:cockroach.util.tracing.LogRecord.Field)
   327    return true;
   328  failure:
   329    // @@protoc_insertion_point(parse_failure:cockroach.util.tracing.LogRecord.Field)
   330    return false;
   331  #undef DO_
   332  }
   333  
   334  void LogRecord_Field::SerializeWithCachedSizes(
   335      ::google::protobuf::io::CodedOutputStream* output) const {
   336    // @@protoc_insertion_point(serialize_start:cockroach.util.tracing.LogRecord.Field)
   337    ::google::protobuf::uint32 cached_has_bits = 0;
   338    (void) cached_has_bits;
   339  
   340    // string key = 1;
   341    if (this->key().size() > 0) {
   342      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   343        this->key().data(), static_cast<int>(this->key().length()),
   344        ::google::protobuf::internal::WireFormatLite::SERIALIZE,
   345        "cockroach.util.tracing.LogRecord.Field.key");
   346      ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
   347        1, this->key(), output);
   348    }
   349  
   350    // string value = 2;
   351    if (this->value().size() > 0) {
   352      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   353        this->value().data(), static_cast<int>(this->value().length()),
   354        ::google::protobuf::internal::WireFormatLite::SERIALIZE,
   355        "cockroach.util.tracing.LogRecord.Field.value");
   356      ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
   357        2, this->value(), output);
   358    }
   359  
   360    output->WriteRaw((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).data(),
   361                     static_cast<int>((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size()));
   362    // @@protoc_insertion_point(serialize_end:cockroach.util.tracing.LogRecord.Field)
   363  }
   364  
   365  size_t LogRecord_Field::ByteSizeLong() const {
   366  // @@protoc_insertion_point(message_byte_size_start:cockroach.util.tracing.LogRecord.Field)
   367    size_t total_size = 0;
   368  
   369    total_size += (::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size();
   370  
   371    // string key = 1;
   372    if (this->key().size() > 0) {
   373      total_size += 1 +
   374        ::google::protobuf::internal::WireFormatLite::StringSize(
   375          this->key());
   376    }
   377  
   378    // string value = 2;
   379    if (this->value().size() > 0) {
   380      total_size += 1 +
   381        ::google::protobuf::internal::WireFormatLite::StringSize(
   382          this->value());
   383    }
   384  
   385    int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
   386    SetCachedSize(cached_size);
   387    return total_size;
   388  }
   389  
   390  void LogRecord_Field::CheckTypeAndMergeFrom(
   391      const ::google::protobuf::MessageLite& from) {
   392    MergeFrom(*::google::protobuf::down_cast<const LogRecord_Field*>(&from));
   393  }
   394  
   395  void LogRecord_Field::MergeFrom(const LogRecord_Field& from) {
   396  // @@protoc_insertion_point(class_specific_merge_from_start:cockroach.util.tracing.LogRecord.Field)
   397    GOOGLE_DCHECK_NE(&from, this);
   398    _internal_metadata_.MergeFrom(from._internal_metadata_);
   399    ::google::protobuf::uint32 cached_has_bits = 0;
   400    (void) cached_has_bits;
   401  
   402    if (from.key().size() > 0) {
   403  
   404      key_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.key_);
   405    }
   406    if (from.value().size() > 0) {
   407  
   408      value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.value_);
   409    }
   410  }
   411  
   412  void LogRecord_Field::CopyFrom(const LogRecord_Field& from) {
   413  // @@protoc_insertion_point(class_specific_copy_from_start:cockroach.util.tracing.LogRecord.Field)
   414    if (&from == this) return;
   415    Clear();
   416    MergeFrom(from);
   417  }
   418  
   419  bool LogRecord_Field::IsInitialized() const {
   420    return true;
   421  }
   422  
   423  void LogRecord_Field::Swap(LogRecord_Field* other) {
   424    if (other == this) return;
   425    InternalSwap(other);
   426  }
   427  void LogRecord_Field::InternalSwap(LogRecord_Field* other) {
   428    using std::swap;
   429    key_.Swap(&other->key_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
   430      GetArenaNoVirtual());
   431    value_.Swap(&other->value_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
   432      GetArenaNoVirtual());
   433    _internal_metadata_.Swap(&other->_internal_metadata_);
   434  }
   435  
   436  ::std::string LogRecord_Field::GetTypeName() const {
   437    return "cockroach.util.tracing.LogRecord.Field";
   438  }
   439  
   440  
   441  // ===================================================================
   442  
   443  void LogRecord::InitAsDefaultInstance() {
   444    ::cockroach::util::tracing::_LogRecord_default_instance_._instance.get_mutable()->time_ = const_cast< ::google::protobuf::Timestamp*>(
   445        ::google::protobuf::Timestamp::internal_default_instance());
   446  }
   447  void LogRecord::clear_time() {
   448    if (GetArenaNoVirtual() == NULL && time_ != NULL) {
   449      delete time_;
   450    }
   451    time_ = NULL;
   452  }
   453  #if !defined(_MSC_VER) || _MSC_VER >= 1900
   454  const int LogRecord::kTimeFieldNumber;
   455  const int LogRecord::kFieldsFieldNumber;
   456  #endif  // !defined(_MSC_VER) || _MSC_VER >= 1900
   457  
   458  LogRecord::LogRecord()
   459    : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
   460    ::google::protobuf::internal::InitSCC(
   461        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_LogRecord.base);
   462    SharedCtor();
   463    // @@protoc_insertion_point(constructor:cockroach.util.tracing.LogRecord)
   464  }
   465  LogRecord::LogRecord(const LogRecord& from)
   466    : ::google::protobuf::MessageLite(),
   467        _internal_metadata_(NULL),
   468        fields_(from.fields_) {
   469    _internal_metadata_.MergeFrom(from._internal_metadata_);
   470    if (from.has_time()) {
   471      time_ = new ::google::protobuf::Timestamp(*from.time_);
   472    } else {
   473      time_ = NULL;
   474    }
   475    // @@protoc_insertion_point(copy_constructor:cockroach.util.tracing.LogRecord)
   476  }
   477  
   478  void LogRecord::SharedCtor() {
   479    time_ = NULL;
   480  }
   481  
   482  LogRecord::~LogRecord() {
   483    // @@protoc_insertion_point(destructor:cockroach.util.tracing.LogRecord)
   484    SharedDtor();
   485  }
   486  
   487  void LogRecord::SharedDtor() {
   488    if (this != internal_default_instance()) delete time_;
   489  }
   490  
   491  void LogRecord::SetCachedSize(int size) const {
   492    _cached_size_.Set(size);
   493  }
   494  const LogRecord& LogRecord::default_instance() {
   495    ::google::protobuf::internal::InitSCC(&protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_LogRecord.base);
   496    return *internal_default_instance();
   497  }
   498  
   499  
   500  void LogRecord::Clear() {
   501  // @@protoc_insertion_point(message_clear_start:cockroach.util.tracing.LogRecord)
   502    ::google::protobuf::uint32 cached_has_bits = 0;
   503    // Prevent compiler warnings about cached_has_bits being unused
   504    (void) cached_has_bits;
   505  
   506    fields_.Clear();
   507    if (GetArenaNoVirtual() == NULL && time_ != NULL) {
   508      delete time_;
   509    }
   510    time_ = NULL;
   511    _internal_metadata_.Clear();
   512  }
   513  
   514  bool LogRecord::MergePartialFromCodedStream(
   515      ::google::protobuf::io::CodedInputStream* input) {
   516  #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
   517    ::google::protobuf::uint32 tag;
   518    ::google::protobuf::internal::LiteUnknownFieldSetter unknown_fields_setter(
   519        &_internal_metadata_);
   520    ::google::protobuf::io::StringOutputStream unknown_fields_output(
   521        unknown_fields_setter.buffer());
   522    ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
   523        &unknown_fields_output, false);
   524    // @@protoc_insertion_point(parse_start:cockroach.util.tracing.LogRecord)
   525    for (;;) {
   526      ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
   527      tag = p.first;
   528      if (!p.second) goto handle_unusual;
   529      switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
   530        case 1: {
   531          if (static_cast< ::google::protobuf::uint8>(tag) ==
   532              static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
   533            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
   534                 input, mutable_time()));
   535          } else {
   536            goto handle_unusual;
   537          }
   538          break;
   539        }
   540  
   541        case 2: {
   542          if (static_cast< ::google::protobuf::uint8>(tag) ==
   543              static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
   544            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
   545                  input, add_fields()));
   546          } else {
   547            goto handle_unusual;
   548          }
   549          break;
   550        }
   551  
   552        default: {
   553        handle_unusual:
   554          if (tag == 0) {
   555            goto success;
   556          }
   557          DO_(::google::protobuf::internal::WireFormatLite::SkipField(
   558              input, tag, &unknown_fields_stream));
   559          break;
   560        }
   561      }
   562    }
   563  success:
   564    // @@protoc_insertion_point(parse_success:cockroach.util.tracing.LogRecord)
   565    return true;
   566  failure:
   567    // @@protoc_insertion_point(parse_failure:cockroach.util.tracing.LogRecord)
   568    return false;
   569  #undef DO_
   570  }
   571  
   572  void LogRecord::SerializeWithCachedSizes(
   573      ::google::protobuf::io::CodedOutputStream* output) const {
   574    // @@protoc_insertion_point(serialize_start:cockroach.util.tracing.LogRecord)
   575    ::google::protobuf::uint32 cached_has_bits = 0;
   576    (void) cached_has_bits;
   577  
   578    if (this->has_time()) {
   579      ::google::protobuf::internal::WireFormatLite::WriteMessage(
   580        1, this->_internal_time(), output);
   581    }
   582  
   583    for (unsigned int i = 0,
   584        n = static_cast<unsigned int>(this->fields_size()); i < n; i++) {
   585      ::google::protobuf::internal::WireFormatLite::WriteMessage(
   586        2,
   587        this->fields(static_cast<int>(i)),
   588        output);
   589    }
   590  
   591    output->WriteRaw((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).data(),
   592                     static_cast<int>((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size()));
   593    // @@protoc_insertion_point(serialize_end:cockroach.util.tracing.LogRecord)
   594  }
   595  
   596  size_t LogRecord::ByteSizeLong() const {
   597  // @@protoc_insertion_point(message_byte_size_start:cockroach.util.tracing.LogRecord)
   598    size_t total_size = 0;
   599  
   600    total_size += (::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size();
   601  
   602    {
   603      unsigned int count = static_cast<unsigned int>(this->fields_size());
   604      total_size += 1UL * count;
   605      for (unsigned int i = 0; i < count; i++) {
   606        total_size +=
   607          ::google::protobuf::internal::WireFormatLite::MessageSize(
   608            this->fields(static_cast<int>(i)));
   609      }
   610    }
   611  
   612    if (this->has_time()) {
   613      total_size += 1 +
   614        ::google::protobuf::internal::WireFormatLite::MessageSize(
   615          *time_);
   616    }
   617  
   618    int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
   619    SetCachedSize(cached_size);
   620    return total_size;
   621  }
   622  
   623  void LogRecord::CheckTypeAndMergeFrom(
   624      const ::google::protobuf::MessageLite& from) {
   625    MergeFrom(*::google::protobuf::down_cast<const LogRecord*>(&from));
   626  }
   627  
   628  void LogRecord::MergeFrom(const LogRecord& from) {
   629  // @@protoc_insertion_point(class_specific_merge_from_start:cockroach.util.tracing.LogRecord)
   630    GOOGLE_DCHECK_NE(&from, this);
   631    _internal_metadata_.MergeFrom(from._internal_metadata_);
   632    ::google::protobuf::uint32 cached_has_bits = 0;
   633    (void) cached_has_bits;
   634  
   635    fields_.MergeFrom(from.fields_);
   636    if (from.has_time()) {
   637      mutable_time()->::google::protobuf::Timestamp::MergeFrom(from.time());
   638    }
   639  }
   640  
   641  void LogRecord::CopyFrom(const LogRecord& from) {
   642  // @@protoc_insertion_point(class_specific_copy_from_start:cockroach.util.tracing.LogRecord)
   643    if (&from == this) return;
   644    Clear();
   645    MergeFrom(from);
   646  }
   647  
   648  bool LogRecord::IsInitialized() const {
   649    return true;
   650  }
   651  
   652  void LogRecord::Swap(LogRecord* other) {
   653    if (other == this) return;
   654    InternalSwap(other);
   655  }
   656  void LogRecord::InternalSwap(LogRecord* other) {
   657    using std::swap;
   658    CastToBase(&fields_)->InternalSwap(CastToBase(&other->fields_));
   659    swap(time_, other->time_);
   660    _internal_metadata_.Swap(&other->_internal_metadata_);
   661  }
   662  
   663  ::std::string LogRecord::GetTypeName() const {
   664    return "cockroach.util.tracing.LogRecord";
   665  }
   666  
   667  
   668  // ===================================================================
   669  
   670  RecordedSpan_BaggageEntry_DoNotUse::RecordedSpan_BaggageEntry_DoNotUse() {}
   671  RecordedSpan_BaggageEntry_DoNotUse::RecordedSpan_BaggageEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
   672  void RecordedSpan_BaggageEntry_DoNotUse::MergeFrom(const RecordedSpan_BaggageEntry_DoNotUse& other) {
   673    MergeFromInternal(other);
   674  }
   675  
   676  // ===================================================================
   677  
   678  RecordedSpan_TagsEntry_DoNotUse::RecordedSpan_TagsEntry_DoNotUse() {}
   679  RecordedSpan_TagsEntry_DoNotUse::RecordedSpan_TagsEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
   680  void RecordedSpan_TagsEntry_DoNotUse::MergeFrom(const RecordedSpan_TagsEntry_DoNotUse& other) {
   681    MergeFromInternal(other);
   682  }
   683  
   684  // ===================================================================
   685  
   686  void RecordedSpan::InitAsDefaultInstance() {
   687    ::cockroach::util::tracing::_RecordedSpan_default_instance_._instance.get_mutable()->start_time_ = const_cast< ::google::protobuf::Timestamp*>(
   688        ::google::protobuf::Timestamp::internal_default_instance());
   689    ::cockroach::util::tracing::_RecordedSpan_default_instance_._instance.get_mutable()->duration_ = const_cast< ::google::protobuf::Duration*>(
   690        ::google::protobuf::Duration::internal_default_instance());
   691    ::cockroach::util::tracing::_RecordedSpan_default_instance_._instance.get_mutable()->stats_ = const_cast< ::google::protobuf::Any*>(
   692        ::google::protobuf::Any::internal_default_instance());
   693  }
   694  void RecordedSpan::clear_start_time() {
   695    if (GetArenaNoVirtual() == NULL && start_time_ != NULL) {
   696      delete start_time_;
   697    }
   698    start_time_ = NULL;
   699  }
   700  void RecordedSpan::clear_duration() {
   701    if (GetArenaNoVirtual() == NULL && duration_ != NULL) {
   702      delete duration_;
   703    }
   704    duration_ = NULL;
   705  }
   706  void RecordedSpan::clear_stats() {
   707    if (GetArenaNoVirtual() == NULL && stats_ != NULL) {
   708      delete stats_;
   709    }
   710    stats_ = NULL;
   711  }
   712  #if !defined(_MSC_VER) || _MSC_VER >= 1900
   713  const int RecordedSpan::kTraceIdFieldNumber;
   714  const int RecordedSpan::kSpanIdFieldNumber;
   715  const int RecordedSpan::kParentSpanIdFieldNumber;
   716  const int RecordedSpan::kOperationFieldNumber;
   717  const int RecordedSpan::kBaggageFieldNumber;
   718  const int RecordedSpan::kTagsFieldNumber;
   719  const int RecordedSpan::kStartTimeFieldNumber;
   720  const int RecordedSpan::kDurationFieldNumber;
   721  const int RecordedSpan::kLogsFieldNumber;
   722  const int RecordedSpan::kStatsFieldNumber;
   723  #endif  // !defined(_MSC_VER) || _MSC_VER >= 1900
   724  
   725  RecordedSpan::RecordedSpan()
   726    : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
   727    ::google::protobuf::internal::InitSCC(
   728        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_RecordedSpan.base);
   729    SharedCtor();
   730    // @@protoc_insertion_point(constructor:cockroach.util.tracing.RecordedSpan)
   731  }
   732  RecordedSpan::RecordedSpan(const RecordedSpan& from)
   733    : ::google::protobuf::MessageLite(),
   734        _internal_metadata_(NULL),
   735        logs_(from.logs_) {
   736    _internal_metadata_.MergeFrom(from._internal_metadata_);
   737    baggage_.MergeFrom(from.baggage_);
   738    tags_.MergeFrom(from.tags_);
   739    operation_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   740    if (from.operation().size() > 0) {
   741      operation_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.operation_);
   742    }
   743    if (from.has_start_time()) {
   744      start_time_ = new ::google::protobuf::Timestamp(*from.start_time_);
   745    } else {
   746      start_time_ = NULL;
   747    }
   748    if (from.has_duration()) {
   749      duration_ = new ::google::protobuf::Duration(*from.duration_);
   750    } else {
   751      duration_ = NULL;
   752    }
   753    if (from.has_stats()) {
   754      stats_ = new ::google::protobuf::Any(*from.stats_);
   755    } else {
   756      stats_ = NULL;
   757    }
   758    ::memcpy(&trace_id_, &from.trace_id_,
   759      static_cast<size_t>(reinterpret_cast<char*>(&parent_span_id_) -
   760      reinterpret_cast<char*>(&trace_id_)) + sizeof(parent_span_id_));
   761    // @@protoc_insertion_point(copy_constructor:cockroach.util.tracing.RecordedSpan)
   762  }
   763  
   764  void RecordedSpan::SharedCtor() {
   765    operation_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   766    ::memset(&start_time_, 0, static_cast<size_t>(
   767        reinterpret_cast<char*>(&parent_span_id_) -
   768        reinterpret_cast<char*>(&start_time_)) + sizeof(parent_span_id_));
   769  }
   770  
   771  RecordedSpan::~RecordedSpan() {
   772    // @@protoc_insertion_point(destructor:cockroach.util.tracing.RecordedSpan)
   773    SharedDtor();
   774  }
   775  
   776  void RecordedSpan::SharedDtor() {
   777    operation_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   778    if (this != internal_default_instance()) delete start_time_;
   779    if (this != internal_default_instance()) delete duration_;
   780    if (this != internal_default_instance()) delete stats_;
   781  }
   782  
   783  void RecordedSpan::SetCachedSize(int size) const {
   784    _cached_size_.Set(size);
   785  }
   786  const RecordedSpan& RecordedSpan::default_instance() {
   787    ::google::protobuf::internal::InitSCC(&protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_RecordedSpan.base);
   788    return *internal_default_instance();
   789  }
   790  
   791  
   792  void RecordedSpan::Clear() {
   793  // @@protoc_insertion_point(message_clear_start:cockroach.util.tracing.RecordedSpan)
   794    ::google::protobuf::uint32 cached_has_bits = 0;
   795    // Prevent compiler warnings about cached_has_bits being unused
   796    (void) cached_has_bits;
   797  
   798    baggage_.Clear();
   799    tags_.Clear();
   800    logs_.Clear();
   801    operation_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
   802    if (GetArenaNoVirtual() == NULL && start_time_ != NULL) {
   803      delete start_time_;
   804    }
   805    start_time_ = NULL;
   806    if (GetArenaNoVirtual() == NULL && duration_ != NULL) {
   807      delete duration_;
   808    }
   809    duration_ = NULL;
   810    if (GetArenaNoVirtual() == NULL && stats_ != NULL) {
   811      delete stats_;
   812    }
   813    stats_ = NULL;
   814    ::memset(&trace_id_, 0, static_cast<size_t>(
   815        reinterpret_cast<char*>(&parent_span_id_) -
   816        reinterpret_cast<char*>(&trace_id_)) + sizeof(parent_span_id_));
   817    _internal_metadata_.Clear();
   818  }
   819  
   820  bool RecordedSpan::MergePartialFromCodedStream(
   821      ::google::protobuf::io::CodedInputStream* input) {
   822  #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
   823    ::google::protobuf::uint32 tag;
   824    ::google::protobuf::internal::LiteUnknownFieldSetter unknown_fields_setter(
   825        &_internal_metadata_);
   826    ::google::protobuf::io::StringOutputStream unknown_fields_output(
   827        unknown_fields_setter.buffer());
   828    ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
   829        &unknown_fields_output, false);
   830    // @@protoc_insertion_point(parse_start:cockroach.util.tracing.RecordedSpan)
   831    for (;;) {
   832      ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
   833      tag = p.first;
   834      if (!p.second) goto handle_unusual;
   835      switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
   836        case 1: {
   837          if (static_cast< ::google::protobuf::uint8>(tag) ==
   838              static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
   839  
   840            DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
   841                     ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
   842                   input, &trace_id_)));
   843          } else {
   844            goto handle_unusual;
   845          }
   846          break;
   847        }
   848  
   849        case 2: {
   850          if (static_cast< ::google::protobuf::uint8>(tag) ==
   851              static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
   852  
   853            DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
   854                     ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
   855                   input, &span_id_)));
   856          } else {
   857            goto handle_unusual;
   858          }
   859          break;
   860        }
   861  
   862        case 3: {
   863          if (static_cast< ::google::protobuf::uint8>(tag) ==
   864              static_cast< ::google::protobuf::uint8>(24u /* 24 & 0xFF */)) {
   865  
   866            DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
   867                     ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
   868                   input, &parent_span_id_)));
   869          } else {
   870            goto handle_unusual;
   871          }
   872          break;
   873        }
   874  
   875        // string operation = 4;
   876        case 4: {
   877          if (static_cast< ::google::protobuf::uint8>(tag) ==
   878              static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
   879            DO_(::google::protobuf::internal::WireFormatLite::ReadString(
   880                  input, this->mutable_operation()));
   881            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   882              this->operation().data(), static_cast<int>(this->operation().length()),
   883              ::google::protobuf::internal::WireFormatLite::PARSE,
   884              "cockroach.util.tracing.RecordedSpan.operation"));
   885          } else {
   886            goto handle_unusual;
   887          }
   888          break;
   889        }
   890  
   891        // map<string, string> baggage = 5;
   892        case 5: {
   893          if (static_cast< ::google::protobuf::uint8>(tag) ==
   894              static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
   895            RecordedSpan_BaggageEntry_DoNotUse::Parser< ::google::protobuf::internal::MapFieldLite<
   896                RecordedSpan_BaggageEntry_DoNotUse,
   897                ::std::string, ::std::string,
   898                ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
   899                ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
   900                0 >,
   901              ::google::protobuf::Map< ::std::string, ::std::string > > parser(&baggage_);
   902            DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
   903                input, &parser));
   904            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   905              parser.key().data(), static_cast<int>(parser.key().length()),
   906              ::google::protobuf::internal::WireFormatLite::PARSE,
   907              "cockroach.util.tracing.RecordedSpan.BaggageEntry.key"));
   908            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   909              parser.value().data(), static_cast<int>(parser.value().length()),
   910              ::google::protobuf::internal::WireFormatLite::PARSE,
   911              "cockroach.util.tracing.RecordedSpan.BaggageEntry.value"));
   912          } else {
   913            goto handle_unusual;
   914          }
   915          break;
   916        }
   917  
   918        // map<string, string> tags = 6;
   919        case 6: {
   920          if (static_cast< ::google::protobuf::uint8>(tag) ==
   921              static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
   922            RecordedSpan_TagsEntry_DoNotUse::Parser< ::google::protobuf::internal::MapFieldLite<
   923                RecordedSpan_TagsEntry_DoNotUse,
   924                ::std::string, ::std::string,
   925                ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
   926                ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
   927                0 >,
   928              ::google::protobuf::Map< ::std::string, ::std::string > > parser(&tags_);
   929            DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
   930                input, &parser));
   931            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   932              parser.key().data(), static_cast<int>(parser.key().length()),
   933              ::google::protobuf::internal::WireFormatLite::PARSE,
   934              "cockroach.util.tracing.RecordedSpan.TagsEntry.key"));
   935            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
   936              parser.value().data(), static_cast<int>(parser.value().length()),
   937              ::google::protobuf::internal::WireFormatLite::PARSE,
   938              "cockroach.util.tracing.RecordedSpan.TagsEntry.value"));
   939          } else {
   940            goto handle_unusual;
   941          }
   942          break;
   943        }
   944  
   945        case 7: {
   946          if (static_cast< ::google::protobuf::uint8>(tag) ==
   947              static_cast< ::google::protobuf::uint8>(58u /* 58 & 0xFF */)) {
   948            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
   949                 input, mutable_start_time()));
   950          } else {
   951            goto handle_unusual;
   952          }
   953          break;
   954        }
   955  
   956        case 8: {
   957          if (static_cast< ::google::protobuf::uint8>(tag) ==
   958              static_cast< ::google::protobuf::uint8>(66u /* 66 & 0xFF */)) {
   959            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
   960                 input, mutable_duration()));
   961          } else {
   962            goto handle_unusual;
   963          }
   964          break;
   965        }
   966  
   967        case 9: {
   968          if (static_cast< ::google::protobuf::uint8>(tag) ==
   969              static_cast< ::google::protobuf::uint8>(74u /* 74 & 0xFF */)) {
   970            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
   971                  input, add_logs()));
   972          } else {
   973            goto handle_unusual;
   974          }
   975          break;
   976        }
   977  
   978        // .google.protobuf.Any stats = 10;
   979        case 10: {
   980          if (static_cast< ::google::protobuf::uint8>(tag) ==
   981              static_cast< ::google::protobuf::uint8>(82u /* 82 & 0xFF */)) {
   982            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
   983                 input, mutable_stats()));
   984          } else {
   985            goto handle_unusual;
   986          }
   987          break;
   988        }
   989  
   990        default: {
   991        handle_unusual:
   992          if (tag == 0) {
   993            goto success;
   994          }
   995          DO_(::google::protobuf::internal::WireFormatLite::SkipField(
   996              input, tag, &unknown_fields_stream));
   997          break;
   998        }
   999      }
  1000    }
  1001  success:
  1002    // @@protoc_insertion_point(parse_success:cockroach.util.tracing.RecordedSpan)
  1003    return true;
  1004  failure:
  1005    // @@protoc_insertion_point(parse_failure:cockroach.util.tracing.RecordedSpan)
  1006    return false;
  1007  #undef DO_
  1008  }
  1009  
  1010  void RecordedSpan::SerializeWithCachedSizes(
  1011      ::google::protobuf::io::CodedOutputStream* output) const {
  1012    // @@protoc_insertion_point(serialize_start:cockroach.util.tracing.RecordedSpan)
  1013    ::google::protobuf::uint32 cached_has_bits = 0;
  1014    (void) cached_has_bits;
  1015  
  1016    if (this->trace_id() != 0) {
  1017      ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->trace_id(), output);
  1018    }
  1019  
  1020    if (this->span_id() != 0) {
  1021      ::google::protobuf::internal::WireFormatLite::WriteUInt64(2, this->span_id(), output);
  1022    }
  1023  
  1024    if (this->parent_span_id() != 0) {
  1025      ::google::protobuf::internal::WireFormatLite::WriteUInt64(3, this->parent_span_id(), output);
  1026    }
  1027  
  1028    // string operation = 4;
  1029    if (this->operation().size() > 0) {
  1030      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1031        this->operation().data(), static_cast<int>(this->operation().length()),
  1032        ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1033        "cockroach.util.tracing.RecordedSpan.operation");
  1034      ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
  1035        4, this->operation(), output);
  1036    }
  1037  
  1038    // map<string, string> baggage = 5;
  1039    if (!this->baggage().empty()) {
  1040      typedef ::google::protobuf::Map< ::std::string, ::std::string >::const_pointer
  1041          ConstPtr;
  1042      typedef ConstPtr SortItem;
  1043      typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  1044      struct Utf8Check {
  1045        static void Check(ConstPtr p) {
  1046          ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1047            p->first.data(), static_cast<int>(p->first.length()),
  1048            ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1049            "cockroach.util.tracing.RecordedSpan.BaggageEntry.key");
  1050          ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1051            p->second.data(), static_cast<int>(p->second.length()),
  1052            ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1053            "cockroach.util.tracing.RecordedSpan.BaggageEntry.value");
  1054        }
  1055      };
  1056  
  1057      if (output->IsSerializationDeterministic() &&
  1058          this->baggage().size() > 1) {
  1059        ::std::unique_ptr<SortItem[]> items(
  1060            new SortItem[this->baggage().size()]);
  1061        typedef ::google::protobuf::Map< ::std::string, ::std::string >::size_type size_type;
  1062        size_type n = 0;
  1063        for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1064            it = this->baggage().begin();
  1065            it != this->baggage().end(); ++it, ++n) {
  1066          items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  1067        }
  1068        ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  1069        ::std::unique_ptr<RecordedSpan_BaggageEntry_DoNotUse> entry;
  1070        for (size_type i = 0; i < n; i++) {
  1071          entry.reset(baggage_.NewEntryWrapper(
  1072              items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  1073          ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1074              5, *entry, output);
  1075          Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  1076        }
  1077      } else {
  1078        ::std::unique_ptr<RecordedSpan_BaggageEntry_DoNotUse> entry;
  1079        for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1080            it = this->baggage().begin();
  1081            it != this->baggage().end(); ++it) {
  1082          entry.reset(baggage_.NewEntryWrapper(
  1083              it->first, it->second));
  1084          ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1085              5, *entry, output);
  1086          Utf8Check::Check(&*it);
  1087        }
  1088      }
  1089    }
  1090  
  1091    // map<string, string> tags = 6;
  1092    if (!this->tags().empty()) {
  1093      typedef ::google::protobuf::Map< ::std::string, ::std::string >::const_pointer
  1094          ConstPtr;
  1095      typedef ConstPtr SortItem;
  1096      typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  1097      struct Utf8Check {
  1098        static void Check(ConstPtr p) {
  1099          ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1100            p->first.data(), static_cast<int>(p->first.length()),
  1101            ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1102            "cockroach.util.tracing.RecordedSpan.TagsEntry.key");
  1103          ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1104            p->second.data(), static_cast<int>(p->second.length()),
  1105            ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1106            "cockroach.util.tracing.RecordedSpan.TagsEntry.value");
  1107        }
  1108      };
  1109  
  1110      if (output->IsSerializationDeterministic() &&
  1111          this->tags().size() > 1) {
  1112        ::std::unique_ptr<SortItem[]> items(
  1113            new SortItem[this->tags().size()]);
  1114        typedef ::google::protobuf::Map< ::std::string, ::std::string >::size_type size_type;
  1115        size_type n = 0;
  1116        for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1117            it = this->tags().begin();
  1118            it != this->tags().end(); ++it, ++n) {
  1119          items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  1120        }
  1121        ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  1122        ::std::unique_ptr<RecordedSpan_TagsEntry_DoNotUse> entry;
  1123        for (size_type i = 0; i < n; i++) {
  1124          entry.reset(tags_.NewEntryWrapper(
  1125              items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  1126          ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1127              6, *entry, output);
  1128          Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  1129        }
  1130      } else {
  1131        ::std::unique_ptr<RecordedSpan_TagsEntry_DoNotUse> entry;
  1132        for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1133            it = this->tags().begin();
  1134            it != this->tags().end(); ++it) {
  1135          entry.reset(tags_.NewEntryWrapper(
  1136              it->first, it->second));
  1137          ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1138              6, *entry, output);
  1139          Utf8Check::Check(&*it);
  1140        }
  1141      }
  1142    }
  1143  
  1144    if (this->has_start_time()) {
  1145      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1146        7, this->_internal_start_time(), output);
  1147    }
  1148  
  1149    if (this->has_duration()) {
  1150      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1151        8, this->_internal_duration(), output);
  1152    }
  1153  
  1154    for (unsigned int i = 0,
  1155        n = static_cast<unsigned int>(this->logs_size()); i < n; i++) {
  1156      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1157        9,
  1158        this->logs(static_cast<int>(i)),
  1159        output);
  1160    }
  1161  
  1162    // .google.protobuf.Any stats = 10;
  1163    if (this->has_stats()) {
  1164      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1165        10, this->_internal_stats(), output);
  1166    }
  1167  
  1168    output->WriteRaw((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).data(),
  1169                     static_cast<int>((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size()));
  1170    // @@protoc_insertion_point(serialize_end:cockroach.util.tracing.RecordedSpan)
  1171  }
  1172  
  1173  size_t RecordedSpan::ByteSizeLong() const {
  1174  // @@protoc_insertion_point(message_byte_size_start:cockroach.util.tracing.RecordedSpan)
  1175    size_t total_size = 0;
  1176  
  1177    total_size += (::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size();
  1178  
  1179    // map<string, string> baggage = 5;
  1180    total_size += 1 *
  1181        ::google::protobuf::internal::FromIntSize(this->baggage_size());
  1182    {
  1183      ::std::unique_ptr<RecordedSpan_BaggageEntry_DoNotUse> entry;
  1184      for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1185          it = this->baggage().begin();
  1186          it != this->baggage().end(); ++it) {
  1187        entry.reset(baggage_.NewEntryWrapper(it->first, it->second));
  1188        total_size += ::google::protobuf::internal::WireFormatLite::
  1189            MessageSizeNoVirtual(*entry);
  1190      }
  1191    }
  1192  
  1193    // map<string, string> tags = 6;
  1194    total_size += 1 *
  1195        ::google::protobuf::internal::FromIntSize(this->tags_size());
  1196    {
  1197      ::std::unique_ptr<RecordedSpan_TagsEntry_DoNotUse> entry;
  1198      for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1199          it = this->tags().begin();
  1200          it != this->tags().end(); ++it) {
  1201        entry.reset(tags_.NewEntryWrapper(it->first, it->second));
  1202        total_size += ::google::protobuf::internal::WireFormatLite::
  1203            MessageSizeNoVirtual(*entry);
  1204      }
  1205    }
  1206  
  1207    {
  1208      unsigned int count = static_cast<unsigned int>(this->logs_size());
  1209      total_size += 1UL * count;
  1210      for (unsigned int i = 0; i < count; i++) {
  1211        total_size +=
  1212          ::google::protobuf::internal::WireFormatLite::MessageSize(
  1213            this->logs(static_cast<int>(i)));
  1214      }
  1215    }
  1216  
  1217    // string operation = 4;
  1218    if (this->operation().size() > 0) {
  1219      total_size += 1 +
  1220        ::google::protobuf::internal::WireFormatLite::StringSize(
  1221          this->operation());
  1222    }
  1223  
  1224    if (this->has_start_time()) {
  1225      total_size += 1 +
  1226        ::google::protobuf::internal::WireFormatLite::MessageSize(
  1227          *start_time_);
  1228    }
  1229  
  1230    if (this->has_duration()) {
  1231      total_size += 1 +
  1232        ::google::protobuf::internal::WireFormatLite::MessageSize(
  1233          *duration_);
  1234    }
  1235  
  1236    // .google.protobuf.Any stats = 10;
  1237    if (this->has_stats()) {
  1238      total_size += 1 +
  1239        ::google::protobuf::internal::WireFormatLite::MessageSize(
  1240          *stats_);
  1241    }
  1242  
  1243    if (this->trace_id() != 0) {
  1244      total_size += 1 +
  1245        ::google::protobuf::internal::WireFormatLite::UInt64Size(
  1246          this->trace_id());
  1247    }
  1248  
  1249    if (this->span_id() != 0) {
  1250      total_size += 1 +
  1251        ::google::protobuf::internal::WireFormatLite::UInt64Size(
  1252          this->span_id());
  1253    }
  1254  
  1255    if (this->parent_span_id() != 0) {
  1256      total_size += 1 +
  1257        ::google::protobuf::internal::WireFormatLite::UInt64Size(
  1258          this->parent_span_id());
  1259    }
  1260  
  1261    int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  1262    SetCachedSize(cached_size);
  1263    return total_size;
  1264  }
  1265  
  1266  void RecordedSpan::CheckTypeAndMergeFrom(
  1267      const ::google::protobuf::MessageLite& from) {
  1268    MergeFrom(*::google::protobuf::down_cast<const RecordedSpan*>(&from));
  1269  }
  1270  
  1271  void RecordedSpan::MergeFrom(const RecordedSpan& from) {
  1272  // @@protoc_insertion_point(class_specific_merge_from_start:cockroach.util.tracing.RecordedSpan)
  1273    GOOGLE_DCHECK_NE(&from, this);
  1274    _internal_metadata_.MergeFrom(from._internal_metadata_);
  1275    ::google::protobuf::uint32 cached_has_bits = 0;
  1276    (void) cached_has_bits;
  1277  
  1278    baggage_.MergeFrom(from.baggage_);
  1279    tags_.MergeFrom(from.tags_);
  1280    logs_.MergeFrom(from.logs_);
  1281    if (from.operation().size() > 0) {
  1282  
  1283      operation_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.operation_);
  1284    }
  1285    if (from.has_start_time()) {
  1286      mutable_start_time()->::google::protobuf::Timestamp::MergeFrom(from.start_time());
  1287    }
  1288    if (from.has_duration()) {
  1289      mutable_duration()->::google::protobuf::Duration::MergeFrom(from.duration());
  1290    }
  1291    if (from.has_stats()) {
  1292      mutable_stats()->::google::protobuf::Any::MergeFrom(from.stats());
  1293    }
  1294    if (from.trace_id() != 0) {
  1295      set_trace_id(from.trace_id());
  1296    }
  1297    if (from.span_id() != 0) {
  1298      set_span_id(from.span_id());
  1299    }
  1300    if (from.parent_span_id() != 0) {
  1301      set_parent_span_id(from.parent_span_id());
  1302    }
  1303  }
  1304  
  1305  void RecordedSpan::CopyFrom(const RecordedSpan& from) {
  1306  // @@protoc_insertion_point(class_specific_copy_from_start:cockroach.util.tracing.RecordedSpan)
  1307    if (&from == this) return;
  1308    Clear();
  1309    MergeFrom(from);
  1310  }
  1311  
  1312  bool RecordedSpan::IsInitialized() const {
  1313    return true;
  1314  }
  1315  
  1316  void RecordedSpan::Swap(RecordedSpan* other) {
  1317    if (other == this) return;
  1318    InternalSwap(other);
  1319  }
  1320  void RecordedSpan::InternalSwap(RecordedSpan* other) {
  1321    using std::swap;
  1322    baggage_.Swap(&other->baggage_);
  1323    tags_.Swap(&other->tags_);
  1324    CastToBase(&logs_)->InternalSwap(CastToBase(&other->logs_));
  1325    operation_.Swap(&other->operation_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
  1326      GetArenaNoVirtual());
  1327    swap(start_time_, other->start_time_);
  1328    swap(duration_, other->duration_);
  1329    swap(stats_, other->stats_);
  1330    swap(trace_id_, other->trace_id_);
  1331    swap(span_id_, other->span_id_);
  1332    swap(parent_span_id_, other->parent_span_id_);
  1333    _internal_metadata_.Swap(&other->_internal_metadata_);
  1334  }
  1335  
  1336  ::std::string RecordedSpan::GetTypeName() const {
  1337    return "cockroach.util.tracing.RecordedSpan";
  1338  }
  1339  
  1340  
  1341  // ===================================================================
  1342  
  1343  NormalizedSpan_TagsEntry_DoNotUse::NormalizedSpan_TagsEntry_DoNotUse() {}
  1344  NormalizedSpan_TagsEntry_DoNotUse::NormalizedSpan_TagsEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {}
  1345  void NormalizedSpan_TagsEntry_DoNotUse::MergeFrom(const NormalizedSpan_TagsEntry_DoNotUse& other) {
  1346    MergeFromInternal(other);
  1347  }
  1348  
  1349  // ===================================================================
  1350  
  1351  void NormalizedSpan::InitAsDefaultInstance() {
  1352    ::cockroach::util::tracing::_NormalizedSpan_default_instance_._instance.get_mutable()->start_time_ = const_cast< ::google::protobuf::Timestamp*>(
  1353        ::google::protobuf::Timestamp::internal_default_instance());
  1354    ::cockroach::util::tracing::_NormalizedSpan_default_instance_._instance.get_mutable()->duration_ = const_cast< ::google::protobuf::Duration*>(
  1355        ::google::protobuf::Duration::internal_default_instance());
  1356  }
  1357  void NormalizedSpan::clear_start_time() {
  1358    if (GetArenaNoVirtual() == NULL && start_time_ != NULL) {
  1359      delete start_time_;
  1360    }
  1361    start_time_ = NULL;
  1362  }
  1363  void NormalizedSpan::clear_duration() {
  1364    if (GetArenaNoVirtual() == NULL && duration_ != NULL) {
  1365      delete duration_;
  1366    }
  1367    duration_ = NULL;
  1368  }
  1369  #if !defined(_MSC_VER) || _MSC_VER >= 1900
  1370  const int NormalizedSpan::kOperationFieldNumber;
  1371  const int NormalizedSpan::kTagsFieldNumber;
  1372  const int NormalizedSpan::kStartTimeFieldNumber;
  1373  const int NormalizedSpan::kDurationFieldNumber;
  1374  const int NormalizedSpan::kLogsFieldNumber;
  1375  const int NormalizedSpan::kChildrenFieldNumber;
  1376  #endif  // !defined(_MSC_VER) || _MSC_VER >= 1900
  1377  
  1378  NormalizedSpan::NormalizedSpan()
  1379    : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  1380    ::google::protobuf::internal::InitSCC(
  1381        &protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_NormalizedSpan.base);
  1382    SharedCtor();
  1383    // @@protoc_insertion_point(constructor:cockroach.util.tracing.NormalizedSpan)
  1384  }
  1385  NormalizedSpan::NormalizedSpan(const NormalizedSpan& from)
  1386    : ::google::protobuf::MessageLite(),
  1387        _internal_metadata_(NULL),
  1388        logs_(from.logs_),
  1389        children_(from.children_) {
  1390    _internal_metadata_.MergeFrom(from._internal_metadata_);
  1391    tags_.MergeFrom(from.tags_);
  1392    operation_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1393    if (from.operation().size() > 0) {
  1394      operation_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.operation_);
  1395    }
  1396    if (from.has_start_time()) {
  1397      start_time_ = new ::google::protobuf::Timestamp(*from.start_time_);
  1398    } else {
  1399      start_time_ = NULL;
  1400    }
  1401    if (from.has_duration()) {
  1402      duration_ = new ::google::protobuf::Duration(*from.duration_);
  1403    } else {
  1404      duration_ = NULL;
  1405    }
  1406    // @@protoc_insertion_point(copy_constructor:cockroach.util.tracing.NormalizedSpan)
  1407  }
  1408  
  1409  void NormalizedSpan::SharedCtor() {
  1410    operation_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1411    ::memset(&start_time_, 0, static_cast<size_t>(
  1412        reinterpret_cast<char*>(&duration_) -
  1413        reinterpret_cast<char*>(&start_time_)) + sizeof(duration_));
  1414  }
  1415  
  1416  NormalizedSpan::~NormalizedSpan() {
  1417    // @@protoc_insertion_point(destructor:cockroach.util.tracing.NormalizedSpan)
  1418    SharedDtor();
  1419  }
  1420  
  1421  void NormalizedSpan::SharedDtor() {
  1422    operation_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1423    if (this != internal_default_instance()) delete start_time_;
  1424    if (this != internal_default_instance()) delete duration_;
  1425  }
  1426  
  1427  void NormalizedSpan::SetCachedSize(int size) const {
  1428    _cached_size_.Set(size);
  1429  }
  1430  const NormalizedSpan& NormalizedSpan::default_instance() {
  1431    ::google::protobuf::internal::InitSCC(&protobuf_util_2ftracing_2frecorded_5fspan_2eproto::scc_info_NormalizedSpan.base);
  1432    return *internal_default_instance();
  1433  }
  1434  
  1435  
  1436  void NormalizedSpan::Clear() {
  1437  // @@protoc_insertion_point(message_clear_start:cockroach.util.tracing.NormalizedSpan)
  1438    ::google::protobuf::uint32 cached_has_bits = 0;
  1439    // Prevent compiler warnings about cached_has_bits being unused
  1440    (void) cached_has_bits;
  1441  
  1442    tags_.Clear();
  1443    logs_.Clear();
  1444    children_.Clear();
  1445    operation_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  1446    if (GetArenaNoVirtual() == NULL && start_time_ != NULL) {
  1447      delete start_time_;
  1448    }
  1449    start_time_ = NULL;
  1450    if (GetArenaNoVirtual() == NULL && duration_ != NULL) {
  1451      delete duration_;
  1452    }
  1453    duration_ = NULL;
  1454    _internal_metadata_.Clear();
  1455  }
  1456  
  1457  bool NormalizedSpan::MergePartialFromCodedStream(
  1458      ::google::protobuf::io::CodedInputStream* input) {
  1459  #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  1460    ::google::protobuf::uint32 tag;
  1461    ::google::protobuf::internal::LiteUnknownFieldSetter unknown_fields_setter(
  1462        &_internal_metadata_);
  1463    ::google::protobuf::io::StringOutputStream unknown_fields_output(
  1464        unknown_fields_setter.buffer());
  1465    ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
  1466        &unknown_fields_output, false);
  1467    // @@protoc_insertion_point(parse_start:cockroach.util.tracing.NormalizedSpan)
  1468    for (;;) {
  1469      ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
  1470      tag = p.first;
  1471      if (!p.second) goto handle_unusual;
  1472      switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
  1473        // string operation = 1;
  1474        case 1: {
  1475          if (static_cast< ::google::protobuf::uint8>(tag) ==
  1476              static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
  1477            DO_(::google::protobuf::internal::WireFormatLite::ReadString(
  1478                  input, this->mutable_operation()));
  1479            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1480              this->operation().data(), static_cast<int>(this->operation().length()),
  1481              ::google::protobuf::internal::WireFormatLite::PARSE,
  1482              "cockroach.util.tracing.NormalizedSpan.operation"));
  1483          } else {
  1484            goto handle_unusual;
  1485          }
  1486          break;
  1487        }
  1488  
  1489        // map<string, string> tags = 2;
  1490        case 2: {
  1491          if (static_cast< ::google::protobuf::uint8>(tag) ==
  1492              static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
  1493            NormalizedSpan_TagsEntry_DoNotUse::Parser< ::google::protobuf::internal::MapFieldLite<
  1494                NormalizedSpan_TagsEntry_DoNotUse,
  1495                ::std::string, ::std::string,
  1496                ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
  1497                ::google::protobuf::internal::WireFormatLite::TYPE_STRING,
  1498                0 >,
  1499              ::google::protobuf::Map< ::std::string, ::std::string > > parser(&tags_);
  1500            DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
  1501                input, &parser));
  1502            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1503              parser.key().data(), static_cast<int>(parser.key().length()),
  1504              ::google::protobuf::internal::WireFormatLite::PARSE,
  1505              "cockroach.util.tracing.NormalizedSpan.TagsEntry.key"));
  1506            DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1507              parser.value().data(), static_cast<int>(parser.value().length()),
  1508              ::google::protobuf::internal::WireFormatLite::PARSE,
  1509              "cockroach.util.tracing.NormalizedSpan.TagsEntry.value"));
  1510          } else {
  1511            goto handle_unusual;
  1512          }
  1513          break;
  1514        }
  1515  
  1516        case 3: {
  1517          if (static_cast< ::google::protobuf::uint8>(tag) ==
  1518              static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
  1519            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  1520                 input, mutable_start_time()));
  1521          } else {
  1522            goto handle_unusual;
  1523          }
  1524          break;
  1525        }
  1526  
  1527        case 4: {
  1528          if (static_cast< ::google::protobuf::uint8>(tag) ==
  1529              static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
  1530            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  1531                 input, mutable_duration()));
  1532          } else {
  1533            goto handle_unusual;
  1534          }
  1535          break;
  1536        }
  1537  
  1538        case 5: {
  1539          if (static_cast< ::google::protobuf::uint8>(tag) ==
  1540              static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
  1541            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  1542                  input, add_logs()));
  1543          } else {
  1544            goto handle_unusual;
  1545          }
  1546          break;
  1547        }
  1548  
  1549        case 6: {
  1550          if (static_cast< ::google::protobuf::uint8>(tag) ==
  1551              static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
  1552            DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
  1553                  input, add_children()));
  1554          } else {
  1555            goto handle_unusual;
  1556          }
  1557          break;
  1558        }
  1559  
  1560        default: {
  1561        handle_unusual:
  1562          if (tag == 0) {
  1563            goto success;
  1564          }
  1565          DO_(::google::protobuf::internal::WireFormatLite::SkipField(
  1566              input, tag, &unknown_fields_stream));
  1567          break;
  1568        }
  1569      }
  1570    }
  1571  success:
  1572    // @@protoc_insertion_point(parse_success:cockroach.util.tracing.NormalizedSpan)
  1573    return true;
  1574  failure:
  1575    // @@protoc_insertion_point(parse_failure:cockroach.util.tracing.NormalizedSpan)
  1576    return false;
  1577  #undef DO_
  1578  }
  1579  
  1580  void NormalizedSpan::SerializeWithCachedSizes(
  1581      ::google::protobuf::io::CodedOutputStream* output) const {
  1582    // @@protoc_insertion_point(serialize_start:cockroach.util.tracing.NormalizedSpan)
  1583    ::google::protobuf::uint32 cached_has_bits = 0;
  1584    (void) cached_has_bits;
  1585  
  1586    // string operation = 1;
  1587    if (this->operation().size() > 0) {
  1588      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1589        this->operation().data(), static_cast<int>(this->operation().length()),
  1590        ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1591        "cockroach.util.tracing.NormalizedSpan.operation");
  1592      ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
  1593        1, this->operation(), output);
  1594    }
  1595  
  1596    // map<string, string> tags = 2;
  1597    if (!this->tags().empty()) {
  1598      typedef ::google::protobuf::Map< ::std::string, ::std::string >::const_pointer
  1599          ConstPtr;
  1600      typedef ConstPtr SortItem;
  1601      typedef ::google::protobuf::internal::CompareByDerefFirst<SortItem> Less;
  1602      struct Utf8Check {
  1603        static void Check(ConstPtr p) {
  1604          ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1605            p->first.data(), static_cast<int>(p->first.length()),
  1606            ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1607            "cockroach.util.tracing.NormalizedSpan.TagsEntry.key");
  1608          ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
  1609            p->second.data(), static_cast<int>(p->second.length()),
  1610            ::google::protobuf::internal::WireFormatLite::SERIALIZE,
  1611            "cockroach.util.tracing.NormalizedSpan.TagsEntry.value");
  1612        }
  1613      };
  1614  
  1615      if (output->IsSerializationDeterministic() &&
  1616          this->tags().size() > 1) {
  1617        ::std::unique_ptr<SortItem[]> items(
  1618            new SortItem[this->tags().size()]);
  1619        typedef ::google::protobuf::Map< ::std::string, ::std::string >::size_type size_type;
  1620        size_type n = 0;
  1621        for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1622            it = this->tags().begin();
  1623            it != this->tags().end(); ++it, ++n) {
  1624          items[static_cast<ptrdiff_t>(n)] = SortItem(&*it);
  1625        }
  1626        ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less());
  1627        ::std::unique_ptr<NormalizedSpan_TagsEntry_DoNotUse> entry;
  1628        for (size_type i = 0; i < n; i++) {
  1629          entry.reset(tags_.NewEntryWrapper(
  1630              items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second));
  1631          ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1632              2, *entry, output);
  1633          Utf8Check::Check(items[static_cast<ptrdiff_t>(i)]);
  1634        }
  1635      } else {
  1636        ::std::unique_ptr<NormalizedSpan_TagsEntry_DoNotUse> entry;
  1637        for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1638            it = this->tags().begin();
  1639            it != this->tags().end(); ++it) {
  1640          entry.reset(tags_.NewEntryWrapper(
  1641              it->first, it->second));
  1642          ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1643              2, *entry, output);
  1644          Utf8Check::Check(&*it);
  1645        }
  1646      }
  1647    }
  1648  
  1649    if (this->has_start_time()) {
  1650      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1651        3, this->_internal_start_time(), output);
  1652    }
  1653  
  1654    if (this->has_duration()) {
  1655      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1656        4, this->_internal_duration(), output);
  1657    }
  1658  
  1659    for (unsigned int i = 0,
  1660        n = static_cast<unsigned int>(this->logs_size()); i < n; i++) {
  1661      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1662        5,
  1663        this->logs(static_cast<int>(i)),
  1664        output);
  1665    }
  1666  
  1667    for (unsigned int i = 0,
  1668        n = static_cast<unsigned int>(this->children_size()); i < n; i++) {
  1669      ::google::protobuf::internal::WireFormatLite::WriteMessage(
  1670        6,
  1671        this->children(static_cast<int>(i)),
  1672        output);
  1673    }
  1674  
  1675    output->WriteRaw((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).data(),
  1676                     static_cast<int>((::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size()));
  1677    // @@protoc_insertion_point(serialize_end:cockroach.util.tracing.NormalizedSpan)
  1678  }
  1679  
  1680  size_t NormalizedSpan::ByteSizeLong() const {
  1681  // @@protoc_insertion_point(message_byte_size_start:cockroach.util.tracing.NormalizedSpan)
  1682    size_t total_size = 0;
  1683  
  1684    total_size += (::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()).size();
  1685  
  1686    // map<string, string> tags = 2;
  1687    total_size += 1 *
  1688        ::google::protobuf::internal::FromIntSize(this->tags_size());
  1689    {
  1690      ::std::unique_ptr<NormalizedSpan_TagsEntry_DoNotUse> entry;
  1691      for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator
  1692          it = this->tags().begin();
  1693          it != this->tags().end(); ++it) {
  1694        entry.reset(tags_.NewEntryWrapper(it->first, it->second));
  1695        total_size += ::google::protobuf::internal::WireFormatLite::
  1696            MessageSizeNoVirtual(*entry);
  1697      }
  1698    }
  1699  
  1700    {
  1701      unsigned int count = static_cast<unsigned int>(this->logs_size());
  1702      total_size += 1UL * count;
  1703      for (unsigned int i = 0; i < count; i++) {
  1704        total_size +=
  1705          ::google::protobuf::internal::WireFormatLite::MessageSize(
  1706            this->logs(static_cast<int>(i)));
  1707      }
  1708    }
  1709  
  1710    {
  1711      unsigned int count = static_cast<unsigned int>(this->children_size());
  1712      total_size += 1UL * count;
  1713      for (unsigned int i = 0; i < count; i++) {
  1714        total_size +=
  1715          ::google::protobuf::internal::WireFormatLite::MessageSize(
  1716            this->children(static_cast<int>(i)));
  1717      }
  1718    }
  1719  
  1720    // string operation = 1;
  1721    if (this->operation().size() > 0) {
  1722      total_size += 1 +
  1723        ::google::protobuf::internal::WireFormatLite::StringSize(
  1724          this->operation());
  1725    }
  1726  
  1727    if (this->has_start_time()) {
  1728      total_size += 1 +
  1729        ::google::protobuf::internal::WireFormatLite::MessageSize(
  1730          *start_time_);
  1731    }
  1732  
  1733    if (this->has_duration()) {
  1734      total_size += 1 +
  1735        ::google::protobuf::internal::WireFormatLite::MessageSize(
  1736          *duration_);
  1737    }
  1738  
  1739    int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  1740    SetCachedSize(cached_size);
  1741    return total_size;
  1742  }
  1743  
  1744  void NormalizedSpan::CheckTypeAndMergeFrom(
  1745      const ::google::protobuf::MessageLite& from) {
  1746    MergeFrom(*::google::protobuf::down_cast<const NormalizedSpan*>(&from));
  1747  }
  1748  
  1749  void NormalizedSpan::MergeFrom(const NormalizedSpan& from) {
  1750  // @@protoc_insertion_point(class_specific_merge_from_start:cockroach.util.tracing.NormalizedSpan)
  1751    GOOGLE_DCHECK_NE(&from, this);
  1752    _internal_metadata_.MergeFrom(from._internal_metadata_);
  1753    ::google::protobuf::uint32 cached_has_bits = 0;
  1754    (void) cached_has_bits;
  1755  
  1756    tags_.MergeFrom(from.tags_);
  1757    logs_.MergeFrom(from.logs_);
  1758    children_.MergeFrom(from.children_);
  1759    if (from.operation().size() > 0) {
  1760  
  1761      operation_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.operation_);
  1762    }
  1763    if (from.has_start_time()) {
  1764      mutable_start_time()->::google::protobuf::Timestamp::MergeFrom(from.start_time());
  1765    }
  1766    if (from.has_duration()) {
  1767      mutable_duration()->::google::protobuf::Duration::MergeFrom(from.duration());
  1768    }
  1769  }
  1770  
  1771  void NormalizedSpan::CopyFrom(const NormalizedSpan& from) {
  1772  // @@protoc_insertion_point(class_specific_copy_from_start:cockroach.util.tracing.NormalizedSpan)
  1773    if (&from == this) return;
  1774    Clear();
  1775    MergeFrom(from);
  1776  }
  1777  
  1778  bool NormalizedSpan::IsInitialized() const {
  1779    return true;
  1780  }
  1781  
  1782  void NormalizedSpan::Swap(NormalizedSpan* other) {
  1783    if (other == this) return;
  1784    InternalSwap(other);
  1785  }
  1786  void NormalizedSpan::InternalSwap(NormalizedSpan* other) {
  1787    using std::swap;
  1788    tags_.Swap(&other->tags_);
  1789    CastToBase(&logs_)->InternalSwap(CastToBase(&other->logs_));
  1790    CastToBase(&children_)->InternalSwap(CastToBase(&other->children_));
  1791    operation_.Swap(&other->operation_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
  1792      GetArenaNoVirtual());
  1793    swap(start_time_, other->start_time_);
  1794    swap(duration_, other->duration_);
  1795    _internal_metadata_.Swap(&other->_internal_metadata_);
  1796  }
  1797  
  1798  ::std::string NormalizedSpan::GetTypeName() const {
  1799    return "cockroach.util.tracing.NormalizedSpan";
  1800  }
  1801  
  1802  
  1803  // @@protoc_insertion_point(namespace_scope)
  1804  }  // namespace tracing
  1805  }  // namespace util
  1806  }  // namespace cockroach
  1807  namespace google {
  1808  namespace protobuf {
  1809  template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::util::tracing::LogRecord_Field* Arena::CreateMaybeMessage< ::cockroach::util::tracing::LogRecord_Field >(Arena* arena) {
  1810    return Arena::CreateInternal< ::cockroach::util::tracing::LogRecord_Field >(arena);
  1811  }
  1812  template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::util::tracing::LogRecord* Arena::CreateMaybeMessage< ::cockroach::util::tracing::LogRecord >(Arena* arena) {
  1813    return Arena::CreateInternal< ::cockroach::util::tracing::LogRecord >(arena);
  1814  }
  1815  template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::util::tracing::RecordedSpan_BaggageEntry_DoNotUse* Arena::CreateMaybeMessage< ::cockroach::util::tracing::RecordedSpan_BaggageEntry_DoNotUse >(Arena* arena) {
  1816    return Arena::CreateInternal< ::cockroach::util::tracing::RecordedSpan_BaggageEntry_DoNotUse >(arena);
  1817  }
  1818  template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::util::tracing::RecordedSpan_TagsEntry_DoNotUse* Arena::CreateMaybeMessage< ::cockroach::util::tracing::RecordedSpan_TagsEntry_DoNotUse >(Arena* arena) {
  1819    return Arena::CreateInternal< ::cockroach::util::tracing::RecordedSpan_TagsEntry_DoNotUse >(arena);
  1820  }
  1821  template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::util::tracing::RecordedSpan* Arena::CreateMaybeMessage< ::cockroach::util::tracing::RecordedSpan >(Arena* arena) {
  1822    return Arena::CreateInternal< ::cockroach::util::tracing::RecordedSpan >(arena);
  1823  }
  1824  template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::util::tracing::NormalizedSpan_TagsEntry_DoNotUse* Arena::CreateMaybeMessage< ::cockroach::util::tracing::NormalizedSpan_TagsEntry_DoNotUse >(Arena* arena) {
  1825    return Arena::CreateInternal< ::cockroach::util::tracing::NormalizedSpan_TagsEntry_DoNotUse >(arena);
  1826  }
  1827  template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::cockroach::util::tracing::NormalizedSpan* Arena::CreateMaybeMessage< ::cockroach::util::tracing::NormalizedSpan >(Arena* arena) {
  1828    return Arena::CreateInternal< ::cockroach::util::tracing::NormalizedSpan >(arena);
  1829  }
  1830  }  // namespace protobuf
  1831  }  // namespace google
  1832  
  1833  // @@protoc_insertion_point(global_scope)