| // Copyright 2018 The Goma Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| // Code generated by protoc-gen-go. DO NOT EDIT. |
| // versions: |
| // protoc-gen-go v1.21.0 |
| // protoc v3.11.4 |
| // source: cache/cache.proto |
| |
| package cache |
| |
| import ( |
| proto "github.com/golang/protobuf/proto" |
| protoreflect "google.golang.org/protobuf/reflect/protoreflect" |
| protoimpl "google.golang.org/protobuf/runtime/protoimpl" |
| reflect "reflect" |
| sync "sync" |
| ) |
| |
| const ( |
| // Verify that this generated code is sufficiently up-to-date. |
| _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) |
| // Verify that runtime/protoimpl is sufficiently up-to-date. |
| _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) |
| ) |
| |
| // This is a compile-time assertion that a sufficiently up-to-date version |
| // of the legacy proto package is being used. |
| const _ = proto.ProtoPackageIsVersion4 |
| |
| type KV struct { |
| state protoimpl.MessageState |
| sizeCache protoimpl.SizeCache |
| unknownFields protoimpl.UnknownFields |
| |
| Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` |
| Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` |
| } |
| |
| func (x *KV) Reset() { |
| *x = KV{} |
| if protoimpl.UnsafeEnabled { |
| mi := &file_cache_cache_proto_msgTypes[0] |
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| ms.StoreMessageInfo(mi) |
| } |
| } |
| |
| func (x *KV) String() string { |
| return protoimpl.X.MessageStringOf(x) |
| } |
| |
| func (*KV) ProtoMessage() {} |
| |
| func (x *KV) ProtoReflect() protoreflect.Message { |
| mi := &file_cache_cache_proto_msgTypes[0] |
| 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 KV.ProtoReflect.Descriptor instead. |
| func (*KV) Descriptor() ([]byte, []int) { |
| return file_cache_cache_proto_rawDescGZIP(), []int{0} |
| } |
| |
| func (x *KV) GetKey() string { |
| if x != nil { |
| return x.Key |
| } |
| return "" |
| } |
| |
| func (x *KV) GetValue() []byte { |
| if x != nil { |
| return x.Value |
| } |
| return nil |
| } |
| |
| type GetReq struct { |
| state protoimpl.MessageState |
| sizeCache protoimpl.SizeCache |
| unknownFields protoimpl.UnknownFields |
| |
| Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` |
| Fast bool `protobuf:"varint,2,opt,name=fast,proto3" json:"fast,omitempty"` |
| } |
| |
| func (x *GetReq) Reset() { |
| *x = GetReq{} |
| if protoimpl.UnsafeEnabled { |
| mi := &file_cache_cache_proto_msgTypes[1] |
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| ms.StoreMessageInfo(mi) |
| } |
| } |
| |
| func (x *GetReq) String() string { |
| return protoimpl.X.MessageStringOf(x) |
| } |
| |
| func (*GetReq) ProtoMessage() {} |
| |
| func (x *GetReq) ProtoReflect() protoreflect.Message { |
| mi := &file_cache_cache_proto_msgTypes[1] |
| 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 GetReq.ProtoReflect.Descriptor instead. |
| func (*GetReq) Descriptor() ([]byte, []int) { |
| return file_cache_cache_proto_rawDescGZIP(), []int{1} |
| } |
| |
| func (x *GetReq) GetKey() string { |
| if x != nil { |
| return x.Key |
| } |
| return "" |
| } |
| |
| func (x *GetReq) GetFast() bool { |
| if x != nil { |
| return x.Fast |
| } |
| return false |
| } |
| |
| type GetResp struct { |
| state protoimpl.MessageState |
| sizeCache protoimpl.SizeCache |
| unknownFields protoimpl.UnknownFields |
| |
| Kv *KV `protobuf:"bytes,1,opt,name=kv,proto3" json:"kv,omitempty"` |
| InMemory bool `protobuf:"varint,2,opt,name=in_memory,json=inMemory,proto3" json:"in_memory,omitempty"` |
| } |
| |
| func (x *GetResp) Reset() { |
| *x = GetResp{} |
| if protoimpl.UnsafeEnabled { |
| mi := &file_cache_cache_proto_msgTypes[2] |
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| ms.StoreMessageInfo(mi) |
| } |
| } |
| |
| func (x *GetResp) String() string { |
| return protoimpl.X.MessageStringOf(x) |
| } |
| |
| func (*GetResp) ProtoMessage() {} |
| |
| func (x *GetResp) ProtoReflect() protoreflect.Message { |
| mi := &file_cache_cache_proto_msgTypes[2] |
| 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 GetResp.ProtoReflect.Descriptor instead. |
| func (*GetResp) Descriptor() ([]byte, []int) { |
| return file_cache_cache_proto_rawDescGZIP(), []int{2} |
| } |
| |
| func (x *GetResp) GetKv() *KV { |
| if x != nil { |
| return x.Kv |
| } |
| return nil |
| } |
| |
| func (x *GetResp) GetInMemory() bool { |
| if x != nil { |
| return x.InMemory |
| } |
| return false |
| } |
| |
| type PutReq struct { |
| state protoimpl.MessageState |
| sizeCache protoimpl.SizeCache |
| unknownFields protoimpl.UnknownFields |
| |
| Kv *KV `protobuf:"bytes,1,opt,name=kv,proto3" json:"kv,omitempty"` |
| WriteBack bool `protobuf:"varint,2,opt,name=write_back,json=writeBack,proto3" json:"write_back,omitempty"` |
| } |
| |
| func (x *PutReq) Reset() { |
| *x = PutReq{} |
| if protoimpl.UnsafeEnabled { |
| mi := &file_cache_cache_proto_msgTypes[3] |
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| ms.StoreMessageInfo(mi) |
| } |
| } |
| |
| func (x *PutReq) String() string { |
| return protoimpl.X.MessageStringOf(x) |
| } |
| |
| func (*PutReq) ProtoMessage() {} |
| |
| func (x *PutReq) ProtoReflect() protoreflect.Message { |
| mi := &file_cache_cache_proto_msgTypes[3] |
| 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 PutReq.ProtoReflect.Descriptor instead. |
| func (*PutReq) Descriptor() ([]byte, []int) { |
| return file_cache_cache_proto_rawDescGZIP(), []int{3} |
| } |
| |
| func (x *PutReq) GetKv() *KV { |
| if x != nil { |
| return x.Kv |
| } |
| return nil |
| } |
| |
| func (x *PutReq) GetWriteBack() bool { |
| if x != nil { |
| return x.WriteBack |
| } |
| return false |
| } |
| |
| type PutResp struct { |
| state protoimpl.MessageState |
| sizeCache protoimpl.SizeCache |
| unknownFields protoimpl.UnknownFields |
| } |
| |
| func (x *PutResp) Reset() { |
| *x = PutResp{} |
| if protoimpl.UnsafeEnabled { |
| mi := &file_cache_cache_proto_msgTypes[4] |
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) |
| ms.StoreMessageInfo(mi) |
| } |
| } |
| |
| func (x *PutResp) String() string { |
| return protoimpl.X.MessageStringOf(x) |
| } |
| |
| func (*PutResp) ProtoMessage() {} |
| |
| func (x *PutResp) ProtoReflect() protoreflect.Message { |
| mi := &file_cache_cache_proto_msgTypes[4] |
| 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 PutResp.ProtoReflect.Descriptor instead. |
| func (*PutResp) Descriptor() ([]byte, []int) { |
| return file_cache_cache_proto_rawDescGZIP(), []int{4} |
| } |
| |
| var File_cache_cache_proto protoreflect.FileDescriptor |
| |
| var file_cache_cache_proto_rawDesc = []byte{ |
| 0x0a, 0x11, 0x63, 0x61, 0x63, 0x68, 0x65, 0x2f, 0x63, 0x61, 0x63, 0x68, 0x65, 0x2e, 0x70, 0x72, |
| 0x6f, 0x74, 0x6f, 0x12, 0x05, 0x63, 0x61, 0x63, 0x68, 0x65, 0x22, 0x2c, 0x0a, 0x02, 0x4b, 0x56, |
| 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, |
| 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x2e, 0x0a, 0x06, 0x47, 0x65, 0x74, 0x52, |
| 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, |
| 0x03, 0x6b, 0x65, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x61, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, |
| 0x28, 0x08, 0x52, 0x04, 0x66, 0x61, 0x73, 0x74, 0x22, 0x41, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x52, |
| 0x65, 0x73, 0x70, 0x12, 0x19, 0x0a, 0x02, 0x6b, 0x76, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, |
| 0x09, 0x2e, 0x63, 0x61, 0x63, 0x68, 0x65, 0x2e, 0x4b, 0x56, 0x52, 0x02, 0x6b, 0x76, 0x12, 0x1b, |
| 0x0a, 0x09, 0x69, 0x6e, 0x5f, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, |
| 0x08, 0x52, 0x08, 0x69, 0x6e, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x22, 0x42, 0x0a, 0x06, 0x50, |
| 0x75, 0x74, 0x52, 0x65, 0x71, 0x12, 0x19, 0x0a, 0x02, 0x6b, 0x76, 0x18, 0x01, 0x20, 0x01, 0x28, |
| 0x0b, 0x32, 0x09, 0x2e, 0x63, 0x61, 0x63, 0x68, 0x65, 0x2e, 0x4b, 0x56, 0x52, 0x02, 0x6b, 0x76, |
| 0x12, 0x1d, 0x0a, 0x0a, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x62, 0x61, 0x63, 0x6b, 0x18, 0x02, |
| 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x77, 0x72, 0x69, 0x74, 0x65, 0x42, 0x61, 0x63, 0x6b, 0x22, |
| 0x09, 0x0a, 0x07, 0x50, 0x75, 0x74, 0x52, 0x65, 0x73, 0x70, 0x42, 0x29, 0x5a, 0x27, 0x67, 0x6f, |
| 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x6f, |
| 0x6d, 0x61, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, |
| 0x63, 0x61, 0x63, 0x68, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, |
| } |
| |
| var ( |
| file_cache_cache_proto_rawDescOnce sync.Once |
| file_cache_cache_proto_rawDescData = file_cache_cache_proto_rawDesc |
| ) |
| |
| func file_cache_cache_proto_rawDescGZIP() []byte { |
| file_cache_cache_proto_rawDescOnce.Do(func() { |
| file_cache_cache_proto_rawDescData = protoimpl.X.CompressGZIP(file_cache_cache_proto_rawDescData) |
| }) |
| return file_cache_cache_proto_rawDescData |
| } |
| |
| var file_cache_cache_proto_msgTypes = make([]protoimpl.MessageInfo, 5) |
| var file_cache_cache_proto_goTypes = []interface{}{ |
| (*KV)(nil), // 0: cache.KV |
| (*GetReq)(nil), // 1: cache.GetReq |
| (*GetResp)(nil), // 2: cache.GetResp |
| (*PutReq)(nil), // 3: cache.PutReq |
| (*PutResp)(nil), // 4: cache.PutResp |
| } |
| var file_cache_cache_proto_depIdxs = []int32{ |
| 0, // 0: cache.GetResp.kv:type_name -> cache.KV |
| 0, // 1: cache.PutReq.kv:type_name -> cache.KV |
| 2, // [2:2] is the sub-list for method output_type |
| 2, // [2:2] is the sub-list for method input_type |
| 2, // [2:2] is the sub-list for extension type_name |
| 2, // [2:2] is the sub-list for extension extendee |
| 0, // [0:2] is the sub-list for field type_name |
| } |
| |
| func init() { file_cache_cache_proto_init() } |
| func file_cache_cache_proto_init() { |
| if File_cache_cache_proto != nil { |
| return |
| } |
| if !protoimpl.UnsafeEnabled { |
| file_cache_cache_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { |
| switch v := v.(*KV); i { |
| case 0: |
| return &v.state |
| case 1: |
| return &v.sizeCache |
| case 2: |
| return &v.unknownFields |
| default: |
| return nil |
| } |
| } |
| file_cache_cache_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { |
| switch v := v.(*GetReq); i { |
| case 0: |
| return &v.state |
| case 1: |
| return &v.sizeCache |
| case 2: |
| return &v.unknownFields |
| default: |
| return nil |
| } |
| } |
| file_cache_cache_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { |
| switch v := v.(*GetResp); i { |
| case 0: |
| return &v.state |
| case 1: |
| return &v.sizeCache |
| case 2: |
| return &v.unknownFields |
| default: |
| return nil |
| } |
| } |
| file_cache_cache_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { |
| switch v := v.(*PutReq); i { |
| case 0: |
| return &v.state |
| case 1: |
| return &v.sizeCache |
| case 2: |
| return &v.unknownFields |
| default: |
| return nil |
| } |
| } |
| file_cache_cache_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { |
| switch v := v.(*PutResp); i { |
| case 0: |
| return &v.state |
| case 1: |
| return &v.sizeCache |
| case 2: |
| return &v.unknownFields |
| default: |
| return nil |
| } |
| } |
| } |
| type x struct{} |
| out := protoimpl.TypeBuilder{ |
| File: protoimpl.DescBuilder{ |
| GoPackagePath: reflect.TypeOf(x{}).PkgPath(), |
| RawDescriptor: file_cache_cache_proto_rawDesc, |
| NumEnums: 0, |
| NumMessages: 5, |
| NumExtensions: 0, |
| NumServices: 0, |
| }, |
| GoTypes: file_cache_cache_proto_goTypes, |
| DependencyIndexes: file_cache_cache_proto_depIdxs, |
| MessageInfos: file_cache_cache_proto_msgTypes, |
| }.Build() |
| File_cache_cache_proto = out.File |
| file_cache_cache_proto_rawDesc = nil |
| file_cache_cache_proto_goTypes = nil |
| file_cache_cache_proto_depIdxs = nil |
| } |