diff --git a/c++/greptime/v1/common.pb.cc b/c++/greptime/v1/common.pb.cc index bfe153a5..3dcbcd9a 100644 --- a/c++/greptime/v1/common.pb.cc +++ b/c++/greptime/v1/common.pb.cc @@ -272,19 +272,6 @@ struct DecimalTypeExtensionDefaultTypeInternal { }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 DecimalTypeExtensionDefaultTypeInternal _DecimalTypeExtension_default_instance_; -PROTOBUF_CONSTEXPR JsonTypeExtension::JsonTypeExtension( - ::_pbi::ConstantInitialized): _impl_{ - /*decltype(_impl_.is_json_)*/false - , /*decltype(_impl_._cached_size_)*/{}} {} -struct JsonTypeExtensionDefaultTypeInternal { - PROTOBUF_CONSTEXPR JsonTypeExtensionDefaultTypeInternal() - : _instance(::_pbi::ConstantInitialized{}) {} - ~JsonTypeExtensionDefaultTypeInternal() {} - union { - JsonTypeExtension _instance; - }; -}; -PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 JsonTypeExtensionDefaultTypeInternal _JsonTypeExtension_default_instance_; PROTOBUF_CONSTEXPR ColumnOptions_OptionsEntry_DoNotUse::ColumnOptions_OptionsEntry_DoNotUse( ::_pbi::ConstantInitialized) {} struct ColumnOptions_OptionsEntry_DoNotUseDefaultTypeInternal { @@ -311,8 +298,8 @@ struct ColumnOptionsDefaultTypeInternal { PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ColumnOptionsDefaultTypeInternal _ColumnOptions_default_instance_; } // namespace v1 } // namespace greptime -static ::_pb::Metadata file_level_metadata_greptime_2fv1_2fcommon_2eproto[21]; -static const ::_pb::EnumDescriptor* file_level_enum_descriptors_greptime_2fv1_2fcommon_2eproto[2]; +static ::_pb::Metadata file_level_metadata_greptime_2fv1_2fcommon_2eproto[20]; +static const ::_pb::EnumDescriptor* file_level_enum_descriptors_greptime_2fv1_2fcommon_2eproto[3]; static constexpr ::_pb::ServiceDescriptor const** file_level_service_descriptors_greptime_2fv1_2fcommon_2eproto = nullptr; const uint32_t TableStruct_greptime_2fv1_2fcommon_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { @@ -470,13 +457,6 @@ const uint32_t TableStruct_greptime_2fv1_2fcommon_2eproto::offsets[] PROTOBUF_SE ~0u, // no _inlined_string_donated_ PROTOBUF_FIELD_OFFSET(::greptime::v1::DecimalTypeExtension, _impl_.precision_), PROTOBUF_FIELD_OFFSET(::greptime::v1::DecimalTypeExtension, _impl_.scale_), - ~0u, // no _has_bits_ - PROTOBUF_FIELD_OFFSET(::greptime::v1::JsonTypeExtension, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - ~0u, // no _inlined_string_donated_ - PROTOBUF_FIELD_OFFSET(::greptime::v1::JsonTypeExtension, _impl_.is_json_), PROTOBUF_FIELD_OFFSET(::greptime::v1::ColumnOptions_OptionsEntry_DoNotUse, _has_bits_), PROTOBUF_FIELD_OFFSET(::greptime::v1::ColumnOptions_OptionsEntry_DoNotUse, _internal_metadata_), ~0u, // no _extensions_ @@ -514,9 +494,8 @@ static const ::_pbi::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protode { 129, -1, -1, sizeof(::greptime::v1::Decimal128)}, { 137, -1, -1, sizeof(::greptime::v1::ColumnDataTypeExtension)}, { 146, -1, -1, sizeof(::greptime::v1::DecimalTypeExtension)}, - { 154, -1, -1, sizeof(::greptime::v1::JsonTypeExtension)}, - { 161, 169, -1, sizeof(::greptime::v1::ColumnOptions_OptionsEntry_DoNotUse)}, - { 171, -1, -1, sizeof(::greptime::v1::ColumnOptions)}, + { 154, 162, -1, sizeof(::greptime::v1::ColumnOptions_OptionsEntry_DoNotUse)}, + { 164, -1, -1, sizeof(::greptime::v1::ColumnOptions)}, }; static const ::_pb::Message* const file_default_instances[] = { @@ -538,7 +517,6 @@ static const ::_pb::Message* const file_default_instances[] = { &::greptime::v1::_Decimal128_default_instance_._instance, &::greptime::v1::_ColumnDataTypeExtension_default_instance_._instance, &::greptime::v1::_DecimalTypeExtension_default_instance_._instance, - &::greptime::v1::_JsonTypeExtension_default_instance_._instance, &::greptime::v1::_ColumnOptions_OptionsEntry_DoNotUse_default_instance_._instance, &::greptime::v1::_ColumnOptions_default_instance_._instance, }; @@ -576,26 +554,26 @@ const char descriptor_table_protodef_greptime_2fv1_2fcommon_2eproto[] PROTOBUF_S "\001(\003\022\n\n\002lo\030\002 \001(\003\"\225\001\n\027ColumnDataTypeExtens" "ion\0229\n\014decimal_type\030\001 \001(\0132!.greptime.v1." "DecimalTypeExtensionH\000\0223\n\tjson_type\030\002 \001(" - "\0132\036.greptime.v1.JsonTypeExtensionH\000B\n\n\010t" + "\0162\036.greptime.v1.JsonTypeExtensionH\000B\n\n\010t" "ype_ext\"8\n\024DecimalTypeExtension\022\021\n\tpreci" - "sion\030\001 \001(\005\022\r\n\005scale\030\002 \001(\005\"$\n\021JsonTypeExt" - "ension\022\017\n\007is_json\030\001 \001(\010\"y\n\rColumnOptions" - "\0228\n\007options\030\001 \003(\0132\'.greptime.v1.ColumnOp" - "tions.OptionsEntry\032.\n\014OptionsEntry\022\013\n\003ke" - "y\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001*1\n\014SemanticTy" - "pe\022\007\n\003TAG\020\000\022\t\n\005FIELD\020\001\022\r\n\tTIMESTAMP\020\002*\326\003" - "\n\016ColumnDataType\022\013\n\007BOOLEAN\020\000\022\010\n\004INT8\020\001\022" - "\t\n\005INT16\020\002\022\t\n\005INT32\020\003\022\t\n\005INT64\020\004\022\t\n\005UINT" - "8\020\005\022\n\n\006UINT16\020\006\022\n\n\006UINT32\020\007\022\n\n\006UINT64\020\010\022" - "\013\n\007FLOAT32\020\t\022\013\n\007FLOAT64\020\n\022\n\n\006BINARY\020\013\022\n\n" - "\006STRING\020\014\022\010\n\004DATE\020\r\022\014\n\010DATETIME\020\016\022\024\n\020TIM" - "ESTAMP_SECOND\020\017\022\031\n\025TIMESTAMP_MILLISECOND" - "\020\020\022\031\n\025TIMESTAMP_MICROSECOND\020\021\022\030\n\024TIMESTA" - "MP_NANOSECOND\020\022\022\017\n\013TIME_SECOND\020\023\022\024\n\020TIME" - "_MILLISECOND\020\024\022\024\n\020TIME_MICROSECOND\020\025\022\023\n\017" - "TIME_NANOSECOND\020\026\022\027\n\023INTERVAL_YEAR_MONTH" - "\020\027\022\025\n\021INTERVAL_DAY_TIME\020\030\022\033\n\027INTERVAL_MO" - "NTH_DAY_NANO\020\031\022\016\n\nDECIMAL128\020\036BO\n\016io.gre" + "sion\030\001 \001(\005\022\r\n\005scale\030\002 \001(\005\"y\n\rColumnOptio" + "ns\0228\n\007options\030\001 \003(\0132\'.greptime.v1.Column" + "Options.OptionsEntry\032.\n\014OptionsEntry\022\013\n\003" + "key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001*1\n\014Semantic" + "Type\022\007\n\003TAG\020\000\022\t\n\005FIELD\020\001\022\r\n\tTIMESTAMP\020\002*" + "\326\003\n\016ColumnDataType\022\013\n\007BOOLEAN\020\000\022\010\n\004INT8\020" + "\001\022\t\n\005INT16\020\002\022\t\n\005INT32\020\003\022\t\n\005INT64\020\004\022\t\n\005UI" + "NT8\020\005\022\n\n\006UINT16\020\006\022\n\n\006UINT32\020\007\022\n\n\006UINT64\020" + "\010\022\013\n\007FLOAT32\020\t\022\013\n\007FLOAT64\020\n\022\n\n\006BINARY\020\013\022" + "\n\n\006STRING\020\014\022\010\n\004DATE\020\r\022\014\n\010DATETIME\020\016\022\024\n\020T" + "IMESTAMP_SECOND\020\017\022\031\n\025TIMESTAMP_MILLISECO" + "ND\020\020\022\031\n\025TIMESTAMP_MICROSECOND\020\021\022\030\n\024TIMES" + "TAMP_NANOSECOND\020\022\022\017\n\013TIME_SECOND\020\023\022\024\n\020TI" + "ME_MILLISECOND\020\024\022\024\n\020TIME_MICROSECOND\020\025\022\023" + "\n\017TIME_NANOSECOND\020\026\022\027\n\023INTERVAL_YEAR_MON" + "TH\020\027\022\025\n\021INTERVAL_DAY_TIME\020\030\022\033\n\027INTERVAL_" + "MONTH_DAY_NANO\020\031\022\016\n\nDECIMAL128\020\036*$\n\021Json" + "TypeExtension\022\017\n\013JSON_BINARY\020\000BO\n\016io.gre" "ptime.v1B\006CommonZ5github.com/GreptimeTea" "m/greptime-proto/go/greptime/v1b\006proto3" ; @@ -603,7 +581,7 @@ static ::_pbi::once_flag descriptor_table_greptime_2fv1_2fcommon_2eproto_once; const ::_pbi::DescriptorTable descriptor_table_greptime_2fv1_2fcommon_2eproto = { false, false, 2159, descriptor_table_protodef_greptime_2fv1_2fcommon_2eproto, "greptime/v1/common.proto", - &descriptor_table_greptime_2fv1_2fcommon_2eproto_once, nullptr, 0, 21, + &descriptor_table_greptime_2fv1_2fcommon_2eproto_once, nullptr, 0, 20, schemas, file_default_instances, TableStruct_greptime_2fv1_2fcommon_2eproto::offsets, file_level_metadata_greptime_2fv1_2fcommon_2eproto, file_level_enum_descriptors_greptime_2fv1_2fcommon_2eproto, file_level_service_descriptors_greptime_2fv1_2fcommon_2eproto, @@ -670,6 +648,19 @@ bool ColumnDataType_IsValid(int value) { } } +const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* JsonTypeExtension_descriptor() { + ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_greptime_2fv1_2fcommon_2eproto); + return file_level_enum_descriptors_greptime_2fv1_2fcommon_2eproto[2]; +} +bool JsonTypeExtension_IsValid(int value) { + switch (value) { + case 0: + return true; + default: + return false; + } +} + // =================================================================== @@ -4291,17 +4282,12 @@ ::PROTOBUF_NAMESPACE_ID::Metadata Decimal128::GetMetadata() const { class ColumnDataTypeExtension::_Internal { public: static const ::greptime::v1::DecimalTypeExtension& decimal_type(const ColumnDataTypeExtension* msg); - static const ::greptime::v1::JsonTypeExtension& json_type(const ColumnDataTypeExtension* msg); }; const ::greptime::v1::DecimalTypeExtension& ColumnDataTypeExtension::_Internal::decimal_type(const ColumnDataTypeExtension* msg) { return *msg->_impl_.type_ext_.decimal_type_; } -const ::greptime::v1::JsonTypeExtension& -ColumnDataTypeExtension::_Internal::json_type(const ColumnDataTypeExtension* msg) { - return *msg->_impl_.type_ext_.json_type_; -} void ColumnDataTypeExtension::set_allocated_decimal_type(::greptime::v1::DecimalTypeExtension* decimal_type) { ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); clear_type_ext(); @@ -4317,21 +4303,6 @@ void ColumnDataTypeExtension::set_allocated_decimal_type(::greptime::v1::Decimal } // @@protoc_insertion_point(field_set_allocated:greptime.v1.ColumnDataTypeExtension.decimal_type) } -void ColumnDataTypeExtension::set_allocated_json_type(::greptime::v1::JsonTypeExtension* json_type) { - ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); - clear_type_ext(); - if (json_type) { - ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = - ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(json_type); - if (message_arena != submessage_arena) { - json_type = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage( - message_arena, json_type, submessage_arena); - } - set_has_json_type(); - _impl_.type_ext_.json_type_ = json_type; - } - // @@protoc_insertion_point(field_set_allocated:greptime.v1.ColumnDataTypeExtension.json_type) -} ColumnDataTypeExtension::ColumnDataTypeExtension(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned) : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) { @@ -4355,8 +4326,7 @@ ColumnDataTypeExtension::ColumnDataTypeExtension(const ColumnDataTypeExtension& break; } case kJsonType: { - _this->_internal_mutable_json_type()->::greptime::v1::JsonTypeExtension::MergeFrom( - from._internal_json_type()); + _this->_internal_set_json_type(from._internal_json_type()); break; } case TYPE_EXT_NOT_SET: { @@ -4408,9 +4378,7 @@ void ColumnDataTypeExtension::clear_type_ext() { break; } case kJsonType: { - if (GetArenaForAllocation() == nullptr) { - delete _impl_.type_ext_.json_type_; - } + // No need to clear break; } case TYPE_EXT_NOT_SET: { @@ -4447,9 +4415,10 @@ const char* ColumnDataTypeExtension::_InternalParse(const char* ptr, ::_pbi::Par continue; // .greptime.v1.JsonTypeExtension json_type = 2; case 2: - if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 18)) { - ptr = ctx->ParseMessage(_internal_mutable_json_type(), ptr); + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 16)) { + uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); CHK_(ptr); + _internal_set_json_type(static_cast<::greptime::v1::JsonTypeExtension>(val)); } else goto handle_unusual; continue; @@ -4491,9 +4460,9 @@ uint8_t* ColumnDataTypeExtension::_InternalSerialize( // .greptime.v1.JsonTypeExtension json_type = 2; if (_internal_has_json_type()) { - target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: - InternalWriteMessage(2, _Internal::json_type(this), - _Internal::json_type(this).GetCachedSize(), target, stream); + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::WriteEnumToArray( + 2, this->_internal_json_type(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { @@ -4523,8 +4492,7 @@ size_t ColumnDataTypeExtension::ByteSizeLong() const { // .greptime.v1.JsonTypeExtension json_type = 2; case kJsonType: { total_size += 1 + - ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize( - *_impl_.type_ext_.json_type_); + ::_pbi::WireFormatLite::EnumSize(this->_internal_json_type()); break; } case TYPE_EXT_NOT_SET: { @@ -4556,8 +4524,7 @@ void ColumnDataTypeExtension::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg break; } case kJsonType: { - _this->_internal_mutable_json_type()->::greptime::v1::JsonTypeExtension::MergeFrom( - from._internal_json_type()); + _this->_internal_set_json_type(from._internal_json_type()); break; } case TYPE_EXT_NOT_SET: { @@ -4804,184 +4771,6 @@ ::PROTOBUF_NAMESPACE_ID::Metadata DecimalTypeExtension::GetMetadata() const { // =================================================================== -class JsonTypeExtension::_Internal { - public: -}; - -JsonTypeExtension::JsonTypeExtension(::PROTOBUF_NAMESPACE_ID::Arena* arena, - bool is_message_owned) - : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) { - SharedCtor(arena, is_message_owned); - // @@protoc_insertion_point(arena_constructor:greptime.v1.JsonTypeExtension) -} -JsonTypeExtension::JsonTypeExtension(const JsonTypeExtension& from) - : ::PROTOBUF_NAMESPACE_ID::Message() { - JsonTypeExtension* const _this = this; (void)_this; - new (&_impl_) Impl_{ - decltype(_impl_.is_json_){} - , /*decltype(_impl_._cached_size_)*/{}}; - - _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); - _this->_impl_.is_json_ = from._impl_.is_json_; - // @@protoc_insertion_point(copy_constructor:greptime.v1.JsonTypeExtension) -} - -inline void JsonTypeExtension::SharedCtor( - ::_pb::Arena* arena, bool is_message_owned) { - (void)arena; - (void)is_message_owned; - new (&_impl_) Impl_{ - decltype(_impl_.is_json_){false} - , /*decltype(_impl_._cached_size_)*/{} - }; -} - -JsonTypeExtension::~JsonTypeExtension() { - // @@protoc_insertion_point(destructor:greptime.v1.JsonTypeExtension) - if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) { - (void)arena; - return; - } - SharedDtor(); -} - -inline void JsonTypeExtension::SharedDtor() { - GOOGLE_DCHECK(GetArenaForAllocation() == nullptr); -} - -void JsonTypeExtension::SetCachedSize(int size) const { - _impl_._cached_size_.Set(size); -} - -void JsonTypeExtension::Clear() { -// @@protoc_insertion_point(message_clear_start:greptime.v1.JsonTypeExtension) - uint32_t cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - _impl_.is_json_ = false; - _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); -} - -const char* JsonTypeExtension::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) { -#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure - while (!ctx->Done(&ptr)) { - uint32_t tag; - ptr = ::_pbi::ReadTag(ptr, &tag); - switch (tag >> 3) { - // bool is_json = 1; - case 1: - if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 8)) { - _impl_.is_json_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr); - CHK_(ptr); - } else - goto handle_unusual; - continue; - default: - goto handle_unusual; - } // switch - handle_unusual: - if ((tag == 0) || ((tag & 7) == 4)) { - CHK_(ptr); - ctx->SetLastTag(tag); - goto message_done; - } - ptr = UnknownFieldParse( - tag, - _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), - ptr, ctx); - CHK_(ptr != nullptr); - } // while -message_done: - return ptr; -failure: - ptr = nullptr; - goto message_done; -#undef CHK_ -} - -uint8_t* JsonTypeExtension::_InternalSerialize( - uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { - // @@protoc_insertion_point(serialize_to_array_start:greptime.v1.JsonTypeExtension) - uint32_t cached_has_bits = 0; - (void) cached_has_bits; - - // bool is_json = 1; - if (this->_internal_is_json() != 0) { - target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(1, this->_internal_is_json(), target); - } - - if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { - target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( - _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); - } - // @@protoc_insertion_point(serialize_to_array_end:greptime.v1.JsonTypeExtension) - return target; -} - -size_t JsonTypeExtension::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:greptime.v1.JsonTypeExtension) - size_t total_size = 0; - - uint32_t cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - // bool is_json = 1; - if (this->_internal_is_json() != 0) { - total_size += 1 + 1; - } - - return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); -} - -const ::PROTOBUF_NAMESPACE_ID::Message::ClassData JsonTypeExtension::_class_data_ = { - ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, - JsonTypeExtension::MergeImpl -}; -const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*JsonTypeExtension::GetClassData() const { return &_class_data_; } - - -void JsonTypeExtension::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) { - auto* const _this = static_cast(&to_msg); - auto& from = static_cast(from_msg); - // @@protoc_insertion_point(class_specific_merge_from_start:greptime.v1.JsonTypeExtension) - GOOGLE_DCHECK_NE(&from, _this); - uint32_t cached_has_bits = 0; - (void) cached_has_bits; - - if (from._internal_is_json() != 0) { - _this->_internal_set_is_json(from._internal_is_json()); - } - _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); -} - -void JsonTypeExtension::CopyFrom(const JsonTypeExtension& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:greptime.v1.JsonTypeExtension) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool JsonTypeExtension::IsInitialized() const { - return true; -} - -void JsonTypeExtension::InternalSwap(JsonTypeExtension* other) { - using std::swap; - _internal_metadata_.InternalSwap(&other->_internal_metadata_); - swap(_impl_.is_json_, other->_impl_.is_json_); -} - -::PROTOBUF_NAMESPACE_ID::Metadata JsonTypeExtension::GetMetadata() const { - return ::_pbi::AssignDescriptors( - &descriptor_table_greptime_2fv1_2fcommon_2eproto_getter, &descriptor_table_greptime_2fv1_2fcommon_2eproto_once, - file_level_metadata_greptime_2fv1_2fcommon_2eproto[18]); -} - -// =================================================================== - ColumnOptions_OptionsEntry_DoNotUse::ColumnOptions_OptionsEntry_DoNotUse() {} ColumnOptions_OptionsEntry_DoNotUse::ColumnOptions_OptionsEntry_DoNotUse(::PROTOBUF_NAMESPACE_ID::Arena* arena) : SuperType(arena) {} @@ -4991,7 +4780,7 @@ void ColumnOptions_OptionsEntry_DoNotUse::MergeFrom(const ColumnOptions_OptionsE ::PROTOBUF_NAMESPACE_ID::Metadata ColumnOptions_OptionsEntry_DoNotUse::GetMetadata() const { return ::_pbi::AssignDescriptors( &descriptor_table_greptime_2fv1_2fcommon_2eproto_getter, &descriptor_table_greptime_2fv1_2fcommon_2eproto_once, - file_level_metadata_greptime_2fv1_2fcommon_2eproto[19]); + file_level_metadata_greptime_2fv1_2fcommon_2eproto[18]); } // =================================================================== @@ -5210,7 +4999,7 @@ void ColumnOptions::InternalSwap(ColumnOptions* other) { ::PROTOBUF_NAMESPACE_ID::Metadata ColumnOptions::GetMetadata() const { return ::_pbi::AssignDescriptors( &descriptor_table_greptime_2fv1_2fcommon_2eproto_getter, &descriptor_table_greptime_2fv1_2fcommon_2eproto_once, - file_level_metadata_greptime_2fv1_2fcommon_2eproto[20]); + file_level_metadata_greptime_2fv1_2fcommon_2eproto[19]); } // @@protoc_insertion_point(namespace_scope) @@ -5289,10 +5078,6 @@ template<> PROTOBUF_NOINLINE ::greptime::v1::DecimalTypeExtension* Arena::CreateMaybeMessage< ::greptime::v1::DecimalTypeExtension >(Arena* arena) { return Arena::CreateMessageInternal< ::greptime::v1::DecimalTypeExtension >(arena); } -template<> PROTOBUF_NOINLINE ::greptime::v1::JsonTypeExtension* -Arena::CreateMaybeMessage< ::greptime::v1::JsonTypeExtension >(Arena* arena) { - return Arena::CreateMessageInternal< ::greptime::v1::JsonTypeExtension >(arena); -} template<> PROTOBUF_NOINLINE ::greptime::v1::ColumnOptions_OptionsEntry_DoNotUse* Arena::CreateMaybeMessage< ::greptime::v1::ColumnOptions_OptionsEntry_DoNotUse >(Arena* arena) { return Arena::CreateMessageInternal< ::greptime::v1::ColumnOptions_OptionsEntry_DoNotUse >(arena); diff --git a/c++/greptime/v1/common.pb.h b/c++/greptime/v1/common.pb.h index c6e2f187..f54d13f5 100644 --- a/c++/greptime/v1/common.pb.h +++ b/c++/greptime/v1/common.pb.h @@ -83,9 +83,6 @@ extern FlightMetadataDefaultTypeInternal _FlightMetadata_default_instance_; class IntervalMonthDayNano; struct IntervalMonthDayNanoDefaultTypeInternal; extern IntervalMonthDayNanoDefaultTypeInternal _IntervalMonthDayNano_default_instance_; -class JsonTypeExtension; -struct JsonTypeExtensionDefaultTypeInternal; -extern JsonTypeExtensionDefaultTypeInternal _JsonTypeExtension_default_instance_; class Metrics; struct MetricsDefaultTypeInternal; extern MetricsDefaultTypeInternal _Metrics_default_instance_; @@ -127,7 +124,6 @@ template<> ::greptime::v1::DecimalTypeExtension* Arena::CreateMaybeMessage<::gre template<> ::greptime::v1::ExpireAfter* Arena::CreateMaybeMessage<::greptime::v1::ExpireAfter>(Arena*); template<> ::greptime::v1::FlightMetadata* Arena::CreateMaybeMessage<::greptime::v1::FlightMetadata>(Arena*); template<> ::greptime::v1::IntervalMonthDayNano* Arena::CreateMaybeMessage<::greptime::v1::IntervalMonthDayNano>(Arena*); -template<> ::greptime::v1::JsonTypeExtension* Arena::CreateMaybeMessage<::greptime::v1::JsonTypeExtension>(Arena*); template<> ::greptime::v1::Metrics* Arena::CreateMaybeMessage<::greptime::v1::Metrics>(Arena*); template<> ::greptime::v1::QueryContext* Arena::CreateMaybeMessage<::greptime::v1::QueryContext>(Arena*); template<> ::greptime::v1::QueryContext_ExtensionsEntry_DoNotUse* Arena::CreateMaybeMessage<::greptime::v1::QueryContext_ExtensionsEntry_DoNotUse>(Arena*); @@ -217,6 +213,30 @@ inline bool ColumnDataType_Parse( return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum( ColumnDataType_descriptor(), name, value); } +enum JsonTypeExtension : int { + JSON_BINARY = 0, + JsonTypeExtension_INT_MIN_SENTINEL_DO_NOT_USE_ = std::numeric_limits::min(), + JsonTypeExtension_INT_MAX_SENTINEL_DO_NOT_USE_ = std::numeric_limits::max() +}; +bool JsonTypeExtension_IsValid(int value); +constexpr JsonTypeExtension JsonTypeExtension_MIN = JSON_BINARY; +constexpr JsonTypeExtension JsonTypeExtension_MAX = JSON_BINARY; +constexpr int JsonTypeExtension_ARRAYSIZE = JsonTypeExtension_MAX + 1; + +const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* JsonTypeExtension_descriptor(); +template +inline const std::string& JsonTypeExtension_Name(T enum_t_value) { + static_assert(::std::is_same::value || + ::std::is_integral::value, + "Incorrect type passed to function JsonTypeExtension_Name."); + return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum( + JsonTypeExtension_descriptor(), enum_t_value); +} +inline bool JsonTypeExtension_Parse( + ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, JsonTypeExtension* value) { + return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum( + JsonTypeExtension_descriptor(), name, value); +} // =================================================================== class QueryContext_ExtensionsEntry_DoNotUse : public ::PROTOBUF_NAMESPACE_ID::internal::MapEntry( - &_JsonTypeExtension_default_instance_); - } - static constexpr int kIndexInFileMessages = - 18; - - friend void swap(JsonTypeExtension& a, JsonTypeExtension& b) { - a.Swap(&b); - } - inline void Swap(JsonTypeExtension* other) { - if (other == this) return; - #ifdef PROTOBUF_FORCE_COPY_IN_SWAP - if (GetOwningArena() != nullptr && - GetOwningArena() == other->GetOwningArena()) { - #else // PROTOBUF_FORCE_COPY_IN_SWAP - if (GetOwningArena() == other->GetOwningArena()) { - #endif // !PROTOBUF_FORCE_COPY_IN_SWAP - InternalSwap(other); - } else { - ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); - } - } - void UnsafeArenaSwap(JsonTypeExtension* other) { - if (other == this) return; - GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena()); - InternalSwap(other); - } - - // implements Message ---------------------------------------------- - - JsonTypeExtension* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final { - return CreateMaybeMessage(arena); - } - using ::PROTOBUF_NAMESPACE_ID::Message::CopyFrom; - void CopyFrom(const JsonTypeExtension& from); - using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; - void MergeFrom( const JsonTypeExtension& from) { - JsonTypeExtension::MergeImpl(*this, from); - } - private: - static void MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg); - public: - PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; - bool IsInitialized() const final; - - size_t ByteSizeLong() const final; - const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; - uint8_t* _InternalSerialize( - uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; - int GetCachedSize() const final { return _impl_._cached_size_.Get(); } - - private: - void SharedCtor(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned); - void SharedDtor(); - void SetCachedSize(int size) const final; - void InternalSwap(JsonTypeExtension* other); - - private: - friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; - static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { - return "greptime.v1.JsonTypeExtension"; - } - protected: - explicit JsonTypeExtension(::PROTOBUF_NAMESPACE_ID::Arena* arena, - bool is_message_owned = false); - public: - - static const ClassData _class_data_; - const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*GetClassData() const final; - - ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - enum : int { - kIsJsonFieldNumber = 1, - }; - // bool is_json = 1; - void clear_is_json(); - bool is_json() const; - void set_is_json(bool value); - private: - bool _internal_is_json() const; - void _internal_set_is_json(bool value); - public: - - // @@protoc_insertion_point(class_scope:greptime.v1.JsonTypeExtension) - private: - class _Internal; - - template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - struct Impl_ { - bool is_json_; - mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; - }; - union { Impl_ _impl_; }; - friend struct ::TableStruct_greptime_2fv1_2fcommon_2eproto; -}; -// ------------------------------------------------------------------- - class ColumnOptions_OptionsEntry_DoNotUse : public ::PROTOBUF_NAMESPACE_ID::internal::MapEntry(_impl_.type_ext_.json_type_); } + return static_cast< ::greptime::v1::JsonTypeExtension >(0); } -inline const ::greptime::v1::JsonTypeExtension& ColumnDataTypeExtension::_internal_json_type() const { - return _internal_has_json_type() - ? *_impl_.type_ext_.json_type_ - : reinterpret_cast< ::greptime::v1::JsonTypeExtension&>(::greptime::v1::_JsonTypeExtension_default_instance_); -} -inline const ::greptime::v1::JsonTypeExtension& ColumnDataTypeExtension::json_type() const { +inline ::greptime::v1::JsonTypeExtension ColumnDataTypeExtension::json_type() const { // @@protoc_insertion_point(field_get:greptime.v1.ColumnDataTypeExtension.json_type) return _internal_json_type(); } -inline ::greptime::v1::JsonTypeExtension* ColumnDataTypeExtension::unsafe_arena_release_json_type() { - // @@protoc_insertion_point(field_unsafe_arena_release:greptime.v1.ColumnDataTypeExtension.json_type) - if (_internal_has_json_type()) { - clear_has_type_ext(); - ::greptime::v1::JsonTypeExtension* temp = _impl_.type_ext_.json_type_; - _impl_.type_ext_.json_type_ = nullptr; - return temp; - } else { - return nullptr; - } -} -inline void ColumnDataTypeExtension::unsafe_arena_set_allocated_json_type(::greptime::v1::JsonTypeExtension* json_type) { - clear_type_ext(); - if (json_type) { - set_has_json_type(); - _impl_.type_ext_.json_type_ = json_type; - } - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:greptime.v1.ColumnDataTypeExtension.json_type) -} -inline ::greptime::v1::JsonTypeExtension* ColumnDataTypeExtension::_internal_mutable_json_type() { +inline void ColumnDataTypeExtension::_internal_set_json_type(::greptime::v1::JsonTypeExtension value) { if (!_internal_has_json_type()) { clear_type_ext(); set_has_json_type(); - _impl_.type_ext_.json_type_ = CreateMaybeMessage< ::greptime::v1::JsonTypeExtension >(GetArenaForAllocation()); } - return _impl_.type_ext_.json_type_; + _impl_.type_ext_.json_type_ = value; } -inline ::greptime::v1::JsonTypeExtension* ColumnDataTypeExtension::mutable_json_type() { - ::greptime::v1::JsonTypeExtension* _msg = _internal_mutable_json_type(); - // @@protoc_insertion_point(field_mutable:greptime.v1.ColumnDataTypeExtension.json_type) - return _msg; +inline void ColumnDataTypeExtension::set_json_type(::greptime::v1::JsonTypeExtension value) { + _internal_set_json_type(value); + // @@protoc_insertion_point(field_set:greptime.v1.ColumnDataTypeExtension.json_type) } inline bool ColumnDataTypeExtension::has_type_ext() const { @@ -5194,30 +5025,6 @@ inline void DecimalTypeExtension::set_scale(int32_t value) { // ------------------------------------------------------------------- -// JsonTypeExtension - -// bool is_json = 1; -inline void JsonTypeExtension::clear_is_json() { - _impl_.is_json_ = false; -} -inline bool JsonTypeExtension::_internal_is_json() const { - return _impl_.is_json_; -} -inline bool JsonTypeExtension::is_json() const { - // @@protoc_insertion_point(field_get:greptime.v1.JsonTypeExtension.is_json) - return _internal_is_json(); -} -inline void JsonTypeExtension::_internal_set_is_json(bool value) { - - _impl_.is_json_ = value; -} -inline void JsonTypeExtension::set_is_json(bool value) { - _internal_set_is_json(value); - // @@protoc_insertion_point(field_set:greptime.v1.JsonTypeExtension.is_json) -} - -// ------------------------------------------------------------------- - // ------------------------------------------------------------------- // ColumnOptions @@ -5292,8 +5099,6 @@ ColumnOptions::mutable_options() { // ------------------------------------------------------------------- -// ------------------------------------------------------------------- - // @@protoc_insertion_point(namespace_scope) @@ -5312,6 +5117,11 @@ template <> inline const EnumDescriptor* GetEnumDescriptor< ::greptime::v1::ColumnDataType>() { return ::greptime::v1::ColumnDataType_descriptor(); } +template <> struct is_proto_enum< ::greptime::v1::JsonTypeExtension> : ::std::true_type {}; +template <> +inline const EnumDescriptor* GetEnumDescriptor< ::greptime::v1::JsonTypeExtension>() { + return ::greptime::v1::JsonTypeExtension_descriptor(); +} PROTOBUF_NAMESPACE_CLOSE diff --git a/go/greptime/v1/common.pb.go b/go/greptime/v1/common.pb.go index 5621b050..269610ea 100644 --- a/go/greptime/v1/common.pb.go +++ b/go/greptime/v1/common.pb.go @@ -204,6 +204,49 @@ func (ColumnDataType) EnumDescriptor() ([]byte, []int) { return file_greptime_v1_common_proto_rawDescGZIP(), []int{1} } +type JsonTypeExtension int32 + +const ( + JsonTypeExtension_JSON_BINARY JsonTypeExtension = 0 +) + +// Enum value maps for JsonTypeExtension. +var ( + JsonTypeExtension_name = map[int32]string{ + 0: "JSON_BINARY", + } + JsonTypeExtension_value = map[string]int32{ + "JSON_BINARY": 0, + } +) + +func (x JsonTypeExtension) Enum() *JsonTypeExtension { + p := new(JsonTypeExtension) + *p = x + return p +} + +func (x JsonTypeExtension) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (JsonTypeExtension) Descriptor() protoreflect.EnumDescriptor { + return file_greptime_v1_common_proto_enumTypes[2].Descriptor() +} + +func (JsonTypeExtension) Type() protoreflect.EnumType { + return &file_greptime_v1_common_proto_enumTypes[2] +} + +func (x JsonTypeExtension) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use JsonTypeExtension.Descriptor instead. +func (JsonTypeExtension) EnumDescriptor() ([]byte, []int) { + return file_greptime_v1_common_proto_rawDescGZIP(), []int{2} +} + type QueryContext struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1100,11 +1143,11 @@ func (x *ColumnDataTypeExtension) GetDecimalType() *DecimalTypeExtension { return nil } -func (x *ColumnDataTypeExtension) GetJsonType() *JsonTypeExtension { +func (x *ColumnDataTypeExtension) GetJsonType() JsonTypeExtension { if x, ok := x.GetTypeExt().(*ColumnDataTypeExtension_JsonType); ok { return x.JsonType } - return nil + return JsonTypeExtension_JSON_BINARY } type isColumnDataTypeExtension_TypeExt interface { @@ -1117,7 +1160,7 @@ type ColumnDataTypeExtension_DecimalType struct { type ColumnDataTypeExtension_JsonType struct { // Marks the binary column in proto is actually a JSON column. - JsonType *JsonTypeExtension `protobuf:"bytes,2,opt,name=json_type,json=jsonType,proto3,oneof"` + JsonType JsonTypeExtension `protobuf:"varint,2,opt,name=json_type,json=jsonType,proto3,enum=greptime.v1.JsonTypeExtension,oneof"` } func (*ColumnDataTypeExtension_DecimalType) isColumnDataTypeExtension_TypeExt() {} @@ -1179,53 +1222,6 @@ func (x *DecimalTypeExtension) GetScale() int32 { return 0 } -type JsonTypeExtension struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - IsJson bool `protobuf:"varint,1,opt,name=is_json,json=isJson,proto3" json:"is_json,omitempty"` -} - -func (x *JsonTypeExtension) Reset() { - *x = JsonTypeExtension{} - if protoimpl.UnsafeEnabled { - mi := &file_greptime_v1_common_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *JsonTypeExtension) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*JsonTypeExtension) ProtoMessage() {} - -func (x *JsonTypeExtension) ProtoReflect() protoreflect.Message { - mi := &file_greptime_v1_common_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use JsonTypeExtension.ProtoReflect.Descriptor instead. -func (*JsonTypeExtension) Descriptor() ([]byte, []int) { - return file_greptime_v1_common_proto_rawDescGZIP(), []int{16} -} - -func (x *JsonTypeExtension) GetIsJson() bool { - if x != nil { - return x.IsJson - } - return false -} - // Additional options for the column. type ColumnOptions struct { state protoimpl.MessageState @@ -1258,7 +1254,7 @@ type ColumnOptions struct { func (x *ColumnOptions) Reset() { *x = ColumnOptions{} if protoimpl.UnsafeEnabled { - mi := &file_greptime_v1_common_proto_msgTypes[17] + mi := &file_greptime_v1_common_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1271,7 +1267,7 @@ func (x *ColumnOptions) String() string { func (*ColumnOptions) ProtoMessage() {} func (x *ColumnOptions) ProtoReflect() protoreflect.Message { - mi := &file_greptime_v1_common_proto_msgTypes[17] + mi := &file_greptime_v1_common_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1284,7 +1280,7 @@ func (x *ColumnOptions) ProtoReflect() protoreflect.Message { // Deprecated: Use ColumnOptions.ProtoReflect.Descriptor instead. func (*ColumnOptions) Descriptor() ([]byte, []int) { - return file_greptime_v1_common_proto_rawDescGZIP(), []int{17} + return file_greptime_v1_common_proto_rawDescGZIP(), []int{16} } func (x *ColumnOptions) GetOptions() map[string]string { @@ -1399,7 +1395,7 @@ var file_greptime_v1_common_proto_rawDesc = []byte{ 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x48, 0x00, 0x52, 0x0b, 0x64, 0x65, 0x63, 0x69, 0x6d, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x12, 0x3d, 0x0a, 0x09, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x0e, 0x32, 0x1e, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4a, 0x73, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x48, 0x00, 0x52, 0x08, 0x6a, 0x73, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x42, 0x0a, 0x0a, 0x08, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x65, 0x78, 0x74, 0x22, 0x4a, 0x0a, 0x14, 0x44, 0x65, 0x63, @@ -1407,57 +1403,57 @@ var file_greptime_v1_common_proto_rawDesc = []byte{ 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x70, 0x72, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63, 0x61, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, - 0x73, 0x63, 0x61, 0x6c, 0x65, 0x22, 0x2c, 0x0a, 0x11, 0x4a, 0x73, 0x6f, 0x6e, 0x54, 0x79, 0x70, - 0x65, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x17, 0x0a, 0x07, 0x69, 0x73, - 0x5f, 0x6a, 0x73, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x4a, - 0x73, 0x6f, 0x6e, 0x22, 0x8e, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x4f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x41, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, - 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x4f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x2e, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, - 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3a, 0x0a, 0x0c, 0x4f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x3a, 0x02, 0x38, 0x01, 0x2a, 0x31, 0x0a, 0x0c, 0x53, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, - 0x54, 0x79, 0x70, 0x65, 0x12, 0x07, 0x0a, 0x03, 0x54, 0x41, 0x47, 0x10, 0x00, 0x12, 0x09, 0x0a, - 0x05, 0x46, 0x49, 0x45, 0x4c, 0x44, 0x10, 0x01, 0x12, 0x0d, 0x0a, 0x09, 0x54, 0x49, 0x4d, 0x45, - 0x53, 0x54, 0x41, 0x4d, 0x50, 0x10, 0x02, 0x2a, 0xd6, 0x03, 0x0a, 0x0e, 0x43, 0x6f, 0x6c, 0x75, - 0x6d, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07, 0x42, 0x4f, - 0x4f, 0x4c, 0x45, 0x41, 0x4e, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x49, 0x4e, 0x54, 0x38, 0x10, - 0x01, 0x12, 0x09, 0x0a, 0x05, 0x49, 0x4e, 0x54, 0x31, 0x36, 0x10, 0x02, 0x12, 0x09, 0x0a, 0x05, - 0x49, 0x4e, 0x54, 0x33, 0x32, 0x10, 0x03, 0x12, 0x09, 0x0a, 0x05, 0x49, 0x4e, 0x54, 0x36, 0x34, - 0x10, 0x04, 0x12, 0x09, 0x0a, 0x05, 0x55, 0x49, 0x4e, 0x54, 0x38, 0x10, 0x05, 0x12, 0x0a, 0x0a, - 0x06, 0x55, 0x49, 0x4e, 0x54, 0x31, 0x36, 0x10, 0x06, 0x12, 0x0a, 0x0a, 0x06, 0x55, 0x49, 0x4e, - 0x54, 0x33, 0x32, 0x10, 0x07, 0x12, 0x0a, 0x0a, 0x06, 0x55, 0x49, 0x4e, 0x54, 0x36, 0x34, 0x10, - 0x08, 0x12, 0x0b, 0x0a, 0x07, 0x46, 0x4c, 0x4f, 0x41, 0x54, 0x33, 0x32, 0x10, 0x09, 0x12, 0x0b, - 0x0a, 0x07, 0x46, 0x4c, 0x4f, 0x41, 0x54, 0x36, 0x34, 0x10, 0x0a, 0x12, 0x0a, 0x0a, 0x06, 0x42, - 0x49, 0x4e, 0x41, 0x52, 0x59, 0x10, 0x0b, 0x12, 0x0a, 0x0a, 0x06, 0x53, 0x54, 0x52, 0x49, 0x4e, - 0x47, 0x10, 0x0c, 0x12, 0x08, 0x0a, 0x04, 0x44, 0x41, 0x54, 0x45, 0x10, 0x0d, 0x12, 0x0c, 0x0a, - 0x08, 0x44, 0x41, 0x54, 0x45, 0x54, 0x49, 0x4d, 0x45, 0x10, 0x0e, 0x12, 0x14, 0x0a, 0x10, 0x54, - 0x49, 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x5f, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, - 0x0f, 0x12, 0x19, 0x0a, 0x15, 0x54, 0x49, 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x5f, 0x4d, - 0x49, 0x4c, 0x4c, 0x49, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x10, 0x12, 0x19, 0x0a, 0x15, - 0x54, 0x49, 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x5f, 0x4d, 0x49, 0x43, 0x52, 0x4f, 0x53, - 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x11, 0x12, 0x18, 0x0a, 0x14, 0x54, 0x49, 0x4d, 0x45, 0x53, - 0x54, 0x41, 0x4d, 0x50, 0x5f, 0x4e, 0x41, 0x4e, 0x4f, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, - 0x12, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x49, 0x4d, 0x45, 0x5f, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, - 0x10, 0x13, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x49, 0x4d, 0x45, 0x5f, 0x4d, 0x49, 0x4c, 0x4c, 0x49, - 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x14, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x49, 0x4d, 0x45, - 0x5f, 0x4d, 0x49, 0x43, 0x52, 0x4f, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x15, 0x12, 0x13, - 0x0a, 0x0f, 0x54, 0x49, 0x4d, 0x45, 0x5f, 0x4e, 0x41, 0x4e, 0x4f, 0x53, 0x45, 0x43, 0x4f, 0x4e, - 0x44, 0x10, 0x16, 0x12, 0x17, 0x0a, 0x13, 0x49, 0x4e, 0x54, 0x45, 0x52, 0x56, 0x41, 0x4c, 0x5f, - 0x59, 0x45, 0x41, 0x52, 0x5f, 0x4d, 0x4f, 0x4e, 0x54, 0x48, 0x10, 0x17, 0x12, 0x15, 0x0a, 0x11, - 0x49, 0x4e, 0x54, 0x45, 0x52, 0x56, 0x41, 0x4c, 0x5f, 0x44, 0x41, 0x59, 0x5f, 0x54, 0x49, 0x4d, - 0x45, 0x10, 0x18, 0x12, 0x1b, 0x0a, 0x17, 0x49, 0x4e, 0x54, 0x45, 0x52, 0x56, 0x41, 0x4c, 0x5f, - 0x4d, 0x4f, 0x4e, 0x54, 0x48, 0x5f, 0x44, 0x41, 0x59, 0x5f, 0x4e, 0x41, 0x4e, 0x4f, 0x10, 0x19, - 0x12, 0x0e, 0x0a, 0x0a, 0x44, 0x45, 0x43, 0x49, 0x4d, 0x41, 0x4c, 0x31, 0x32, 0x38, 0x10, 0x1e, - 0x42, 0x4f, 0x0a, 0x0e, 0x69, 0x6f, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2e, - 0x76, 0x31, 0x42, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x5a, 0x35, 0x67, 0x69, 0x74, 0x68, - 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x47, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x54, - 0x65, 0x61, 0x6d, 0x2f, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2d, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x2f, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2f, 0x76, - 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x73, 0x63, 0x61, 0x6c, 0x65, 0x22, 0x8e, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, + 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x41, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, + 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, + 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x4f, 0x70, 0x74, + 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, + 0x79, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3a, 0x0a, 0x0c, 0x4f, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x2a, 0x31, 0x0a, 0x0c, 0x53, 0x65, 0x6d, 0x61, 0x6e, 0x74, + 0x69, 0x63, 0x54, 0x79, 0x70, 0x65, 0x12, 0x07, 0x0a, 0x03, 0x54, 0x41, 0x47, 0x10, 0x00, 0x12, + 0x09, 0x0a, 0x05, 0x46, 0x49, 0x45, 0x4c, 0x44, 0x10, 0x01, 0x12, 0x0d, 0x0a, 0x09, 0x54, 0x49, + 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x10, 0x02, 0x2a, 0xd6, 0x03, 0x0a, 0x0e, 0x43, 0x6f, + 0x6c, 0x75, 0x6d, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07, + 0x42, 0x4f, 0x4f, 0x4c, 0x45, 0x41, 0x4e, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x49, 0x4e, 0x54, + 0x38, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x49, 0x4e, 0x54, 0x31, 0x36, 0x10, 0x02, 0x12, 0x09, + 0x0a, 0x05, 0x49, 0x4e, 0x54, 0x33, 0x32, 0x10, 0x03, 0x12, 0x09, 0x0a, 0x05, 0x49, 0x4e, 0x54, + 0x36, 0x34, 0x10, 0x04, 0x12, 0x09, 0x0a, 0x05, 0x55, 0x49, 0x4e, 0x54, 0x38, 0x10, 0x05, 0x12, + 0x0a, 0x0a, 0x06, 0x55, 0x49, 0x4e, 0x54, 0x31, 0x36, 0x10, 0x06, 0x12, 0x0a, 0x0a, 0x06, 0x55, + 0x49, 0x4e, 0x54, 0x33, 0x32, 0x10, 0x07, 0x12, 0x0a, 0x0a, 0x06, 0x55, 0x49, 0x4e, 0x54, 0x36, + 0x34, 0x10, 0x08, 0x12, 0x0b, 0x0a, 0x07, 0x46, 0x4c, 0x4f, 0x41, 0x54, 0x33, 0x32, 0x10, 0x09, + 0x12, 0x0b, 0x0a, 0x07, 0x46, 0x4c, 0x4f, 0x41, 0x54, 0x36, 0x34, 0x10, 0x0a, 0x12, 0x0a, 0x0a, + 0x06, 0x42, 0x49, 0x4e, 0x41, 0x52, 0x59, 0x10, 0x0b, 0x12, 0x0a, 0x0a, 0x06, 0x53, 0x54, 0x52, + 0x49, 0x4e, 0x47, 0x10, 0x0c, 0x12, 0x08, 0x0a, 0x04, 0x44, 0x41, 0x54, 0x45, 0x10, 0x0d, 0x12, + 0x0c, 0x0a, 0x08, 0x44, 0x41, 0x54, 0x45, 0x54, 0x49, 0x4d, 0x45, 0x10, 0x0e, 0x12, 0x14, 0x0a, + 0x10, 0x54, 0x49, 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x5f, 0x53, 0x45, 0x43, 0x4f, 0x4e, + 0x44, 0x10, 0x0f, 0x12, 0x19, 0x0a, 0x15, 0x54, 0x49, 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, + 0x5f, 0x4d, 0x49, 0x4c, 0x4c, 0x49, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x10, 0x12, 0x19, + 0x0a, 0x15, 0x54, 0x49, 0x4d, 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x5f, 0x4d, 0x49, 0x43, 0x52, + 0x4f, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x11, 0x12, 0x18, 0x0a, 0x14, 0x54, 0x49, 0x4d, + 0x45, 0x53, 0x54, 0x41, 0x4d, 0x50, 0x5f, 0x4e, 0x41, 0x4e, 0x4f, 0x53, 0x45, 0x43, 0x4f, 0x4e, + 0x44, 0x10, 0x12, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x49, 0x4d, 0x45, 0x5f, 0x53, 0x45, 0x43, 0x4f, + 0x4e, 0x44, 0x10, 0x13, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x49, 0x4d, 0x45, 0x5f, 0x4d, 0x49, 0x4c, + 0x4c, 0x49, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x14, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x49, + 0x4d, 0x45, 0x5f, 0x4d, 0x49, 0x43, 0x52, 0x4f, 0x53, 0x45, 0x43, 0x4f, 0x4e, 0x44, 0x10, 0x15, + 0x12, 0x13, 0x0a, 0x0f, 0x54, 0x49, 0x4d, 0x45, 0x5f, 0x4e, 0x41, 0x4e, 0x4f, 0x53, 0x45, 0x43, + 0x4f, 0x4e, 0x44, 0x10, 0x16, 0x12, 0x17, 0x0a, 0x13, 0x49, 0x4e, 0x54, 0x45, 0x52, 0x56, 0x41, + 0x4c, 0x5f, 0x59, 0x45, 0x41, 0x52, 0x5f, 0x4d, 0x4f, 0x4e, 0x54, 0x48, 0x10, 0x17, 0x12, 0x15, + 0x0a, 0x11, 0x49, 0x4e, 0x54, 0x45, 0x52, 0x56, 0x41, 0x4c, 0x5f, 0x44, 0x41, 0x59, 0x5f, 0x54, + 0x49, 0x4d, 0x45, 0x10, 0x18, 0x12, 0x1b, 0x0a, 0x17, 0x49, 0x4e, 0x54, 0x45, 0x52, 0x56, 0x41, + 0x4c, 0x5f, 0x4d, 0x4f, 0x4e, 0x54, 0x48, 0x5f, 0x44, 0x41, 0x59, 0x5f, 0x4e, 0x41, 0x4e, 0x4f, + 0x10, 0x19, 0x12, 0x0e, 0x0a, 0x0a, 0x44, 0x45, 0x43, 0x49, 0x4d, 0x41, 0x4c, 0x31, 0x32, 0x38, + 0x10, 0x1e, 0x2a, 0x24, 0x0a, 0x11, 0x4a, 0x73, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x45, 0x78, + 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x0f, 0x0a, 0x0b, 0x4a, 0x53, 0x4f, 0x4e, 0x5f, + 0x42, 0x49, 0x4e, 0x41, 0x52, 0x59, 0x10, 0x00, 0x42, 0x4f, 0x0a, 0x0e, 0x69, 0x6f, 0x2e, 0x67, + 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x06, 0x43, 0x6f, 0x6d, 0x6d, + 0x6f, 0x6e, 0x5a, 0x35, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x47, + 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x54, 0x65, 0x61, 0x6d, 0x2f, 0x67, 0x72, 0x65, 0x70, + 0x74, 0x69, 0x6d, 0x65, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x2f, 0x67, 0x72, + 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( @@ -1472,28 +1468,28 @@ func file_greptime_v1_common_proto_rawDescGZIP() []byte { return file_greptime_v1_common_proto_rawDescData } -var file_greptime_v1_common_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_greptime_v1_common_proto_msgTypes = make([]protoimpl.MessageInfo, 21) +var file_greptime_v1_common_proto_enumTypes = make([]protoimpl.EnumInfo, 3) +var file_greptime_v1_common_proto_msgTypes = make([]protoimpl.MessageInfo, 20) var file_greptime_v1_common_proto_goTypes = []interface{}{ (SemanticType)(0), // 0: greptime.v1.SemanticType (ColumnDataType)(0), // 1: greptime.v1.ColumnDataType - (*QueryContext)(nil), // 2: greptime.v1.QueryContext - (*RequestHeader)(nil), // 3: greptime.v1.RequestHeader - (*ResponseHeader)(nil), // 4: greptime.v1.ResponseHeader - (*Status)(nil), // 5: greptime.v1.Status - (*AuthHeader)(nil), // 6: greptime.v1.AuthHeader - (*Basic)(nil), // 7: greptime.v1.Basic - (*Token)(nil), // 8: greptime.v1.Token - (*TableName)(nil), // 9: greptime.v1.TableName - (*AffectedRows)(nil), // 10: greptime.v1.AffectedRows - (*Metrics)(nil), // 11: greptime.v1.Metrics - (*ExpireAfter)(nil), // 12: greptime.v1.ExpireAfter - (*FlightMetadata)(nil), // 13: greptime.v1.FlightMetadata - (*IntervalMonthDayNano)(nil), // 14: greptime.v1.IntervalMonthDayNano - (*Decimal128)(nil), // 15: greptime.v1.Decimal128 - (*ColumnDataTypeExtension)(nil), // 16: greptime.v1.ColumnDataTypeExtension - (*DecimalTypeExtension)(nil), // 17: greptime.v1.DecimalTypeExtension - (*JsonTypeExtension)(nil), // 18: greptime.v1.JsonTypeExtension + (JsonTypeExtension)(0), // 2: greptime.v1.JsonTypeExtension + (*QueryContext)(nil), // 3: greptime.v1.QueryContext + (*RequestHeader)(nil), // 4: greptime.v1.RequestHeader + (*ResponseHeader)(nil), // 5: greptime.v1.ResponseHeader + (*Status)(nil), // 6: greptime.v1.Status + (*AuthHeader)(nil), // 7: greptime.v1.AuthHeader + (*Basic)(nil), // 8: greptime.v1.Basic + (*Token)(nil), // 9: greptime.v1.Token + (*TableName)(nil), // 10: greptime.v1.TableName + (*AffectedRows)(nil), // 11: greptime.v1.AffectedRows + (*Metrics)(nil), // 12: greptime.v1.Metrics + (*ExpireAfter)(nil), // 13: greptime.v1.ExpireAfter + (*FlightMetadata)(nil), // 14: greptime.v1.FlightMetadata + (*IntervalMonthDayNano)(nil), // 15: greptime.v1.IntervalMonthDayNano + (*Decimal128)(nil), // 16: greptime.v1.Decimal128 + (*ColumnDataTypeExtension)(nil), // 17: greptime.v1.ColumnDataTypeExtension + (*DecimalTypeExtension)(nil), // 18: greptime.v1.DecimalTypeExtension (*ColumnOptions)(nil), // 19: greptime.v1.ColumnOptions nil, // 20: greptime.v1.QueryContext.ExtensionsEntry nil, // 21: greptime.v1.RequestHeader.TracingContextEntry @@ -1501,15 +1497,15 @@ var file_greptime_v1_common_proto_goTypes = []interface{}{ } var file_greptime_v1_common_proto_depIdxs = []int32{ 20, // 0: greptime.v1.QueryContext.extensions:type_name -> greptime.v1.QueryContext.ExtensionsEntry - 6, // 1: greptime.v1.RequestHeader.authorization:type_name -> greptime.v1.AuthHeader + 7, // 1: greptime.v1.RequestHeader.authorization:type_name -> greptime.v1.AuthHeader 21, // 2: greptime.v1.RequestHeader.tracing_context:type_name -> greptime.v1.RequestHeader.TracingContextEntry - 5, // 3: greptime.v1.ResponseHeader.status:type_name -> greptime.v1.Status - 7, // 4: greptime.v1.AuthHeader.basic:type_name -> greptime.v1.Basic - 8, // 5: greptime.v1.AuthHeader.token:type_name -> greptime.v1.Token - 10, // 6: greptime.v1.FlightMetadata.affected_rows:type_name -> greptime.v1.AffectedRows - 11, // 7: greptime.v1.FlightMetadata.metrics:type_name -> greptime.v1.Metrics - 17, // 8: greptime.v1.ColumnDataTypeExtension.decimal_type:type_name -> greptime.v1.DecimalTypeExtension - 18, // 9: greptime.v1.ColumnDataTypeExtension.json_type:type_name -> greptime.v1.JsonTypeExtension + 6, // 3: greptime.v1.ResponseHeader.status:type_name -> greptime.v1.Status + 8, // 4: greptime.v1.AuthHeader.basic:type_name -> greptime.v1.Basic + 9, // 5: greptime.v1.AuthHeader.token:type_name -> greptime.v1.Token + 11, // 6: greptime.v1.FlightMetadata.affected_rows:type_name -> greptime.v1.AffectedRows + 12, // 7: greptime.v1.FlightMetadata.metrics:type_name -> greptime.v1.Metrics + 18, // 8: greptime.v1.ColumnDataTypeExtension.decimal_type:type_name -> greptime.v1.DecimalTypeExtension + 2, // 9: greptime.v1.ColumnDataTypeExtension.json_type:type_name -> greptime.v1.JsonTypeExtension 22, // 10: greptime.v1.ColumnOptions.options:type_name -> greptime.v1.ColumnOptions.OptionsEntry 11, // [11:11] is the sub-list for method output_type 11, // [11:11] is the sub-list for method input_type @@ -1717,18 +1713,6 @@ func file_greptime_v1_common_proto_init() { } } file_greptime_v1_common_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*JsonTypeExtension); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_greptime_v1_common_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ColumnOptions); i { case 0: return &v.state @@ -1754,8 +1738,8 @@ func file_greptime_v1_common_proto_init() { File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_greptime_v1_common_proto_rawDesc, - NumEnums: 2, - NumMessages: 21, + NumEnums: 3, + NumMessages: 20, NumExtensions: 0, NumServices: 0, }, diff --git a/java/src/main/java/io/greptime/v1/Common.java b/java/src/main/java/io/greptime/v1/Common.java index 9b7cd3d4..d71febb3 100644 --- a/java/src/main/java/io/greptime/v1/Common.java +++ b/java/src/main/java/io/greptime/v1/Common.java @@ -464,6 +464,105 @@ private ColumnDataType(int value) { // @@protoc_insertion_point(enum_scope:greptime.v1.ColumnDataType) } + /** + * Protobuf enum {@code greptime.v1.JsonTypeExtension} + */ + public enum JsonTypeExtension + implements com.google.protobuf.ProtocolMessageEnum { + /** + * JSON_BINARY = 0; + */ + JSON_BINARY(0), + UNRECOGNIZED(-1), + ; + + /** + * JSON_BINARY = 0; + */ + public static final int JSON_BINARY_VALUE = 0; + + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static JsonTypeExtension valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static JsonTypeExtension forNumber(int value) { + switch (value) { + case 0: return JSON_BINARY; + default: return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + private static final com.google.protobuf.Internal.EnumLiteMap< + JsonTypeExtension> internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public JsonTypeExtension findValueByNumber(int number) { + return JsonTypeExtension.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor + getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + public final com.google.protobuf.Descriptors.EnumDescriptor + getDescriptorForType() { + return getDescriptor(); + } + public static final com.google.protobuf.Descriptors.EnumDescriptor + getDescriptor() { + return io.greptime.v1.Common.getDescriptor().getEnumTypes().get(2); + } + + private static final JsonTypeExtension[] VALUES = values(); + + public static JsonTypeExtension valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException( + "EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private JsonTypeExtension(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:greptime.v1.JsonTypeExtension) + } + public interface QueryContextOrBuilder extends // @@protoc_insertion_point(interface_extends:greptime.v1.QueryContext) com.google.protobuf.MessageOrBuilder { @@ -11491,17 +11590,18 @@ public interface ColumnDataTypeExtensionOrBuilder extends * * * .greptime.v1.JsonTypeExtension json_type = 2; - * @return The jsonType. + * @return The enum numeric value on the wire for jsonType. */ - io.greptime.v1.Common.JsonTypeExtension getJsonType(); + int getJsonTypeValue(); /** *
      * Marks the binary column in proto is actually a JSON column.
      * 
* * .greptime.v1.JsonTypeExtension json_type = 2; + * @return The jsonType. */ - io.greptime.v1.Common.JsonTypeExtensionOrBuilder getJsonTypeOrBuilder(); + io.greptime.v1.Common.JsonTypeExtension getJsonType(); public io.greptime.v1.Common.ColumnDataTypeExtension.TypeExtCase getTypeExtCase(); } @@ -11568,18 +11668,10 @@ private ColumnDataTypeExtension( typeExtCase_ = 1; break; } - case 18: { - io.greptime.v1.Common.JsonTypeExtension.Builder subBuilder = null; - if (typeExtCase_ == 2) { - subBuilder = ((io.greptime.v1.Common.JsonTypeExtension) typeExt_).toBuilder(); - } - typeExt_ = - input.readMessage(io.greptime.v1.Common.JsonTypeExtension.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.greptime.v1.Common.JsonTypeExtension) typeExt_); - typeExt_ = subBuilder.buildPartial(); - } + case 16: { + int rawValue = input.readEnum(); typeExtCase_ = 2; + typeExt_ = rawValue; break; } default: { @@ -11697,7 +11789,6 @@ public io.greptime.v1.Common.DecimalTypeExtensionOrBuilder getDecimalTypeOrBuild * .greptime.v1.JsonTypeExtension json_type = 2; * @return Whether the jsonType field is set. */ - @java.lang.Override public boolean hasJsonType() { return typeExtCase_ == 2; } @@ -11707,14 +11798,13 @@ public boolean hasJsonType() { * * * .greptime.v1.JsonTypeExtension json_type = 2; - * @return The jsonType. + * @return The enum numeric value on the wire for jsonType. */ - @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtension getJsonType() { + public int getJsonTypeValue() { if (typeExtCase_ == 2) { - return (io.greptime.v1.Common.JsonTypeExtension) typeExt_; + return (java.lang.Integer) typeExt_; } - return io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance(); + return 0; } /** *
@@ -11722,13 +11812,16 @@ public io.greptime.v1.Common.JsonTypeExtension getJsonType() {
      * 
* * .greptime.v1.JsonTypeExtension json_type = 2; + * @return The jsonType. */ - @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtensionOrBuilder getJsonTypeOrBuilder() { + public io.greptime.v1.Common.JsonTypeExtension getJsonType() { if (typeExtCase_ == 2) { - return (io.greptime.v1.Common.JsonTypeExtension) typeExt_; + @SuppressWarnings("deprecation") + io.greptime.v1.Common.JsonTypeExtension result = io.greptime.v1.Common.JsonTypeExtension.valueOf( + (java.lang.Integer) typeExt_); + return result == null ? io.greptime.v1.Common.JsonTypeExtension.UNRECOGNIZED : result; } - return io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance(); + return io.greptime.v1.Common.JsonTypeExtension.JSON_BINARY; } private byte memoizedIsInitialized = -1; @@ -11749,7 +11842,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) output.writeMessage(1, (io.greptime.v1.Common.DecimalTypeExtension) typeExt_); } if (typeExtCase_ == 2) { - output.writeMessage(2, (io.greptime.v1.Common.JsonTypeExtension) typeExt_); + output.writeEnum(2, ((java.lang.Integer) typeExt_)); } unknownFields.writeTo(output); } @@ -11766,7 +11859,7 @@ public int getSerializedSize() { } if (typeExtCase_ == 2) { size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (io.greptime.v1.Common.JsonTypeExtension) typeExt_); + .computeEnumSize(2, ((java.lang.Integer) typeExt_)); } size += unknownFields.getSerializedSize(); memoizedSize = size; @@ -11790,8 +11883,8 @@ public boolean equals(final java.lang.Object obj) { .equals(other.getDecimalType())) return false; break; case 2: - if (!getJsonType() - .equals(other.getJsonType())) return false; + if (getJsonTypeValue() + != other.getJsonTypeValue()) return false; break; case 0: default: @@ -11814,7 +11907,7 @@ public int hashCode() { break; case 2: hash = (37 * hash) + JSON_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getJsonType().hashCode(); + hash = (53 * hash) + getJsonTypeValue(); break; case 0: default: @@ -11992,11 +12085,7 @@ public io.greptime.v1.Common.ColumnDataTypeExtension buildPartial() { } } if (typeExtCase_ == 2) { - if (jsonTypeBuilder_ == null) { - result.typeExt_ = typeExt_; - } else { - result.typeExt_ = jsonTypeBuilder_.build(); - } + result.typeExt_ = typeExt_; } result.typeExtCase_ = typeExtCase_; onBuilt(); @@ -12053,7 +12142,7 @@ public Builder mergeFrom(io.greptime.v1.Common.ColumnDataTypeExtension other) { break; } case JSON_TYPE: { - mergeJsonType(other.getJsonType()); + setJsonTypeValue(other.getJsonTypeValue()); break; } case TYPEEXT_NOT_SET: { @@ -12246,8 +12335,6 @@ public io.greptime.v1.Common.DecimalTypeExtensionOrBuilder getDecimalTypeOrBuild return decimalTypeBuilder_; } - private com.google.protobuf.SingleFieldBuilderV3< - io.greptime.v1.Common.JsonTypeExtension, io.greptime.v1.Common.JsonTypeExtension.Builder, io.greptime.v1.Common.JsonTypeExtensionOrBuilder> jsonTypeBuilder_; /** *
        * Marks the binary column in proto is actually a JSON column.
@@ -12266,21 +12353,14 @@ public boolean hasJsonType() {
        * 
* * .greptime.v1.JsonTypeExtension json_type = 2; - * @return The jsonType. + * @return The enum numeric value on the wire for jsonType. */ @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtension getJsonType() { - if (jsonTypeBuilder_ == null) { - if (typeExtCase_ == 2) { - return (io.greptime.v1.Common.JsonTypeExtension) typeExt_; - } - return io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance(); - } else { - if (typeExtCase_ == 2) { - return jsonTypeBuilder_.getMessage(); - } - return io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance(); + public int getJsonTypeValue() { + if (typeExtCase_ == 2) { + return ((java.lang.Integer) typeExt_).intValue(); } + return 0; } /** *
@@ -12288,18 +12368,13 @@ public io.greptime.v1.Common.JsonTypeExtension getJsonType() {
        * 
* * .greptime.v1.JsonTypeExtension json_type = 2; + * @param value The enum numeric value on the wire for jsonType to set. + * @return This builder for chaining. */ - public Builder setJsonType(io.greptime.v1.Common.JsonTypeExtension value) { - if (jsonTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - typeExt_ = value; - onChanged(); - } else { - jsonTypeBuilder_.setMessage(value); - } + public Builder setJsonTypeValue(int value) { typeExtCase_ = 2; + typeExt_ = value; + onChanged(); return this; } /** @@ -12308,17 +12383,17 @@ public Builder setJsonType(io.greptime.v1.Common.JsonTypeExtension value) { * * * .greptime.v1.JsonTypeExtension json_type = 2; + * @return The jsonType. */ - public Builder setJsonType( - io.greptime.v1.Common.JsonTypeExtension.Builder builderForValue) { - if (jsonTypeBuilder_ == null) { - typeExt_ = builderForValue.build(); - onChanged(); - } else { - jsonTypeBuilder_.setMessage(builderForValue.build()); + @java.lang.Override + public io.greptime.v1.Common.JsonTypeExtension getJsonType() { + if (typeExtCase_ == 2) { + @SuppressWarnings("deprecation") + io.greptime.v1.Common.JsonTypeExtension result = io.greptime.v1.Common.JsonTypeExtension.valueOf( + (java.lang.Integer) typeExt_); + return result == null ? io.greptime.v1.Common.JsonTypeExtension.UNRECOGNIZED : result; } - typeExtCase_ = 2; - return this; + return io.greptime.v1.Common.JsonTypeExtension.JSON_BINARY; } /** *
@@ -12326,25 +12401,16 @@ public Builder setJsonType(
        * 
* * .greptime.v1.JsonTypeExtension json_type = 2; + * @param value The jsonType to set. + * @return This builder for chaining. */ - public Builder mergeJsonType(io.greptime.v1.Common.JsonTypeExtension value) { - if (jsonTypeBuilder_ == null) { - if (typeExtCase_ == 2 && - typeExt_ != io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance()) { - typeExt_ = io.greptime.v1.Common.JsonTypeExtension.newBuilder((io.greptime.v1.Common.JsonTypeExtension) typeExt_) - .mergeFrom(value).buildPartial(); - } else { - typeExt_ = value; - } - onChanged(); - } else { - if (typeExtCase_ == 2) { - jsonTypeBuilder_.mergeFrom(value); - } else { - jsonTypeBuilder_.setMessage(value); - } + public Builder setJsonType(io.greptime.v1.Common.JsonTypeExtension value) { + if (value == null) { + throw new NullPointerException(); } typeExtCase_ = 2; + typeExt_ = value.getNumber(); + onChanged(); return this; } /** @@ -12353,75 +12419,15 @@ public Builder mergeJsonType(io.greptime.v1.Common.JsonTypeExtension value) { * * * .greptime.v1.JsonTypeExtension json_type = 2; + * @return This builder for chaining. */ public Builder clearJsonType() { - if (jsonTypeBuilder_ == null) { - if (typeExtCase_ == 2) { - typeExtCase_ = 0; - typeExt_ = null; - onChanged(); - } - } else { - if (typeExtCase_ == 2) { - typeExtCase_ = 0; - typeExt_ = null; - } - jsonTypeBuilder_.clear(); - } - return this; - } - /** - *
-       * Marks the binary column in proto is actually a JSON column.
-       * 
- * - * .greptime.v1.JsonTypeExtension json_type = 2; - */ - public io.greptime.v1.Common.JsonTypeExtension.Builder getJsonTypeBuilder() { - return getJsonTypeFieldBuilder().getBuilder(); - } - /** - *
-       * Marks the binary column in proto is actually a JSON column.
-       * 
- * - * .greptime.v1.JsonTypeExtension json_type = 2; - */ - @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtensionOrBuilder getJsonTypeOrBuilder() { - if ((typeExtCase_ == 2) && (jsonTypeBuilder_ != null)) { - return jsonTypeBuilder_.getMessageOrBuilder(); - } else { - if (typeExtCase_ == 2) { - return (io.greptime.v1.Common.JsonTypeExtension) typeExt_; - } - return io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance(); - } - } - /** - *
-       * Marks the binary column in proto is actually a JSON column.
-       * 
- * - * .greptime.v1.JsonTypeExtension json_type = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.greptime.v1.Common.JsonTypeExtension, io.greptime.v1.Common.JsonTypeExtension.Builder, io.greptime.v1.Common.JsonTypeExtensionOrBuilder> - getJsonTypeFieldBuilder() { - if (jsonTypeBuilder_ == null) { - if (!(typeExtCase_ == 2)) { - typeExt_ = io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance(); - } - jsonTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - io.greptime.v1.Common.JsonTypeExtension, io.greptime.v1.Common.JsonTypeExtension.Builder, io.greptime.v1.Common.JsonTypeExtensionOrBuilder>( - (io.greptime.v1.Common.JsonTypeExtension) typeExt_, - getParentForChildren(), - isClean()); + if (typeExtCase_ == 2) { + typeExtCase_ = 0; typeExt_ = null; + onChanged(); } - typeExtCase_ = 2; - onChanged();; - return jsonTypeBuilder_; + return this; } @java.lang.Override public final Builder setUnknownFields( @@ -13036,521 +13042,30 @@ public io.greptime.v1.Common.DecimalTypeExtension getDefaultInstanceForType() { } - public interface JsonTypeExtensionOrBuilder extends - // @@protoc_insertion_point(interface_extends:greptime.v1.JsonTypeExtension) + public interface ColumnOptionsOrBuilder extends + // @@protoc_insertion_point(interface_extends:greptime.v1.ColumnOptions) com.google.protobuf.MessageOrBuilder { /** - * bool is_json = 1; - * @return The isJson. - */ - boolean getIsJson(); - } - /** - * Protobuf type {@code greptime.v1.JsonTypeExtension} - */ - public static final class JsonTypeExtension extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:greptime.v1.JsonTypeExtension) - JsonTypeExtensionOrBuilder { - private static final long serialVersionUID = 0L; - // Use JsonTypeExtension.newBuilder() to construct. - private JsonTypeExtension(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private JsonTypeExtension() { - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { - return new JsonTypeExtension(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private JsonTypeExtension( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: { - - isJson_ = input.readBool(); - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return io.greptime.v1.Common.internal_static_greptime_v1_JsonTypeExtension_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.greptime.v1.Common.internal_static_greptime_v1_JsonTypeExtension_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.greptime.v1.Common.JsonTypeExtension.class, io.greptime.v1.Common.JsonTypeExtension.Builder.class); - } - - public static final int IS_JSON_FIELD_NUMBER = 1; - private boolean isJson_; - /** - * bool is_json = 1; - * @return The isJson. - */ - @java.lang.Override - public boolean getIsJson() { - return isJson_; - } - - private byte memoizedIsInitialized = -1; - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (isJson_ != false) { - output.writeBool(1, isJson_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (isJson_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(1, isJson_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof io.greptime.v1.Common.JsonTypeExtension)) { - return super.equals(obj); - } - io.greptime.v1.Common.JsonTypeExtension other = (io.greptime.v1.Common.JsonTypeExtension) obj; - - if (getIsJson() - != other.getIsJson()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + IS_JSON_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getIsJson()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - public static io.greptime.v1.Common.JsonTypeExtension parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static io.greptime.v1.Common.JsonTypeExtension parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static io.greptime.v1.Common.JsonTypeExtension parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(io.greptime.v1.Common.JsonTypeExtension prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code greptime.v1.JsonTypeExtension} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:greptime.v1.JsonTypeExtension) - io.greptime.v1.Common.JsonTypeExtensionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return io.greptime.v1.Common.internal_static_greptime_v1_JsonTypeExtension_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.greptime.v1.Common.internal_static_greptime_v1_JsonTypeExtension_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.greptime.v1.Common.JsonTypeExtension.class, io.greptime.v1.Common.JsonTypeExtension.Builder.class); - } - - // Construct using io.greptime.v1.Common.JsonTypeExtension.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - @java.lang.Override - public Builder clear() { - super.clear(); - isJson_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return io.greptime.v1.Common.internal_static_greptime_v1_JsonTypeExtension_descriptor; - } - - @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtension getDefaultInstanceForType() { - return io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance(); - } - - @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtension build() { - io.greptime.v1.Common.JsonTypeExtension result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtension buildPartial() { - io.greptime.v1.Common.JsonTypeExtension result = new io.greptime.v1.Common.JsonTypeExtension(this); - result.isJson_ = isJson_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return super.setField(field, value); - } - @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return super.addRepeatedField(field, value); - } - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.greptime.v1.Common.JsonTypeExtension) { - return mergeFrom((io.greptime.v1.Common.JsonTypeExtension)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.greptime.v1.Common.JsonTypeExtension other) { - if (other == io.greptime.v1.Common.JsonTypeExtension.getDefaultInstance()) return this; - if (other.getIsJson() != false) { - setIsJson(other.getIsJson()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.greptime.v1.Common.JsonTypeExtension parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.greptime.v1.Common.JsonTypeExtension) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private boolean isJson_ ; - /** - * bool is_json = 1; - * @return The isJson. - */ - @java.lang.Override - public boolean getIsJson() { - return isJson_; - } - /** - * bool is_json = 1; - * @param value The isJson to set. - * @return This builder for chaining. - */ - public Builder setIsJson(boolean value) { - - isJson_ = value; - onChanged(); - return this; - } - /** - * bool is_json = 1; - * @return This builder for chaining. - */ - public Builder clearIsJson() { - - isJson_ = false; - onChanged(); - return this; - } - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:greptime.v1.JsonTypeExtension) - } - - // @@protoc_insertion_point(class_scope:greptime.v1.JsonTypeExtension) - private static final io.greptime.v1.Common.JsonTypeExtension DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new io.greptime.v1.Common.JsonTypeExtension(); - } - - public static io.greptime.v1.Common.JsonTypeExtension getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public JsonTypeExtension parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new JsonTypeExtension(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.greptime.v1.Common.JsonTypeExtension getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ColumnOptionsOrBuilder extends - // @@protoc_insertion_point(interface_extends:greptime.v1.ColumnOptions) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Supported keys:
-     *   "fulltext":
-     *      A JSON encoded string containing full-text search options for the column.
-     *      The fulltext options JSON structure:
-     *      {
-     *        "enable": bool,          // Indicates whether full-text search is
-     *                                 // enabled for the column.
-     *        "analyzer": string,      // The language-specific text analyzer to
-     *                                 // use for indexing and searching text.
-     *                                 // Supported values: ["English" (Default), "Chinese"].
-     *        "case-sensitive": bool   // Indicates whether the text should be treated
-     *                                 // as case-sensitive during full-text search.
-     *      }
-     *      Example:
-     *      "fulltext": "{\"enable\": true, \"analyzer\": \"English\", \"case-sensitive\": false}"
-     * 
- * - * map<string, string> options = 1; + *
+     * Supported keys:
+     *   "fulltext":
+     *      A JSON encoded string containing full-text search options for the column.
+     *      The fulltext options JSON structure:
+     *      {
+     *        "enable": bool,          // Indicates whether full-text search is
+     *                                 // enabled for the column.
+     *        "analyzer": string,      // The language-specific text analyzer to
+     *                                 // use for indexing and searching text.
+     *                                 // Supported values: ["English" (Default), "Chinese"].
+     *        "case-sensitive": bool   // Indicates whether the text should be treated
+     *                                 // as case-sensitive during full-text search.
+     *      }
+     *      Example:
+     *      "fulltext": "{\"enable\": true, \"analyzer\": \"English\", \"case-sensitive\": false}"
+     * 
+ * + * map<string, string> options = 1; */ int getOptionsCount(); /** @@ -14658,11 +14173,6 @@ public io.greptime.v1.Common.ColumnOptions getDefaultInstanceForType() { private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_greptime_v1_DecimalTypeExtension_fieldAccessorTable; - private static final com.google.protobuf.Descriptors.Descriptor - internal_static_greptime_v1_JsonTypeExtension_descriptor; - private static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_greptime_v1_JsonTypeExtension_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_greptime_v1_ColumnOptions_descriptor; private static final @@ -14714,26 +14224,26 @@ public io.greptime.v1.Common.ColumnOptions getDefaultInstanceForType() { "\001(\003\022\n\n\002lo\030\002 \001(\003\"\225\001\n\027ColumnDataTypeExtens" + "ion\0229\n\014decimal_type\030\001 \001(\0132!.greptime.v1." + "DecimalTypeExtensionH\000\0223\n\tjson_type\030\002 \001(" + - "\0132\036.greptime.v1.JsonTypeExtensionH\000B\n\n\010t" + + "\0162\036.greptime.v1.JsonTypeExtensionH\000B\n\n\010t" + "ype_ext\"8\n\024DecimalTypeExtension\022\021\n\tpreci" + - "sion\030\001 \001(\005\022\r\n\005scale\030\002 \001(\005\"$\n\021JsonTypeExt" + - "ension\022\017\n\007is_json\030\001 \001(\010\"y\n\rColumnOptions" + - "\0228\n\007options\030\001 \003(\0132\'.greptime.v1.ColumnOp" + - "tions.OptionsEntry\032.\n\014OptionsEntry\022\013\n\003ke" + - "y\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001*1\n\014SemanticTy" + - "pe\022\007\n\003TAG\020\000\022\t\n\005FIELD\020\001\022\r\n\tTIMESTAMP\020\002*\326\003" + - "\n\016ColumnDataType\022\013\n\007BOOLEAN\020\000\022\010\n\004INT8\020\001\022" + - "\t\n\005INT16\020\002\022\t\n\005INT32\020\003\022\t\n\005INT64\020\004\022\t\n\005UINT" + - "8\020\005\022\n\n\006UINT16\020\006\022\n\n\006UINT32\020\007\022\n\n\006UINT64\020\010\022" + - "\013\n\007FLOAT32\020\t\022\013\n\007FLOAT64\020\n\022\n\n\006BINARY\020\013\022\n\n" + - "\006STRING\020\014\022\010\n\004DATE\020\r\022\014\n\010DATETIME\020\016\022\024\n\020TIM" + - "ESTAMP_SECOND\020\017\022\031\n\025TIMESTAMP_MILLISECOND" + - "\020\020\022\031\n\025TIMESTAMP_MICROSECOND\020\021\022\030\n\024TIMESTA" + - "MP_NANOSECOND\020\022\022\017\n\013TIME_SECOND\020\023\022\024\n\020TIME" + - "_MILLISECOND\020\024\022\024\n\020TIME_MICROSECOND\020\025\022\023\n\017" + - "TIME_NANOSECOND\020\026\022\027\n\023INTERVAL_YEAR_MONTH" + - "\020\027\022\025\n\021INTERVAL_DAY_TIME\020\030\022\033\n\027INTERVAL_MO" + - "NTH_DAY_NANO\020\031\022\016\n\nDECIMAL128\020\036BO\n\016io.gre" + + "sion\030\001 \001(\005\022\r\n\005scale\030\002 \001(\005\"y\n\rColumnOptio" + + "ns\0228\n\007options\030\001 \003(\0132\'.greptime.v1.Column" + + "Options.OptionsEntry\032.\n\014OptionsEntry\022\013\n\003" + + "key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001*1\n\014Semantic" + + "Type\022\007\n\003TAG\020\000\022\t\n\005FIELD\020\001\022\r\n\tTIMESTAMP\020\002*" + + "\326\003\n\016ColumnDataType\022\013\n\007BOOLEAN\020\000\022\010\n\004INT8\020" + + "\001\022\t\n\005INT16\020\002\022\t\n\005INT32\020\003\022\t\n\005INT64\020\004\022\t\n\005UI" + + "NT8\020\005\022\n\n\006UINT16\020\006\022\n\n\006UINT32\020\007\022\n\n\006UINT64\020" + + "\010\022\013\n\007FLOAT32\020\t\022\013\n\007FLOAT64\020\n\022\n\n\006BINARY\020\013\022" + + "\n\n\006STRING\020\014\022\010\n\004DATE\020\r\022\014\n\010DATETIME\020\016\022\024\n\020T" + + "IMESTAMP_SECOND\020\017\022\031\n\025TIMESTAMP_MILLISECO" + + "ND\020\020\022\031\n\025TIMESTAMP_MICROSECOND\020\021\022\030\n\024TIMES" + + "TAMP_NANOSECOND\020\022\022\017\n\013TIME_SECOND\020\023\022\024\n\020TI" + + "ME_MILLISECOND\020\024\022\024\n\020TIME_MICROSECOND\020\025\022\023" + + "\n\017TIME_NANOSECOND\020\026\022\027\n\023INTERVAL_YEAR_MON" + + "TH\020\027\022\025\n\021INTERVAL_DAY_TIME\020\030\022\033\n\027INTERVAL_" + + "MONTH_DAY_NANO\020\031\022\016\n\nDECIMAL128\020\036*$\n\021Json" + + "TypeExtension\022\017\n\013JSON_BINARY\020\000BO\n\016io.gre" + "ptime.v1B\006CommonZ5github.com/GreptimeTea" + "m/greptime-proto/go/greptime/v1b\006proto3" }; @@ -14849,14 +14359,8 @@ public io.greptime.v1.Common.ColumnOptions getDefaultInstanceForType() { com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_greptime_v1_DecimalTypeExtension_descriptor, new java.lang.String[] { "Precision", "Scale", }); - internal_static_greptime_v1_JsonTypeExtension_descriptor = - getDescriptor().getMessageTypes().get(16); - internal_static_greptime_v1_JsonTypeExtension_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_greptime_v1_JsonTypeExtension_descriptor, - new java.lang.String[] { "IsJson", }); internal_static_greptime_v1_ColumnOptions_descriptor = - getDescriptor().getMessageTypes().get(17); + getDescriptor().getMessageTypes().get(16); internal_static_greptime_v1_ColumnOptions_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_greptime_v1_ColumnOptions_descriptor, diff --git a/proto/greptime/v1/common.proto b/proto/greptime/v1/common.proto index 338bfc04..5124f41f 100644 --- a/proto/greptime/v1/common.proto +++ b/proto/greptime/v1/common.proto @@ -145,8 +145,8 @@ message DecimalTypeExtension { int32 scale = 2; } -message JsonTypeExtension { - bool is_json = 1; +enum JsonTypeExtension { + JSON_BINARY = 0; } // Additional options for the column.