mirror of
https://github.com/go-kratos/kratos.git
synced 2025-01-07 23:02:12 +02:00
parent
a4409adf16
commit
5546be9188
@ -9,6 +9,7 @@ github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.m
|
||||
github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
|
||||
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
|
||||
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
|
||||
github.com/go-kratos/kratos/v2 v2.0.0-20210305104106-278210c4755a/go.mod h1:oLvFyDBJkkWN8TPqb+NmpvRrSy9uM/K+XQubVRc11a8=
|
||||
github.com/go-kratos/kratos/v2 v2.0.0-alpha5 h1:lewh/J44ua+EFTTdjQ9F6+yVGzV8GBFi177aPHZyJCw=
|
||||
github.com/go-kratos/kratos/v2 v2.0.0-alpha5/go.mod h1:oLvFyDBJkkWN8TPqb+NmpvRrSy9uM/K+XQubVRc11a8=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
|
||||
|
@ -32,14 +32,14 @@ run:
|
||||
ent:
|
||||
cd internal/data/ && ent generate ./ent/schema
|
||||
|
||||
.PHONY: generate
|
||||
generate:
|
||||
go generate ./...
|
||||
|
||||
.PHONY: build
|
||||
build:
|
||||
mkdir -p bin/ && go build -ldflags "-X main.Version=$(VERSION)" -o ./bin/ ./...
|
||||
|
||||
.PHONY: wire
|
||||
wire:
|
||||
cd cmd/blog/ && wire
|
||||
|
||||
.PHONY: test
|
||||
test:
|
||||
go test -v ./... -cover
|
||||
|
@ -1,8 +1,8 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.25.0
|
||||
// protoc v3.13.0
|
||||
// source: api/blog/v1/blog.proto
|
||||
// protoc-gen-go v1.25.0-devel
|
||||
// protoc v3.6.1
|
||||
// source: blog.proto
|
||||
|
||||
package v1
|
||||
|
||||
@ -40,7 +40,7 @@ type Article struct {
|
||||
func (x *Article) Reset() {
|
||||
*x = Article{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[0]
|
||||
mi := &file_blog_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -53,7 +53,7 @@ func (x *Article) String() string {
|
||||
func (*Article) ProtoMessage() {}
|
||||
|
||||
func (x *Article) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[0]
|
||||
mi := &file_blog_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -66,7 +66,7 @@ func (x *Article) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Article.ProtoReflect.Descriptor instead.
|
||||
func (*Article) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{0}
|
||||
return file_blog_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *Article) GetId() int64 {
|
||||
@ -109,7 +109,7 @@ type CreateArticleRequest struct {
|
||||
func (x *CreateArticleRequest) Reset() {
|
||||
*x = CreateArticleRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[1]
|
||||
mi := &file_blog_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -122,7 +122,7 @@ func (x *CreateArticleRequest) String() string {
|
||||
func (*CreateArticleRequest) ProtoMessage() {}
|
||||
|
||||
func (x *CreateArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[1]
|
||||
mi := &file_blog_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -135,7 +135,7 @@ func (x *CreateArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use CreateArticleRequest.ProtoReflect.Descriptor instead.
|
||||
func (*CreateArticleRequest) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{1}
|
||||
return file_blog_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *CreateArticleRequest) GetTitle() string {
|
||||
@ -163,7 +163,7 @@ type CreateArticleReply struct {
|
||||
func (x *CreateArticleReply) Reset() {
|
||||
*x = CreateArticleReply{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[2]
|
||||
mi := &file_blog_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -176,7 +176,7 @@ func (x *CreateArticleReply) String() string {
|
||||
func (*CreateArticleReply) ProtoMessage() {}
|
||||
|
||||
func (x *CreateArticleReply) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[2]
|
||||
mi := &file_blog_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -189,7 +189,7 @@ func (x *CreateArticleReply) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use CreateArticleReply.ProtoReflect.Descriptor instead.
|
||||
func (*CreateArticleReply) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{2}
|
||||
return file_blog_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *CreateArticleReply) GetArticle() *Article {
|
||||
@ -212,7 +212,7 @@ type UpdateArticleRequest struct {
|
||||
func (x *UpdateArticleRequest) Reset() {
|
||||
*x = UpdateArticleRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[3]
|
||||
mi := &file_blog_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -225,7 +225,7 @@ func (x *UpdateArticleRequest) String() string {
|
||||
func (*UpdateArticleRequest) ProtoMessage() {}
|
||||
|
||||
func (x *UpdateArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[3]
|
||||
mi := &file_blog_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -238,7 +238,7 @@ func (x *UpdateArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use UpdateArticleRequest.ProtoReflect.Descriptor instead.
|
||||
func (*UpdateArticleRequest) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{3}
|
||||
return file_blog_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *UpdateArticleRequest) GetId() int64 {
|
||||
@ -273,7 +273,7 @@ type UpdateArticleReply struct {
|
||||
func (x *UpdateArticleReply) Reset() {
|
||||
*x = UpdateArticleReply{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[4]
|
||||
mi := &file_blog_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -286,7 +286,7 @@ func (x *UpdateArticleReply) String() string {
|
||||
func (*UpdateArticleReply) ProtoMessage() {}
|
||||
|
||||
func (x *UpdateArticleReply) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[4]
|
||||
mi := &file_blog_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -299,7 +299,7 @@ func (x *UpdateArticleReply) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use UpdateArticleReply.ProtoReflect.Descriptor instead.
|
||||
func (*UpdateArticleReply) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{4}
|
||||
return file_blog_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *UpdateArticleReply) GetArticle() *Article {
|
||||
@ -320,7 +320,7 @@ type DeleteArticleRequest struct {
|
||||
func (x *DeleteArticleRequest) Reset() {
|
||||
*x = DeleteArticleRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[5]
|
||||
mi := &file_blog_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -333,7 +333,7 @@ func (x *DeleteArticleRequest) String() string {
|
||||
func (*DeleteArticleRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DeleteArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[5]
|
||||
mi := &file_blog_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -346,7 +346,7 @@ func (x *DeleteArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DeleteArticleRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DeleteArticleRequest) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{5}
|
||||
return file_blog_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
func (x *DeleteArticleRequest) GetId() int64 {
|
||||
@ -365,7 +365,7 @@ type DeleteArticleReply struct {
|
||||
func (x *DeleteArticleReply) Reset() {
|
||||
*x = DeleteArticleReply{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[6]
|
||||
mi := &file_blog_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -378,7 +378,7 @@ func (x *DeleteArticleReply) String() string {
|
||||
func (*DeleteArticleReply) ProtoMessage() {}
|
||||
|
||||
func (x *DeleteArticleReply) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[6]
|
||||
mi := &file_blog_proto_msgTypes[6]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -391,7 +391,7 @@ func (x *DeleteArticleReply) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DeleteArticleReply.ProtoReflect.Descriptor instead.
|
||||
func (*DeleteArticleReply) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{6}
|
||||
return file_blog_proto_rawDescGZIP(), []int{6}
|
||||
}
|
||||
|
||||
type GetArticleRequest struct {
|
||||
@ -405,7 +405,7 @@ type GetArticleRequest struct {
|
||||
func (x *GetArticleRequest) Reset() {
|
||||
*x = GetArticleRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[7]
|
||||
mi := &file_blog_proto_msgTypes[7]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -418,7 +418,7 @@ func (x *GetArticleRequest) String() string {
|
||||
func (*GetArticleRequest) ProtoMessage() {}
|
||||
|
||||
func (x *GetArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[7]
|
||||
mi := &file_blog_proto_msgTypes[7]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -431,7 +431,7 @@ func (x *GetArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use GetArticleRequest.ProtoReflect.Descriptor instead.
|
||||
func (*GetArticleRequest) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{7}
|
||||
return file_blog_proto_rawDescGZIP(), []int{7}
|
||||
}
|
||||
|
||||
func (x *GetArticleRequest) GetId() int64 {
|
||||
@ -452,7 +452,7 @@ type GetArticleReply struct {
|
||||
func (x *GetArticleReply) Reset() {
|
||||
*x = GetArticleReply{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[8]
|
||||
mi := &file_blog_proto_msgTypes[8]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -465,7 +465,7 @@ func (x *GetArticleReply) String() string {
|
||||
func (*GetArticleReply) ProtoMessage() {}
|
||||
|
||||
func (x *GetArticleReply) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[8]
|
||||
mi := &file_blog_proto_msgTypes[8]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -478,7 +478,7 @@ func (x *GetArticleReply) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use GetArticleReply.ProtoReflect.Descriptor instead.
|
||||
func (*GetArticleReply) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{8}
|
||||
return file_blog_proto_rawDescGZIP(), []int{8}
|
||||
}
|
||||
|
||||
func (x *GetArticleReply) GetArticle() *Article {
|
||||
@ -497,7 +497,7 @@ type ListArticleRequest struct {
|
||||
func (x *ListArticleRequest) Reset() {
|
||||
*x = ListArticleRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[9]
|
||||
mi := &file_blog_proto_msgTypes[9]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -510,7 +510,7 @@ func (x *ListArticleRequest) String() string {
|
||||
func (*ListArticleRequest) ProtoMessage() {}
|
||||
|
||||
func (x *ListArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[9]
|
||||
mi := &file_blog_proto_msgTypes[9]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -523,7 +523,7 @@ func (x *ListArticleRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use ListArticleRequest.ProtoReflect.Descriptor instead.
|
||||
func (*ListArticleRequest) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{9}
|
||||
return file_blog_proto_rawDescGZIP(), []int{9}
|
||||
}
|
||||
|
||||
type ListArticleReply struct {
|
||||
@ -537,7 +537,7 @@ type ListArticleReply struct {
|
||||
func (x *ListArticleReply) Reset() {
|
||||
*x = ListArticleReply{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[10]
|
||||
mi := &file_blog_proto_msgTypes[10]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -550,7 +550,7 @@ func (x *ListArticleReply) String() string {
|
||||
func (*ListArticleReply) ProtoMessage() {}
|
||||
|
||||
func (x *ListArticleReply) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_blog_v1_blog_proto_msgTypes[10]
|
||||
mi := &file_blog_proto_msgTypes[10]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -563,7 +563,7 @@ func (x *ListArticleReply) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use ListArticleReply.ProtoReflect.Descriptor instead.
|
||||
func (*ListArticleReply) Descriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_blog_proto_rawDescGZIP(), []int{10}
|
||||
return file_blog_proto_rawDescGZIP(), []int{10}
|
||||
}
|
||||
|
||||
func (x *ListArticleReply) GetResults() []*Article {
|
||||
@ -573,104 +573,104 @@ func (x *ListArticleReply) GetResults() []*Article {
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_api_blog_v1_blog_proto protoreflect.FileDescriptor
|
||||
var File_blog_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_api_blog_v1_blog_proto_rawDesc = []byte{
|
||||
0x0a, 0x16, 0x61, 0x70, 0x69, 0x2f, 0x62, 0x6c, 0x6f, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x62, 0x6c,
|
||||
0x6f, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x06, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31,
|
||||
0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e,
|
||||
0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x5d,
|
||||
0x0a, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74,
|
||||
0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12,
|
||||
0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6c, 0x69, 0x6b,
|
||||
0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x6c, 0x69, 0x6b, 0x65, 0x22, 0x46, 0x0a,
|
||||
0x14, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65,
|
||||
0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x63,
|
||||
0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f,
|
||||
0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x3f, 0x0a, 0x12, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x29, 0x0a, 0x07, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x61,
|
||||
0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x07, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x22, 0x56, 0x0a, 0x14, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65,
|
||||
0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e,
|
||||
0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14,
|
||||
0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74,
|
||||
0x69, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18,
|
||||
0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x3f,
|
||||
0x0a, 0x12, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52,
|
||||
0x65, 0x70, 0x6c, 0x79, 0x12, 0x29, 0x0a, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x22,
|
||||
0x26, 0x0a, 0x14, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65,
|
||||
0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x22, 0x14, 0x0a, 0x12, 0x44, 0x65, 0x6c, 0x65, 0x74,
|
||||
0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x23, 0x0a,
|
||||
0x11, 0x47, 0x65, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
var file_blog_proto_rawDesc = []byte{
|
||||
0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x06, 0x61, 0x70,
|
||||
0x69, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69,
|
||||
0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x22, 0x5d, 0x0a, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x0e, 0x0a,
|
||||
0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a,
|
||||
0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69,
|
||||
0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x03,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x6c, 0x69, 0x6b, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x6c, 0x69, 0x6b,
|
||||
0x65, 0x22, 0x46, 0x0a, 0x14, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63,
|
||||
0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74,
|
||||
0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12,
|
||||
0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x3f, 0x0a, 0x12, 0x43, 0x72, 0x65,
|
||||
0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12,
|
||||
0x29, 0x0a, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b,
|
||||
0x32, 0x0f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c,
|
||||
0x65, 0x52, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x22, 0x56, 0x0a, 0x14, 0x55, 0x70,
|
||||
0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02,
|
||||
0x69, 0x64, 0x22, 0x3c, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65,
|
||||
0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x29, 0x0a, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e,
|
||||
0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65,
|
||||
0x22, 0x14, 0x0a, 0x12, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x3d, 0x0a, 0x10, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x72,
|
||||
0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x29, 0x0a, 0x07, 0x72, 0x65,
|
||||
0x73, 0x75, 0x6c, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x61, 0x70,
|
||||
0x69, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x07, 0x72, 0x65,
|
||||
0x73, 0x75, 0x6c, 0x74, 0x73, 0x32, 0xf5, 0x03, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x67, 0x53, 0x65,
|
||||
0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x62, 0x0a, 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x1c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e,
|
||||
0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72,
|
||||
0x65, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79,
|
||||
0x22, 0x17, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x11, 0x22, 0x0c, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72,
|
||||
0x74, 0x69, 0x63, 0x6c, 0x65, 0x2f, 0x3a, 0x01, 0x2a, 0x12, 0x66, 0x0a, 0x0d, 0x55, 0x70, 0x64,
|
||||
0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74,
|
||||
0x65, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65,
|
||||
0x6e, 0x74, 0x22, 0x3f, 0x0a, 0x12, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69,
|
||||
0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x29, 0x0a, 0x07, 0x41, 0x72, 0x74, 0x69,
|
||||
0x63, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x61, 0x70, 0x69, 0x2e,
|
||||
0x76, 0x31, 0x2e, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x07, 0x41, 0x72, 0x74, 0x69,
|
||||
0x63, 0x6c, 0x65, 0x22, 0x26, 0x0a, 0x14, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x72, 0x74,
|
||||
0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69,
|
||||
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x22, 0x14, 0x0a, 0x12, 0x44,
|
||||
0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c,
|
||||
0x79, 0x22, 0x23, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x22, 0x3c, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x41, 0x72, 0x74,
|
||||
0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x29, 0x0a, 0x07, 0x41, 0x72, 0x74,
|
||||
0x69, 0x63, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x61, 0x70, 0x69,
|
||||
0x2e, 0x76, 0x31, 0x2e, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x07, 0x41, 0x72, 0x74,
|
||||
0x69, 0x63, 0x6c, 0x65, 0x22, 0x14, 0x0a, 0x12, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x72, 0x74, 0x69,
|
||||
0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x3d, 0x0a, 0x10, 0x4c, 0x69,
|
||||
0x73, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x29,
|
||||
0x0a, 0x07, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32,
|
||||
0x0f, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65,
|
||||
0x52, 0x07, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x32, 0xf5, 0x03, 0x0a, 0x0b, 0x42, 0x6c,
|
||||
0x6f, 0x67, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x62, 0x0a, 0x0d, 0x43, 0x72, 0x65,
|
||||
0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x1c, 0x2e, 0x61, 0x70, 0x69,
|
||||
0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c,
|
||||
0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c,
|
||||
0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76,
|
||||
0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52,
|
||||
0x65, 0x70, 0x6c, 0x79, 0x22, 0x1b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x15, 0x1a, 0x10, 0x2f, 0x76,
|
||||
0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x2f, 0x7b, 0x69, 0x64, 0x7d, 0x3a, 0x01,
|
||||
0x2a, 0x12, 0x63, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63,
|
||||
0x6c, 0x65, 0x12, 0x1c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65,
|
||||
0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
|
||||
0x1a, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65,
|
||||
0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52,
|
||||
0x65, 0x70, 0x6c, 0x79, 0x22, 0x17, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x11, 0x22, 0x0c, 0x2f, 0x76,
|
||||
0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x2f, 0x3a, 0x01, 0x2a, 0x12, 0x66, 0x0a,
|
||||
0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x1c,
|
||||
0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72,
|
||||
0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x61,
|
||||
0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69,
|
||||
0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x1b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x15,
|
||||
0x1a, 0x10, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x2f, 0x7b, 0x69,
|
||||
0x64, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x63, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x1c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e,
|
||||
0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65,
|
||||
0x6c, 0x65, 0x74, 0x65, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79,
|
||||
0x22, 0x18, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x12, 0x2a, 0x10, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72,
|
||||
0x74, 0x69, 0x63, 0x6c, 0x65, 0x2f, 0x7b, 0x69, 0x64, 0x7d, 0x12, 0x5a, 0x0a, 0x0a, 0x47, 0x65,
|
||||
0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x19, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76,
|
||||
0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75,
|
||||
0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74,
|
||||
0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x18, 0x82, 0xd3,
|
||||
0xe4, 0x93, 0x02, 0x12, 0x2a, 0x10, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c,
|
||||
0x65, 0x2f, 0x7b, 0x69, 0x64, 0x7d, 0x12, 0x5a, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x41, 0x72, 0x74,
|
||||
0x69, 0x63, 0x6c, 0x65, 0x12, 0x19, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65,
|
||||
0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
|
||||
0x17, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x72, 0x74, 0x69,
|
||||
0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x18, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x12,
|
||||
0x12, 0x10, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x2f, 0x7b, 0x69,
|
||||
0x64, 0x7d, 0x12, 0x59, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c,
|
||||
0x65, 0x12, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e,
|
||||
0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63,
|
||||
0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x14, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0e, 0x12,
|
||||
0x0c, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x2f, 0x42, 0x38, 0x0a,
|
||||
0x06, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x50, 0x01, 0x5a, 0x2c, 0x67, 0x69, 0x74, 0x68, 0x75,
|
||||
0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2f,
|
||||
0x65, 0x78, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x73, 0x2f, 0x62, 0x6c, 0x6f, 0x67, 0x2f, 0x61, 0x70,
|
||||
0x69, 0x2f, 0x76, 0x31, 0x3b, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0xe4, 0x93, 0x02, 0x12, 0x12, 0x10, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c,
|
||||
0x65, 0x2f, 0x7b, 0x69, 0x64, 0x7d, 0x12, 0x59, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x72,
|
||||
0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x1a, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x4c,
|
||||
0x69, 0x73, 0x74, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
|
||||
0x74, 0x1a, 0x18, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x41,
|
||||
0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x14, 0x82, 0xd3, 0xe4,
|
||||
0x93, 0x02, 0x0e, 0x12, 0x0c, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65,
|
||||
0x2f, 0x42, 0x3f, 0x0a, 0x06, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x50, 0x01, 0x5a, 0x33, 0x67,
|
||||
0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x6b, 0x72, 0x61,
|
||||
0x74, 0x6f, 0x73, 0x2f, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2f, 0x65, 0x78, 0x61, 0x6d, 0x70,
|
||||
0x6c, 0x65, 0x73, 0x2f, 0x62, 0x6c, 0x6f, 0x67, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x3b,
|
||||
0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_api_blog_v1_blog_proto_rawDescOnce sync.Once
|
||||
file_api_blog_v1_blog_proto_rawDescData = file_api_blog_v1_blog_proto_rawDesc
|
||||
file_blog_proto_rawDescOnce sync.Once
|
||||
file_blog_proto_rawDescData = file_blog_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_api_blog_v1_blog_proto_rawDescGZIP() []byte {
|
||||
file_api_blog_v1_blog_proto_rawDescOnce.Do(func() {
|
||||
file_api_blog_v1_blog_proto_rawDescData = protoimpl.X.CompressGZIP(file_api_blog_v1_blog_proto_rawDescData)
|
||||
func file_blog_proto_rawDescGZIP() []byte {
|
||||
file_blog_proto_rawDescOnce.Do(func() {
|
||||
file_blog_proto_rawDescData = protoimpl.X.CompressGZIP(file_blog_proto_rawDescData)
|
||||
})
|
||||
return file_api_blog_v1_blog_proto_rawDescData
|
||||
return file_blog_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_api_blog_v1_blog_proto_msgTypes = make([]protoimpl.MessageInfo, 11)
|
||||
var file_api_blog_v1_blog_proto_goTypes = []interface{}{
|
||||
var file_blog_proto_msgTypes = make([]protoimpl.MessageInfo, 11)
|
||||
var file_blog_proto_goTypes = []interface{}{
|
||||
(*Article)(nil), // 0: api.v1.Article
|
||||
(*CreateArticleRequest)(nil), // 1: api.v1.CreateArticleRequest
|
||||
(*CreateArticleReply)(nil), // 2: api.v1.CreateArticleReply
|
||||
@ -683,7 +683,7 @@ var file_api_blog_v1_blog_proto_goTypes = []interface{}{
|
||||
(*ListArticleRequest)(nil), // 9: api.v1.ListArticleRequest
|
||||
(*ListArticleReply)(nil), // 10: api.v1.ListArticleReply
|
||||
}
|
||||
var file_api_blog_v1_blog_proto_depIdxs = []int32{
|
||||
var file_blog_proto_depIdxs = []int32{
|
||||
0, // 0: api.v1.CreateArticleReply.Article:type_name -> api.v1.Article
|
||||
0, // 1: api.v1.UpdateArticleReply.Article:type_name -> api.v1.Article
|
||||
0, // 2: api.v1.GetArticleReply.Article:type_name -> api.v1.Article
|
||||
@ -705,13 +705,13 @@ var file_api_blog_v1_blog_proto_depIdxs = []int32{
|
||||
0, // [0:4] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_api_blog_v1_blog_proto_init() }
|
||||
func file_api_blog_v1_blog_proto_init() {
|
||||
if File_api_blog_v1_blog_proto != nil {
|
||||
func init() { file_blog_proto_init() }
|
||||
func file_blog_proto_init() {
|
||||
if File_blog_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_api_blog_v1_blog_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Article); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -723,7 +723,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*CreateArticleRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -735,7 +735,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*CreateArticleReply); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -747,7 +747,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*UpdateArticleRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -759,7 +759,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*UpdateArticleReply); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -771,7 +771,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DeleteArticleRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -783,7 +783,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DeleteArticleReply); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -795,7 +795,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetArticleRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -807,7 +807,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetArticleReply); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -819,7 +819,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*ListArticleRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -831,7 +831,7 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_api_blog_v1_blog_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_blog_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*ListArticleReply); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -848,18 +848,18 @@ func file_api_blog_v1_blog_proto_init() {
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_api_blog_v1_blog_proto_rawDesc,
|
||||
RawDescriptor: file_blog_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 11,
|
||||
NumExtensions: 0,
|
||||
NumServices: 1,
|
||||
},
|
||||
GoTypes: file_api_blog_v1_blog_proto_goTypes,
|
||||
DependencyIndexes: file_api_blog_v1_blog_proto_depIdxs,
|
||||
MessageInfos: file_api_blog_v1_blog_proto_msgTypes,
|
||||
GoTypes: file_blog_proto_goTypes,
|
||||
DependencyIndexes: file_blog_proto_depIdxs,
|
||||
MessageInfos: file_blog_proto_msgTypes,
|
||||
}.Build()
|
||||
File_api_blog_v1_blog_proto = out.File
|
||||
file_api_blog_v1_blog_proto_rawDesc = nil
|
||||
file_api_blog_v1_blog_proto_goTypes = nil
|
||||
file_api_blog_v1_blog_proto_depIdxs = nil
|
||||
File_blog_proto = out.File
|
||||
file_blog_proto_rawDesc = nil
|
||||
file_blog_proto_goTypes = nil
|
||||
file_blog_proto_depIdxs = nil
|
||||
}
|
||||
|
@ -2,7 +2,7 @@ syntax = "proto3";
|
||||
|
||||
package api.v1;
|
||||
|
||||
option go_package = "github.com/go-kratos/examples/blog/api/v1;v1";
|
||||
option go_package = "github.com/go-kratos/kratos/examples/blog/api/v1;v1";
|
||||
option java_multiple_files = true;
|
||||
option java_package = "api.v1";
|
||||
|
||||
|
@ -241,5 +241,5 @@ var BlogService_ServiceDesc = grpc.ServiceDesc{
|
||||
},
|
||||
},
|
||||
Streams: []grpc.StreamDesc{},
|
||||
Metadata: "api/blog/v1/blog.proto",
|
||||
Metadata: "blog.proto",
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.25.0
|
||||
// protoc v3.13.0
|
||||
// source: api/blog/v1/errors/article.proto
|
||||
// protoc-gen-go v1.25.0-devel
|
||||
// protoc v3.6.1
|
||||
// source: article.proto
|
||||
|
||||
package errors
|
||||
|
||||
@ -56,11 +56,11 @@ func (x Article) String() string {
|
||||
}
|
||||
|
||||
func (Article) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_api_blog_v1_errors_article_proto_enumTypes[0].Descriptor()
|
||||
return file_article_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (Article) Type() protoreflect.EnumType {
|
||||
return &file_api_blog_v1_errors_article_proto_enumTypes[0]
|
||||
return &file_article_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x Article) Number() protoreflect.EnumNumber {
|
||||
@ -69,46 +69,46 @@ func (x Article) Number() protoreflect.EnumNumber {
|
||||
|
||||
// Deprecated: Use Article.Descriptor instead.
|
||||
func (Article) EnumDescriptor() ([]byte, []int) {
|
||||
return file_api_blog_v1_errors_article_proto_rawDescGZIP(), []int{0}
|
||||
return file_article_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
var File_api_blog_v1_errors_article_proto protoreflect.FileDescriptor
|
||||
var File_article_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_api_blog_v1_errors_article_proto_rawDesc = []byte{
|
||||
0x0a, 0x20, 0x61, 0x70, 0x69, 0x2f, 0x62, 0x6c, 0x6f, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x65, 0x72,
|
||||
0x72, 0x6f, 0x72, 0x73, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x12, 0x12, 0x61, 0x70, 0x69, 0x2e, 0x62, 0x6c, 0x6f, 0x67, 0x2e, 0x76, 0x31, 0x2e,
|
||||
0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x1a, 0x1c, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2f, 0x61,
|
||||
0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x2a, 0x34, 0x0a, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12,
|
||||
0x10, 0x0a, 0x0c, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x4d, 0x69, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x10,
|
||||
0x00, 0x12, 0x12, 0x0a, 0x0e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x4d, 0x69, 0x73, 0x73,
|
||||
0x69, 0x6e, 0x67, 0x10, 0x01, 0x1a, 0x03, 0xc0, 0x3e, 0x01, 0x42, 0x5b, 0x0a, 0x0e, 0x62, 0x6c,
|
||||
0x6f, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x50, 0x01, 0x5a, 0x37,
|
||||
0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x6b, 0x72,
|
||||
0x61, 0x74, 0x6f, 0x73, 0x2f, 0x65, 0x78, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x73, 0x2f, 0x62, 0x6c,
|
||||
0x6f, 0x67, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73,
|
||||
0x3b, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0xa2, 0x02, 0x0d, 0x41, 0x50, 0x49, 0x42, 0x6c, 0x6f,
|
||||
0x67, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
var file_article_proto_rawDesc = []byte{
|
||||
0x0a, 0x0d, 0x61, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12,
|
||||
0x12, 0x61, 0x70, 0x69, 0x2e, 0x62, 0x6c, 0x6f, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x65, 0x72, 0x72,
|
||||
0x6f, 0x72, 0x73, 0x1a, 0x1c, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x2f,
|
||||
0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x2a, 0x34, 0x0a, 0x07, 0x41, 0x72, 0x74, 0x69, 0x63, 0x6c, 0x65, 0x12, 0x10, 0x0a, 0x0c,
|
||||
0x54, 0x69, 0x74, 0x6c, 0x65, 0x4d, 0x69, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x10, 0x00, 0x12, 0x12,
|
||||
0x0a, 0x0e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x4d, 0x69, 0x73, 0x73, 0x69, 0x6e, 0x67,
|
||||
0x10, 0x01, 0x1a, 0x03, 0xc0, 0x3e, 0x01, 0x42, 0x62, 0x0a, 0x0e, 0x62, 0x6c, 0x6f, 0x67, 0x2e,
|
||||
0x76, 0x31, 0x2e, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74,
|
||||
0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x6b, 0x72, 0x61, 0x74, 0x6f,
|
||||
0x73, 0x2f, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2f, 0x65, 0x78, 0x61, 0x6d, 0x70, 0x6c, 0x65,
|
||||
0x73, 0x2f, 0x62, 0x6c, 0x6f, 0x67, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x65, 0x72,
|
||||
0x72, 0x6f, 0x72, 0x73, 0x3b, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0xa2, 0x02, 0x0d, 0x41, 0x50,
|
||||
0x49, 0x42, 0x6c, 0x6f, 0x67, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_api_blog_v1_errors_article_proto_rawDescOnce sync.Once
|
||||
file_api_blog_v1_errors_article_proto_rawDescData = file_api_blog_v1_errors_article_proto_rawDesc
|
||||
file_article_proto_rawDescOnce sync.Once
|
||||
file_article_proto_rawDescData = file_article_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_api_blog_v1_errors_article_proto_rawDescGZIP() []byte {
|
||||
file_api_blog_v1_errors_article_proto_rawDescOnce.Do(func() {
|
||||
file_api_blog_v1_errors_article_proto_rawDescData = protoimpl.X.CompressGZIP(file_api_blog_v1_errors_article_proto_rawDescData)
|
||||
func file_article_proto_rawDescGZIP() []byte {
|
||||
file_article_proto_rawDescOnce.Do(func() {
|
||||
file_article_proto_rawDescData = protoimpl.X.CompressGZIP(file_article_proto_rawDescData)
|
||||
})
|
||||
return file_api_blog_v1_errors_article_proto_rawDescData
|
||||
return file_article_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_api_blog_v1_errors_article_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_api_blog_v1_errors_article_proto_goTypes = []interface{}{
|
||||
var file_article_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_article_proto_goTypes = []interface{}{
|
||||
(Article)(0), // 0: api.blog.v1.errors.Article
|
||||
}
|
||||
var file_api_blog_v1_errors_article_proto_depIdxs = []int32{
|
||||
var file_article_proto_depIdxs = []int32{
|
||||
0, // [0:0] is the sub-list for method output_type
|
||||
0, // [0:0] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
@ -116,27 +116,27 @@ var file_api_blog_v1_errors_article_proto_depIdxs = []int32{
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_api_blog_v1_errors_article_proto_init() }
|
||||
func file_api_blog_v1_errors_article_proto_init() {
|
||||
if File_api_blog_v1_errors_article_proto != nil {
|
||||
func init() { file_article_proto_init() }
|
||||
func file_article_proto_init() {
|
||||
if File_article_proto != nil {
|
||||
return
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_api_blog_v1_errors_article_proto_rawDesc,
|
||||
RawDescriptor: file_article_proto_rawDesc,
|
||||
NumEnums: 1,
|
||||
NumMessages: 0,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_api_blog_v1_errors_article_proto_goTypes,
|
||||
DependencyIndexes: file_api_blog_v1_errors_article_proto_depIdxs,
|
||||
EnumInfos: file_api_blog_v1_errors_article_proto_enumTypes,
|
||||
GoTypes: file_article_proto_goTypes,
|
||||
DependencyIndexes: file_article_proto_depIdxs,
|
||||
EnumInfos: file_article_proto_enumTypes,
|
||||
}.Build()
|
||||
File_api_blog_v1_errors_article_proto = out.File
|
||||
file_api_blog_v1_errors_article_proto_rawDesc = nil
|
||||
file_api_blog_v1_errors_article_proto_goTypes = nil
|
||||
file_api_blog_v1_errors_article_proto_depIdxs = nil
|
||||
File_article_proto = out.File
|
||||
file_article_proto_rawDesc = nil
|
||||
file_article_proto_goTypes = nil
|
||||
file_article_proto_depIdxs = nil
|
||||
}
|
||||
|
@ -5,7 +5,7 @@ package api.blog.v1.errors;
|
||||
import "kratos/api/annotations.proto";
|
||||
|
||||
// 多语言特定包名,用于源代码引用
|
||||
option go_package = "github.com/go-kratos/examples/blog/api/v1/errors;errors";
|
||||
option go_package = "github.com/go-kratos/kratos/examples/blog/api/v1/errors;errors";
|
||||
option java_multiple_files = true;
|
||||
option java_package = "blog.v1.errors";
|
||||
option objc_class_prefix = "APIBlogErrors";
|
||||
|
@ -6,7 +6,7 @@ import (
|
||||
|
||||
"go.opentelemetry.io/otel/exporters/trace/jaeger"
|
||||
|
||||
"github.com/go-kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/kratos/v2"
|
||||
"github.com/go-kratos/kratos/v2/config"
|
||||
"github.com/go-kratos/kratos/v2/config/file"
|
||||
|
@ -5,11 +5,11 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"github.com/go-kratos/examples/blog/internal/biz"
|
||||
"github.com/go-kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/examples/blog/internal/data"
|
||||
"github.com/go-kratos/examples/blog/internal/server"
|
||||
"github.com/go-kratos/examples/blog/internal/service"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/biz"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/server"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/service"
|
||||
"github.com/go-kratos/kratos/v2"
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
"github.com/google/wire"
|
||||
|
@ -6,11 +6,11 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"github.com/go-kratos/examples/blog/internal/biz"
|
||||
"github.com/go-kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/examples/blog/internal/data"
|
||||
"github.com/go-kratos/examples/blog/internal/server"
|
||||
"github.com/go-kratos/examples/blog/internal/service"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/biz"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/server"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/service"
|
||||
"github.com/go-kratos/kratos/v2"
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
)
|
||||
|
3
examples/blog/generate.go
Normal file
3
examples/blog/generate.go
Normal file
@ -0,0 +1,3 @@
|
||||
package generate
|
||||
|
||||
//go:generate kratos proto client .
|
@ -1,8 +1,8 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.25.0
|
||||
// protoc v3.13.0
|
||||
// source: internal/conf/conf.proto
|
||||
// protoc-gen-go v1.25.0-devel
|
||||
// protoc v3.6.1
|
||||
// source: conf.proto
|
||||
|
||||
package conf
|
||||
|
||||
@ -38,7 +38,7 @@ type Bootstrap struct {
|
||||
func (x *Bootstrap) Reset() {
|
||||
*x = Bootstrap{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[0]
|
||||
mi := &file_conf_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -51,7 +51,7 @@ func (x *Bootstrap) String() string {
|
||||
func (*Bootstrap) ProtoMessage() {}
|
||||
|
||||
func (x *Bootstrap) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[0]
|
||||
mi := &file_conf_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -64,7 +64,7 @@ func (x *Bootstrap) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Bootstrap.ProtoReflect.Descriptor instead.
|
||||
func (*Bootstrap) Descriptor() ([]byte, []int) {
|
||||
return file_internal_conf_conf_proto_rawDescGZIP(), []int{0}
|
||||
return file_conf_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *Bootstrap) GetServer() *Server {
|
||||
@ -93,7 +93,7 @@ type Server struct {
|
||||
func (x *Server) Reset() {
|
||||
*x = Server{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[1]
|
||||
mi := &file_conf_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -106,7 +106,7 @@ func (x *Server) String() string {
|
||||
func (*Server) ProtoMessage() {}
|
||||
|
||||
func (x *Server) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[1]
|
||||
mi := &file_conf_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -119,7 +119,7 @@ func (x *Server) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Server.ProtoReflect.Descriptor instead.
|
||||
func (*Server) Descriptor() ([]byte, []int) {
|
||||
return file_internal_conf_conf_proto_rawDescGZIP(), []int{1}
|
||||
return file_conf_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *Server) GetHttp() *Server_HTTP {
|
||||
@ -148,7 +148,7 @@ type Data struct {
|
||||
func (x *Data) Reset() {
|
||||
*x = Data{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[2]
|
||||
mi := &file_conf_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -161,7 +161,7 @@ func (x *Data) String() string {
|
||||
func (*Data) ProtoMessage() {}
|
||||
|
||||
func (x *Data) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[2]
|
||||
mi := &file_conf_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -174,7 +174,7 @@ func (x *Data) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Data.ProtoReflect.Descriptor instead.
|
||||
func (*Data) Descriptor() ([]byte, []int) {
|
||||
return file_internal_conf_conf_proto_rawDescGZIP(), []int{2}
|
||||
return file_conf_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *Data) GetDatabase() *Data_Database {
|
||||
@ -204,7 +204,7 @@ type Server_HTTP struct {
|
||||
func (x *Server_HTTP) Reset() {
|
||||
*x = Server_HTTP{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[3]
|
||||
mi := &file_conf_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -217,7 +217,7 @@ func (x *Server_HTTP) String() string {
|
||||
func (*Server_HTTP) ProtoMessage() {}
|
||||
|
||||
func (x *Server_HTTP) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[3]
|
||||
mi := &file_conf_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -230,7 +230,7 @@ func (x *Server_HTTP) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Server_HTTP.ProtoReflect.Descriptor instead.
|
||||
func (*Server_HTTP) Descriptor() ([]byte, []int) {
|
||||
return file_internal_conf_conf_proto_rawDescGZIP(), []int{1, 0}
|
||||
return file_conf_proto_rawDescGZIP(), []int{1, 0}
|
||||
}
|
||||
|
||||
func (x *Server_HTTP) GetNetwork() string {
|
||||
@ -267,7 +267,7 @@ type Server_GRPC struct {
|
||||
func (x *Server_GRPC) Reset() {
|
||||
*x = Server_GRPC{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[4]
|
||||
mi := &file_conf_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -280,7 +280,7 @@ func (x *Server_GRPC) String() string {
|
||||
func (*Server_GRPC) ProtoMessage() {}
|
||||
|
||||
func (x *Server_GRPC) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[4]
|
||||
mi := &file_conf_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -293,7 +293,7 @@ func (x *Server_GRPC) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Server_GRPC.ProtoReflect.Descriptor instead.
|
||||
func (*Server_GRPC) Descriptor() ([]byte, []int) {
|
||||
return file_internal_conf_conf_proto_rawDescGZIP(), []int{1, 1}
|
||||
return file_conf_proto_rawDescGZIP(), []int{1, 1}
|
||||
}
|
||||
|
||||
func (x *Server_GRPC) GetNetwork() string {
|
||||
@ -329,7 +329,7 @@ type Data_Database struct {
|
||||
func (x *Data_Database) Reset() {
|
||||
*x = Data_Database{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[5]
|
||||
mi := &file_conf_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -342,7 +342,7 @@ func (x *Data_Database) String() string {
|
||||
func (*Data_Database) ProtoMessage() {}
|
||||
|
||||
func (x *Data_Database) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[5]
|
||||
mi := &file_conf_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -355,7 +355,7 @@ func (x *Data_Database) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Data_Database.ProtoReflect.Descriptor instead.
|
||||
func (*Data_Database) Descriptor() ([]byte, []int) {
|
||||
return file_internal_conf_conf_proto_rawDescGZIP(), []int{2, 0}
|
||||
return file_conf_proto_rawDescGZIP(), []int{2, 0}
|
||||
}
|
||||
|
||||
func (x *Data_Database) GetDriver() string {
|
||||
@ -389,7 +389,7 @@ type Data_Redis struct {
|
||||
func (x *Data_Redis) Reset() {
|
||||
*x = Data_Redis{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[6]
|
||||
mi := &file_conf_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -402,7 +402,7 @@ func (x *Data_Redis) String() string {
|
||||
func (*Data_Redis) ProtoMessage() {}
|
||||
|
||||
func (x *Data_Redis) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_internal_conf_conf_proto_msgTypes[6]
|
||||
mi := &file_conf_proto_msgTypes[6]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -415,7 +415,7 @@ func (x *Data_Redis) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Data_Redis.ProtoReflect.Descriptor instead.
|
||||
func (*Data_Redis) Descriptor() ([]byte, []int) {
|
||||
return file_internal_conf_conf_proto_rawDescGZIP(), []int{2, 1}
|
||||
return file_conf_proto_rawDescGZIP(), []int{2, 1}
|
||||
}
|
||||
|
||||
func (x *Data_Redis) GetNetwork() string {
|
||||
@ -467,90 +467,89 @@ func (x *Data_Redis) GetWriteTimeout() *duration.Duration {
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_internal_conf_conf_proto protoreflect.FileDescriptor
|
||||
var File_conf_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_internal_conf_conf_proto_rawDesc = []byte{
|
||||
0x0a, 0x18, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x2f,
|
||||
0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x14, 0x6b, 0x72, 0x61, 0x74,
|
||||
0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e, 0x63, 0x6f, 0x6e, 0x66,
|
||||
0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75,
|
||||
0x66, 0x2f, 0x64, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
||||
0x22, 0x71, 0x0a, 0x09, 0x42, 0x6f, 0x6f, 0x74, 0x73, 0x74, 0x72, 0x61, 0x70, 0x12, 0x34, 0x0a,
|
||||
0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e,
|
||||
0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e,
|
||||
0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x52, 0x06, 0x73, 0x65, 0x72,
|
||||
0x76, 0x65, 0x72, 0x12, 0x2e, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||
0x0b, 0x32, 0x1a, 0x2e, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72,
|
||||
0x6e, 0x61, 0x6c, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x64,
|
||||
0x61, 0x74, 0x61, 0x22, 0xcc, 0x02, 0x0a, 0x06, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x12, 0x35,
|
||||
0x0a, 0x04, 0x68, 0x74, 0x74, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x6b,
|
||||
0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e, 0x63,
|
||||
0x6f, 0x6e, 0x66, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x48, 0x54, 0x54, 0x50, 0x52,
|
||||
0x04, 0x68, 0x74, 0x74, 0x70, 0x12, 0x35, 0x0a, 0x04, 0x67, 0x72, 0x70, 0x63, 0x18, 0x02, 0x20,
|
||||
0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74,
|
||||
0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x65,
|
||||
0x72, 0x2e, 0x47, 0x52, 0x50, 0x43, 0x52, 0x04, 0x67, 0x72, 0x70, 0x63, 0x1a, 0x69, 0x0a, 0x04,
|
||||
0x48, 0x54, 0x54, 0x50, 0x12, 0x18, 0x0a, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x12, 0x12,
|
||||
0x0a, 0x04, 0x61, 0x64, 0x64, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x61, 0x64,
|
||||
0x64, 0x72, 0x12, 0x33, 0x0a, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x03, 0x20,
|
||||
0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x07,
|
||||
0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x1a, 0x69, 0x0a, 0x04, 0x47, 0x52, 0x50, 0x43, 0x12,
|
||||
0x18, 0x0a, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x64, 0x64,
|
||||
0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x61, 0x64, 0x64, 0x72, 0x12, 0x33, 0x0a,
|
||||
0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19,
|
||||
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
|
||||
0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f,
|
||||
0x75, 0x74, 0x22, 0xdb, 0x03, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x12, 0x3f, 0x0a, 0x08, 0x64,
|
||||
0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e,
|
||||
0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e,
|
||||
0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61,
|
||||
0x73, 0x65, 0x52, 0x08, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x12, 0x36, 0x0a, 0x05,
|
||||
0x72, 0x65, 0x64, 0x69, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x6b, 0x72,
|
||||
var file_conf_proto_rawDesc = []byte{
|
||||
0x0a, 0x0a, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x14, 0x6b, 0x72,
|
||||
0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e, 0x63, 0x6f,
|
||||
0x6e, 0x66, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x64, 0x69, 0x73, 0x52, 0x05, 0x72,
|
||||
0x65, 0x64, 0x69, 0x73, 0x1a, 0x3a, 0x0a, 0x08, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65,
|
||||
0x12, 0x16, 0x0a, 0x06, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x06, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x6f, 0x75, 0x72,
|
||||
0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65,
|
||||
0x1a, 0x9d, 0x02, 0x0a, 0x05, 0x52, 0x65, 0x64, 0x69, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x6e, 0x65,
|
||||
0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x74,
|
||||
0x77, 0x6f, 0x72, 0x6b, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x64, 0x64, 0x72, 0x18, 0x02, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x04, 0x61, 0x64, 0x64, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x73, 0x73,
|
||||
0x77, 0x6f, 0x72, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x73, 0x73,
|
||||
0x77, 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x64, 0x62, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05,
|
||||
0x52, 0x02, 0x64, 0x62, 0x12, 0x3c, 0x0a, 0x0c, 0x64, 0x69, 0x61, 0x6c, 0x5f, 0x74, 0x69, 0x6d,
|
||||
0x65, 0x6f, 0x75, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f,
|
||||
0x6e, 0x66, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
||||
0x62, 0x75, 0x66, 0x2f, 0x64, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x22, 0x71, 0x0a, 0x09, 0x42, 0x6f, 0x6f, 0x74, 0x73, 0x74, 0x72, 0x61, 0x70, 0x12,
|
||||
0x34, 0x0a, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||
0x1c, 0x2e, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61,
|
||||
0x6c, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x52, 0x06, 0x73,
|
||||
0x65, 0x72, 0x76, 0x65, 0x72, 0x12, 0x2e, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20,
|
||||
0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74,
|
||||
0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x52,
|
||||
0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0xcc, 0x02, 0x0a, 0x06, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72,
|
||||
0x12, 0x35, 0x0a, 0x04, 0x68, 0x74, 0x74, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21,
|
||||
0x2e, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c,
|
||||
0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x48, 0x54, 0x54,
|
||||
0x50, 0x52, 0x04, 0x68, 0x74, 0x74, 0x70, 0x12, 0x35, 0x0a, 0x04, 0x67, 0x72, 0x70, 0x63, 0x18,
|
||||
0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69,
|
||||
0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x53, 0x65, 0x72,
|
||||
0x76, 0x65, 0x72, 0x2e, 0x47, 0x52, 0x50, 0x43, 0x52, 0x04, 0x67, 0x72, 0x70, 0x63, 0x1a, 0x69,
|
||||
0x0a, 0x04, 0x48, 0x54, 0x54, 0x50, 0x12, 0x18, 0x0a, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72,
|
||||
0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b,
|
||||
0x12, 0x12, 0x0a, 0x04, 0x61, 0x64, 0x64, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
|
||||
0x61, 0x64, 0x64, 0x72, 0x12, 0x33, 0x0a, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18,
|
||||
0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e,
|
||||
0x52, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x1a, 0x69, 0x0a, 0x04, 0x47, 0x52, 0x50,
|
||||
0x43, 0x12, 0x18, 0x0a, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x12, 0x12, 0x0a, 0x04, 0x61,
|
||||
0x64, 0x64, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x61, 0x64, 0x64, 0x72, 0x12,
|
||||
0x33, 0x0a, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b,
|
||||
0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62,
|
||||
0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x74, 0x69, 0x6d,
|
||||
0x65, 0x6f, 0x75, 0x74, 0x22, 0xdb, 0x03, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x12, 0x3f, 0x0a,
|
||||
0x08, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||
0x23, 0x2e, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61,
|
||||
0x6c, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x2e, 0x44, 0x61, 0x74, 0x61,
|
||||
0x62, 0x61, 0x73, 0x65, 0x52, 0x08, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x12, 0x36,
|
||||
0x0a, 0x05, 0x72, 0x65, 0x64, 0x69, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e,
|
||||
0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2e,
|
||||
0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x64, 0x69, 0x73, 0x52,
|
||||
0x05, 0x72, 0x65, 0x64, 0x69, 0x73, 0x1a, 0x3a, 0x0a, 0x08, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61,
|
||||
0x73, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x06, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x6f,
|
||||
0x75, 0x72, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x6f, 0x75, 0x72,
|
||||
0x63, 0x65, 0x1a, 0x9d, 0x02, 0x0a, 0x05, 0x52, 0x65, 0x64, 0x69, 0x73, 0x12, 0x18, 0x0a, 0x07,
|
||||
0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e,
|
||||
0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x64, 0x64, 0x72, 0x18, 0x02,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x61, 0x64, 0x64, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61,
|
||||
0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61,
|
||||
0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x64, 0x62, 0x18, 0x04, 0x20, 0x01,
|
||||
0x28, 0x05, 0x52, 0x02, 0x64, 0x62, 0x12, 0x3c, 0x0a, 0x0c, 0x64, 0x69, 0x61, 0x6c, 0x5f, 0x74,
|
||||
0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67,
|
||||
0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44,
|
||||
0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x64, 0x69, 0x61, 0x6c, 0x54, 0x69, 0x6d,
|
||||
0x65, 0x6f, 0x75, 0x74, 0x12, 0x3c, 0x0a, 0x0c, 0x72, 0x65, 0x61, 0x64, 0x5f, 0x74, 0x69, 0x6d,
|
||||
0x65, 0x6f, 0x75, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f,
|
||||
0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72,
|
||||
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x64, 0x69, 0x61, 0x6c, 0x54, 0x69, 0x6d, 0x65, 0x6f,
|
||||
0x75, 0x74, 0x12, 0x3c, 0x0a, 0x0c, 0x72, 0x65, 0x61, 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x6f,
|
||||
0x75, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
|
||||
0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74,
|
||||
0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x72, 0x65, 0x61, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74,
|
||||
0x12, 0x3e, 0x0a, 0x0d, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75,
|
||||
0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
|
||||
0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x52, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74,
|
||||
0x42, 0x08, 0x5a, 0x06, 0x2e, 0x3b, 0x63, 0x6f, 0x6e, 0x66, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x33,
|
||||
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x72, 0x65, 0x61, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x6f,
|
||||
0x75, 0x74, 0x12, 0x3e, 0x0a, 0x0d, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65,
|
||||
0x6f, 0x75, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
|
||||
0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61,
|
||||
0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x6f,
|
||||
0x75, 0x74, 0x42, 0x08, 0x5a, 0x06, 0x2e, 0x3b, 0x63, 0x6f, 0x6e, 0x66, 0x62, 0x06, 0x70, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_internal_conf_conf_proto_rawDescOnce sync.Once
|
||||
file_internal_conf_conf_proto_rawDescData = file_internal_conf_conf_proto_rawDesc
|
||||
file_conf_proto_rawDescOnce sync.Once
|
||||
file_conf_proto_rawDescData = file_conf_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_internal_conf_conf_proto_rawDescGZIP() []byte {
|
||||
file_internal_conf_conf_proto_rawDescOnce.Do(func() {
|
||||
file_internal_conf_conf_proto_rawDescData = protoimpl.X.CompressGZIP(file_internal_conf_conf_proto_rawDescData)
|
||||
func file_conf_proto_rawDescGZIP() []byte {
|
||||
file_conf_proto_rawDescOnce.Do(func() {
|
||||
file_conf_proto_rawDescData = protoimpl.X.CompressGZIP(file_conf_proto_rawDescData)
|
||||
})
|
||||
return file_internal_conf_conf_proto_rawDescData
|
||||
return file_conf_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_internal_conf_conf_proto_msgTypes = make([]protoimpl.MessageInfo, 7)
|
||||
var file_internal_conf_conf_proto_goTypes = []interface{}{
|
||||
var file_conf_proto_msgTypes = make([]protoimpl.MessageInfo, 7)
|
||||
var file_conf_proto_goTypes = []interface{}{
|
||||
(*Bootstrap)(nil), // 0: kratos.internal.conf.Bootstrap
|
||||
(*Server)(nil), // 1: kratos.internal.conf.Server
|
||||
(*Data)(nil), // 2: kratos.internal.conf.Data
|
||||
@ -560,7 +559,7 @@ var file_internal_conf_conf_proto_goTypes = []interface{}{
|
||||
(*Data_Redis)(nil), // 6: kratos.internal.conf.Data.Redis
|
||||
(*duration.Duration)(nil), // 7: google.protobuf.Duration
|
||||
}
|
||||
var file_internal_conf_conf_proto_depIdxs = []int32{
|
||||
var file_conf_proto_depIdxs = []int32{
|
||||
1, // 0: kratos.internal.conf.Bootstrap.server:type_name -> kratos.internal.conf.Server
|
||||
2, // 1: kratos.internal.conf.Bootstrap.data:type_name -> kratos.internal.conf.Data
|
||||
3, // 2: kratos.internal.conf.Server.http:type_name -> kratos.internal.conf.Server.HTTP
|
||||
@ -579,13 +578,13 @@ var file_internal_conf_conf_proto_depIdxs = []int32{
|
||||
0, // [0:11] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_internal_conf_conf_proto_init() }
|
||||
func file_internal_conf_conf_proto_init() {
|
||||
if File_internal_conf_conf_proto != nil {
|
||||
func init() { file_conf_proto_init() }
|
||||
func file_conf_proto_init() {
|
||||
if File_conf_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_internal_conf_conf_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_conf_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Bootstrap); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -597,7 +596,7 @@ func file_internal_conf_conf_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_internal_conf_conf_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_conf_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Server); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -609,7 +608,7 @@ func file_internal_conf_conf_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_internal_conf_conf_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_conf_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Data); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -621,7 +620,7 @@ func file_internal_conf_conf_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_internal_conf_conf_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_conf_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Server_HTTP); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -633,7 +632,7 @@ func file_internal_conf_conf_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_internal_conf_conf_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_conf_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Server_GRPC); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -645,7 +644,7 @@ func file_internal_conf_conf_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_internal_conf_conf_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_conf_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Data_Database); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -657,7 +656,7 @@ func file_internal_conf_conf_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_internal_conf_conf_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
file_conf_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Data_Redis); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -674,18 +673,18 @@ func file_internal_conf_conf_proto_init() {
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_internal_conf_conf_proto_rawDesc,
|
||||
RawDescriptor: file_conf_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 7,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_internal_conf_conf_proto_goTypes,
|
||||
DependencyIndexes: file_internal_conf_conf_proto_depIdxs,
|
||||
MessageInfos: file_internal_conf_conf_proto_msgTypes,
|
||||
GoTypes: file_conf_proto_goTypes,
|
||||
DependencyIndexes: file_conf_proto_depIdxs,
|
||||
MessageInfos: file_conf_proto_msgTypes,
|
||||
}.Build()
|
||||
File_internal_conf_conf_proto = out.File
|
||||
file_internal_conf_conf_proto_rawDesc = nil
|
||||
file_internal_conf_conf_proto_goTypes = nil
|
||||
file_internal_conf_conf_proto_depIdxs = nil
|
||||
File_conf_proto = out.File
|
||||
file_conf_proto_rawDesc = nil
|
||||
file_conf_proto_goTypes = nil
|
||||
file_conf_proto_depIdxs = nil
|
||||
}
|
||||
|
@ -2,7 +2,7 @@ package data
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/go-kratos/examples/blog/internal/biz"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/biz"
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
"time"
|
||||
)
|
||||
|
@ -2,8 +2,8 @@ package data
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/go-kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent"
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
"github.com/go-redis/redis/extra/redisotel"
|
||||
"github.com/go-redis/redis/v8"
|
||||
|
@ -8,7 +8,7 @@ import (
|
||||
"time"
|
||||
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
)
|
||||
|
||||
// Article is the model entity for the Article schema.
|
||||
|
@ -7,7 +7,7 @@ import (
|
||||
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
)
|
||||
|
||||
// ID filters vertices based on their ID field.
|
||||
|
@ -10,9 +10,9 @@ import (
|
||||
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// ArticleCreate is the builder for creating a Article entity.
|
||||
|
@ -9,8 +9,8 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
)
|
||||
|
||||
// ArticleDelete is the builder for deleting a Article entity.
|
||||
|
@ -12,10 +12,10 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// ArticleQuery is the builder for querying Article entities.
|
||||
|
@ -10,10 +10,10 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// ArticleUpdate is the builder for updating Article entities.
|
||||
|
@ -7,11 +7,11 @@ import (
|
||||
"fmt"
|
||||
"log"
|
||||
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/migrate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/migrate"
|
||||
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
|
||||
"entgo.io/ent/dialect"
|
||||
"entgo.io/ent/dialect/sql"
|
||||
|
@ -8,8 +8,8 @@ import (
|
||||
"time"
|
||||
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
)
|
||||
|
||||
// Comment is the model entity for the Comment schema.
|
||||
|
@ -7,7 +7,7 @@ import (
|
||||
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
)
|
||||
|
||||
// ID filters vertices based on their ID field.
|
||||
|
@ -10,8 +10,8 @@ import (
|
||||
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
)
|
||||
|
||||
// CommentCreate is the builder for creating a Comment entity.
|
||||
|
@ -9,8 +9,8 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
)
|
||||
|
||||
// CommentDelete is the builder for deleting a Comment entity.
|
||||
|
@ -11,9 +11,9 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
)
|
||||
|
||||
// CommentQuery is the builder for querying Comment entities.
|
||||
|
@ -10,9 +10,9 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
)
|
||||
|
||||
// CommentUpdate is the builder for updating Comment entities.
|
||||
|
@ -5,9 +5,9 @@ package enttest
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent"
|
||||
// required by schema hooks.
|
||||
_ "github.com/go-kratos/examples/blog/internal/data/ent/runtime"
|
||||
_ "github.com/go-kratos/kratos/examples/blog/internal/data/ent/runtime"
|
||||
|
||||
"entgo.io/ent/dialect/sql/schema"
|
||||
)
|
||||
|
@ -6,7 +6,7 @@ import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent"
|
||||
)
|
||||
|
||||
// The ArticleFunc type is an adapter to allow the use of ordinary
|
||||
|
@ -8,10 +8,10 @@ import (
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
|
||||
"entgo.io/ent"
|
||||
)
|
||||
|
@ -5,10 +5,10 @@ package ent
|
||||
import (
|
||||
"time"
|
||||
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/schema"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/comment"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/schema"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// The init function reads all schema descriptors with runtime code
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
package runtime
|
||||
|
||||
// The schema-stitching logic is generated in github.com/go-kratos/examples/blog/internal/data/ent/runtime.go
|
||||
// The schema-stitching logic is generated in github.com/go-kratos/kratos/examples/blog/internal/data/ent/runtime.go
|
||||
|
||||
const (
|
||||
Version = "v0.6.0" // Version of ent codegen.
|
||||
|
@ -8,7 +8,7 @@ import (
|
||||
"time"
|
||||
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// Tag is the model entity for the Tag schema.
|
||||
|
@ -7,7 +7,7 @@ import (
|
||||
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
)
|
||||
|
||||
// ID filters vertices based on their ID field.
|
||||
|
@ -10,8 +10,8 @@ import (
|
||||
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// TagCreate is the builder for creating a Tag entity.
|
||||
|
@ -9,8 +9,8 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// TagDelete is the builder for deleting a Tag entity.
|
||||
|
@ -12,9 +12,9 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// TagQuery is the builder for querying Tag entities.
|
||||
|
@ -10,9 +10,9 @@ import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
"entgo.io/ent/dialect/sql/sqlgraph"
|
||||
"entgo.io/ent/schema/field"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/examples/blog/internal/data/ent/tag"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/article"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/predicate"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/data/ent/tag"
|
||||
)
|
||||
|
||||
// TagUpdate is the builder for updating Tag entities.
|
||||
|
@ -1,9 +1,9 @@
|
||||
package server
|
||||
|
||||
import (
|
||||
v1 "github.com/go-kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/examples/blog/internal/service"
|
||||
v1 "github.com/go-kratos/kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/service"
|
||||
"github.com/go-kratos/kratos/v2/middleware"
|
||||
"github.com/go-kratos/kratos/v2/middleware/logging"
|
||||
"github.com/go-kratos/kratos/v2/middleware/recovery"
|
||||
|
@ -1,9 +1,9 @@
|
||||
package server
|
||||
|
||||
import (
|
||||
v1 "github.com/go-kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/examples/blog/internal/service"
|
||||
v1 "github.com/go-kratos/kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/conf"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/service"
|
||||
"github.com/go-kratos/kratos/v2/middleware"
|
||||
"github.com/go-kratos/kratos/v2/middleware/logging"
|
||||
"github.com/go-kratos/kratos/v2/middleware/recovery"
|
||||
|
@ -4,8 +4,8 @@ import (
|
||||
"context"
|
||||
"go.opentelemetry.io/otel"
|
||||
|
||||
pb "github.com/go-kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/examples/blog/internal/biz"
|
||||
pb "github.com/go-kratos/kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/biz"
|
||||
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
)
|
||||
|
@ -1,8 +1,8 @@
|
||||
package service
|
||||
|
||||
import (
|
||||
pb "github.com/go-kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/examples/blog/internal/biz"
|
||||
pb "github.com/go-kratos/kratos/examples/blog/api/blog/v1"
|
||||
"github.com/go-kratos/kratos/examples/blog/internal/biz"
|
||||
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
"github.com/google/wire"
|
||||
|
@ -2,75 +2,105 @@ package tracing
|
||||
|
||||
import (
|
||||
"context"
|
||||
"go.opentelemetry.io/otel"
|
||||
"go.opentelemetry.io/otel/label"
|
||||
"go.opentelemetry.io/otel/propagation"
|
||||
"google.golang.org/grpc/metadata"
|
||||
|
||||
"github.com/go-kratos/kratos/v2/middleware"
|
||||
"github.com/go-kratos/kratos/v2/transport/grpc"
|
||||
"github.com/go-kratos/kratos/v2/transport/http"
|
||||
"github.com/opentracing/opentracing-go"
|
||||
"github.com/opentracing/opentracing-go/ext"
|
||||
"github.com/opentracing/opentracing-go/log"
|
||||
"google.golang.org/grpc/metadata"
|
||||
|
||||
oteltrace "go.opentelemetry.io/otel/trace"
|
||||
)
|
||||
|
||||
var _ propagation.TextMapCarrier = &MetadataCarrier{}
|
||||
|
||||
// Option is tracing option.
|
||||
type Option func(*options)
|
||||
|
||||
type options struct {
|
||||
tracer opentracing.Tracer
|
||||
TracerProvider oteltrace.TracerProvider
|
||||
Propagators propagation.TextMapPropagator
|
||||
}
|
||||
|
||||
// WithTracer sets a custom tracer to be used for this middleware, otherwise the opentracing.GlobalTracer is used.
|
||||
func WithTracer(tracer opentracing.Tracer) Option {
|
||||
return func(o *options) {
|
||||
o.tracer = tracer
|
||||
func WithPropagators(propagators propagation.TextMapPropagator) Option {
|
||||
return func(opts *options) {
|
||||
opts.Propagators = propagators
|
||||
}
|
||||
}
|
||||
|
||||
// Server returns a new server middleware for OpenTracing.
|
||||
func WithTracerProvider(provider oteltrace.TracerProvider) Option {
|
||||
return func(opts *options) {
|
||||
opts.TracerProvider = provider
|
||||
}
|
||||
}
|
||||
|
||||
type MetadataCarrier struct {
|
||||
md *metadata.MD
|
||||
}
|
||||
|
||||
func (mc MetadataCarrier) Get(key string) string {
|
||||
values := mc.md.Get(key)
|
||||
if len(values) == 0 {
|
||||
return ""
|
||||
}
|
||||
return values[0]
|
||||
}
|
||||
|
||||
// Set stores the key-value pair.
|
||||
func (mc MetadataCarrier) Set(key string, value string) {
|
||||
mc.md.Set(key, value)
|
||||
}
|
||||
|
||||
// Server returns a new server middleware for OpenTelemetry.
|
||||
func Server(opts ...Option) middleware.Middleware {
|
||||
options := options{
|
||||
tracer: opentracing.GlobalTracer(),
|
||||
}
|
||||
options := options{}
|
||||
for _, o := range opts {
|
||||
o(&options)
|
||||
}
|
||||
if options.TracerProvider == nil {
|
||||
options.TracerProvider = otel.GetTracerProvider()
|
||||
}
|
||||
if options.TracerProvider == nil {
|
||||
options.TracerProvider = otel.GetTracerProvider()
|
||||
}
|
||||
tracer := options.TracerProvider.Tracer(
|
||||
"default",
|
||||
)
|
||||
if options.Propagators == nil {
|
||||
options.Propagators = otel.GetTextMapPropagator()
|
||||
}
|
||||
return func(handler middleware.Handler) middleware.Handler {
|
||||
return func(ctx context.Context, req interface{}) (reply interface{}, err error) {
|
||||
var (
|
||||
component string
|
||||
operation string
|
||||
spanContext opentracing.SpanContext
|
||||
component string
|
||||
operation string
|
||||
)
|
||||
if info, ok := http.FromServerContext(ctx); ok {
|
||||
// HTTP span
|
||||
component = "HTTP"
|
||||
operation = info.Request.RequestURI
|
||||
spanContext, _ = options.tracer.Extract(
|
||||
opentracing.HTTPHeaders,
|
||||
opentracing.HTTPHeadersCarrier(info.Request.Header),
|
||||
)
|
||||
ctx = propagation.NewCompositeTextMapPropagator(options.Propagators).Extract(ctx, info.Request.Header)
|
||||
} else if info, ok := grpc.FromServerContext(ctx); ok {
|
||||
// gRPC span
|
||||
component = "gRPC"
|
||||
operation = info.FullMethod
|
||||
if md, ok := metadata.FromIncomingContext(ctx); ok {
|
||||
spanContext, _ = options.tracer.Extract(
|
||||
opentracing.HTTPHeaders,
|
||||
opentracing.HTTPHeadersCarrier(md),
|
||||
)
|
||||
ctx = propagation.NewCompositeTextMapPropagator(options.Propagators).Extract(ctx, MetadataCarrier{md: &md})
|
||||
}
|
||||
}
|
||||
span := options.tracer.StartSpan(
|
||||
ctx, span := tracer.Start(ctx,
|
||||
operation,
|
||||
ext.RPCServerOption(spanContext),
|
||||
opentracing.Tag{Key: string(ext.Component), Value: component},
|
||||
oteltrace.WithAttributes(label.String("component", component)),
|
||||
oteltrace.WithSpanKind(oteltrace.SpanKindServer),
|
||||
)
|
||||
defer span.Finish()
|
||||
defer span.End()
|
||||
if reply, err = handler(ctx, req); err != nil {
|
||||
ext.Error.Set(span, true)
|
||||
span.LogFields(
|
||||
log.String("event", "error"),
|
||||
log.String("message", err.Error()),
|
||||
span.RecordError(err)
|
||||
span.SetAttributes(
|
||||
label.String("event", "error"),
|
||||
label.String("message", err.Error()),
|
||||
)
|
||||
}
|
||||
return
|
||||
|
@ -1,4 +1,4 @@
|
||||
module github.com/go-kratos/examples
|
||||
module github.com/go-kratos/kratos/examples
|
||||
|
||||
go 1.15
|
||||
|
||||
@ -16,18 +16,19 @@ require (
|
||||
github.com/gorilla/mux v1.8.0
|
||||
github.com/hashicorp/consul/api v1.8.1
|
||||
github.com/hashicorp/go-sockaddr v1.0.2 // indirect
|
||||
github.com/imdario/mergo v0.3.11 // indirect
|
||||
github.com/imdario/mergo v0.3.12 // indirect
|
||||
github.com/kr/text v0.2.0 // indirect
|
||||
github.com/leodido/go-urn v1.2.1 // indirect
|
||||
github.com/opentracing/opentracing-go v1.2.0
|
||||
github.com/ugorji/go v1.2.3 // indirect
|
||||
go.opentelemetry.io/otel v0.17.0
|
||||
go.opentelemetry.io/otel/exporters/trace/jaeger v0.17.0
|
||||
go.opentelemetry.io/otel/sdk v0.17.0
|
||||
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad // indirect
|
||||
go.opentelemetry.io/otel/trace v0.17.0
|
||||
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83 // indirect
|
||||
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110 // indirect
|
||||
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
|
||||
google.golang.org/genproto v0.0.0-20210226172003-ab064af71705
|
||||
golang.org/x/sys v0.0.0-20210309074719-68d13333faf2 // indirect
|
||||
google.golang.org/genproto v0.0.0-20210309190941-1aeedc14537d
|
||||
google.golang.org/grpc v1.36.0
|
||||
google.golang.org/protobuf v1.25.1-0.20200805231151-a709e31e5d12
|
||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect
|
||||
|
@ -264,8 +264,8 @@ github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpO
|
||||
github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
|
||||
github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
|
||||
github.com/imdario/mergo v0.3.6/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
|
||||
github.com/imdario/mergo v0.3.11 h1:3tnifQM4i+fbajXKBHXWEH+KvNHqojZ778UH75j3bGA=
|
||||
github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
|
||||
github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU=
|
||||
github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI=
|
||||
github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
|
||||
@ -459,8 +459,8 @@ golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8U
|
||||
golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY=
|
||||
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad h1:DN0cp81fZ3njFcrLCytUHRSUkqBjfTo4Tx9RJTWs0EY=
|
||||
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
|
||||
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83 h1:/ZScEX8SfEmUGRHs0gxpqteO5nfNW6axyZbBdw9A12g=
|
||||
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
|
||||
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
|
||||
@ -605,8 +605,9 @@ golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7w
|
||||
golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210228012217-479acdf4ea46 h1:V066+OYJ66oTjnhm4Yrn7SXIwSCiDQJxpBxmvqb1N1c=
|
||||
golang.org/x/sys v0.0.0-20210228012217-479acdf4ea46/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210309074719-68d13333faf2 h1:46ULzRKLh1CwgRq2dC5SlBzEqqNCi8rreOZnNrbqcIY=
|
||||
golang.org/x/sys v0.0.0-20210309074719-68d13333faf2/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
|
||||
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
@ -740,8 +741,8 @@ google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6D
|
||||
google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
|
||||
google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
|
||||
google.golang.org/genproto v0.0.0-20210114201628-6edceaf6022f/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
|
||||
google.golang.org/genproto v0.0.0-20210226172003-ab064af71705 h1:PYBmACG+YEv8uQPW0r1kJj8tR+gkF0UWq7iFdUezwEw=
|
||||
google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
|
||||
google.golang.org/genproto v0.0.0-20210309190941-1aeedc14537d h1:sWOBy5pWexdIILaM1hND+dymU2yY4yvDUbUTQJdek6Q=
|
||||
google.golang.org/genproto v0.0.0-20210309190941-1aeedc14537d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
|
||||
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
|
||||
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
|
||||
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"log"
|
||||
"net/http"
|
||||
|
||||
pb "github.com/go-kratos/examples/helloworld/helloworld"
|
||||
pb "github.com/go-kratos/kratos/examples/helloworld/helloworld"
|
||||
"github.com/go-kratos/kratos/v2/errors"
|
||||
"github.com/go-kratos/kratos/v2/middleware"
|
||||
"github.com/go-kratos/kratos/v2/middleware/recovery"
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"fmt"
|
||||
"os"
|
||||
|
||||
pb "github.com/go-kratos/examples/helloworld/helloworld"
|
||||
pb "github.com/go-kratos/kratos/examples/helloworld/helloworld"
|
||||
"github.com/go-kratos/kratos/v2"
|
||||
"github.com/go-kratos/kratos/v2/errors"
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"log"
|
||||
|
||||
consul "github.com/go-kratos/consul/registry"
|
||||
pb "github.com/go-kratos/examples/helloworld/helloworld"
|
||||
pb "github.com/go-kratos/kratos/examples/helloworld/helloworld"
|
||||
transgrpc "github.com/go-kratos/kratos/v2/transport/grpc"
|
||||
"github.com/hashicorp/consul/api"
|
||||
)
|
||||
|
@ -6,7 +6,7 @@ import (
|
||||
"os"
|
||||
|
||||
consul "github.com/go-kratos/consul/registry"
|
||||
pb "github.com/go-kratos/examples/helloworld/helloworld"
|
||||
pb "github.com/go-kratos/kratos/examples/helloworld/helloworld"
|
||||
"github.com/go-kratos/kratos/v2"
|
||||
"github.com/go-kratos/kratos/v2/log"
|
||||
"github.com/go-kratos/kratos/v2/transport/grpc"
|
||||
|
Loading…
Reference in New Issue
Block a user