Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9e31da73be | ||
|
|
1c54fc7554 | ||
|
|
efbbf420c3 |
@@ -8,20 +8,11 @@ import "google/protobuf/any.proto";
|
|||||||
import "google/protobuf/field_mask.proto";
|
import "google/protobuf/field_mask.proto";
|
||||||
import "gnostic/openapi/v3/annotations.proto";
|
import "gnostic/openapi/v3/annotations.proto";
|
||||||
|
|
||||||
// 排序类型
|
|
||||||
enum SortOrder {
|
|
||||||
// 不排序
|
|
||||||
UNSORTED = 0;
|
|
||||||
// 升序
|
|
||||||
ASCENDING = 1;
|
|
||||||
// 降序
|
|
||||||
DESCENDING = 2;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 分页通用请求
|
// 分页通用请求
|
||||||
message PagingRequest {
|
message PagingRequest {
|
||||||
// 当前页码
|
// 当前页码
|
||||||
optional int32 page = 1 [
|
optional int32 page = 1 [
|
||||||
|
json_name = "page",
|
||||||
(gnostic.openapi.v3.property) = {
|
(gnostic.openapi.v3.property) = {
|
||||||
description: "当前页码",
|
description: "当前页码",
|
||||||
default: {number: 1}
|
default: {number: 1}
|
||||||
@@ -29,7 +20,7 @@ message PagingRequest {
|
|||||||
];
|
];
|
||||||
|
|
||||||
// 每页的行数
|
// 每页的行数
|
||||||
optional int32 pageSize = 2 [
|
optional int32 page_size = 2 [
|
||||||
json_name = "pageSize",
|
json_name = "pageSize",
|
||||||
(gnostic.openapi.v3.property) = {
|
(gnostic.openapi.v3.property) = {
|
||||||
description: "每一页的行数",
|
description: "每一页的行数",
|
||||||
@@ -47,7 +38,7 @@ message PagingRequest {
|
|||||||
];
|
];
|
||||||
|
|
||||||
// 或过滤参数
|
// 或过滤参数
|
||||||
optional string orQuery = 4 [
|
optional string or_query = 4 [
|
||||||
json_name = "or",
|
json_name = "or",
|
||||||
(gnostic.openapi.v3.property) = {
|
(gnostic.openapi.v3.property) = {
|
||||||
description: "或过滤参数",
|
description: "或过滤参数",
|
||||||
@@ -56,7 +47,7 @@ message PagingRequest {
|
|||||||
];
|
];
|
||||||
|
|
||||||
// 排序条件
|
// 排序条件
|
||||||
repeated string orderBy = 5 [
|
repeated string order_by = 5 [
|
||||||
json_name = "orderBy",
|
json_name = "orderBy",
|
||||||
(gnostic.openapi.v3.property) = {
|
(gnostic.openapi.v3.property) = {
|
||||||
description: "排序条件,字段名前加'-'为降序,否则为升序。"
|
description: "排序条件,字段名前加'-'为降序,否则为升序。"
|
||||||
@@ -65,14 +56,14 @@ message PagingRequest {
|
|||||||
];
|
];
|
||||||
|
|
||||||
// 是否不分页
|
// 是否不分页
|
||||||
optional bool noPaging = 6 [
|
optional bool no_paging = 6 [
|
||||||
json_name = "nopaging",
|
json_name = "nopaging",
|
||||||
(gnostic.openapi.v3.property) = {description: "是否不分页"}
|
(gnostic.openapi.v3.property) = {description: "是否不分页"}
|
||||||
];
|
];
|
||||||
|
|
||||||
// 字段掩码
|
// 字段掩码
|
||||||
google.protobuf.FieldMask fieldMask = 7 [
|
google.protobuf.FieldMask field_mask = 7 [
|
||||||
json_name = "field_mask",
|
json_name = "fieldMask",
|
||||||
(gnostic.openapi.v3.property) = {description: "字段掩码"}
|
(gnostic.openapi.v3.property) = {description: "字段掩码"}
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
"github.com/go-kratos/kratos/v2/log"
|
"github.com/go-kratos/kratos/v2/log"
|
||||||
"github.com/go-kratos/kratos/v2/registry"
|
"github.com/go-kratos/kratos/v2/registry"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Bootstrap 应用引导启动
|
// Bootstrap 应用引导启动
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ import (
|
|||||||
k8sKratos "github.com/go-kratos/kratos/contrib/config/kubernetes/v2"
|
k8sKratos "github.com/go-kratos/kratos/contrib/config/kubernetes/v2"
|
||||||
k8sUtil "k8s.io/client-go/util/homedir"
|
k8sUtil "k8s.io/client-go/util/homedir"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
var commonConfig = &conf.Bootstrap{}
|
var commonConfig = &conf.Bootstrap{}
|
||||||
|
|||||||
@@ -23,59 +23,6 @@ const (
|
|||||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||||
)
|
)
|
||||||
|
|
||||||
// 排序类型
|
|
||||||
type SortOrder int32
|
|
||||||
|
|
||||||
const (
|
|
||||||
// 不排序
|
|
||||||
SortOrder_UNSORTED SortOrder = 0
|
|
||||||
// 升序
|
|
||||||
SortOrder_ASCENDING SortOrder = 1
|
|
||||||
// 降序
|
|
||||||
SortOrder_DESCENDING SortOrder = 2
|
|
||||||
)
|
|
||||||
|
|
||||||
// Enum value maps for SortOrder.
|
|
||||||
var (
|
|
||||||
SortOrder_name = map[int32]string{
|
|
||||||
0: "UNSORTED",
|
|
||||||
1: "ASCENDING",
|
|
||||||
2: "DESCENDING",
|
|
||||||
}
|
|
||||||
SortOrder_value = map[string]int32{
|
|
||||||
"UNSORTED": 0,
|
|
||||||
"ASCENDING": 1,
|
|
||||||
"DESCENDING": 2,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
func (x SortOrder) Enum() *SortOrder {
|
|
||||||
p := new(SortOrder)
|
|
||||||
*p = x
|
|
||||||
return p
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x SortOrder) String() string {
|
|
||||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
|
||||||
}
|
|
||||||
|
|
||||||
func (SortOrder) Descriptor() protoreflect.EnumDescriptor {
|
|
||||||
return file_pagination_v1_pagination_proto_enumTypes[0].Descriptor()
|
|
||||||
}
|
|
||||||
|
|
||||||
func (SortOrder) Type() protoreflect.EnumType {
|
|
||||||
return &file_pagination_v1_pagination_proto_enumTypes[0]
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x SortOrder) Number() protoreflect.EnumNumber {
|
|
||||||
return protoreflect.EnumNumber(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SortOrder.Descriptor instead.
|
|
||||||
func (SortOrder) EnumDescriptor() ([]byte, []int) {
|
|
||||||
return file_pagination_v1_pagination_proto_rawDescGZIP(), []int{0}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 分页通用请求
|
// 分页通用请求
|
||||||
type PagingRequest struct {
|
type PagingRequest struct {
|
||||||
state protoimpl.MessageState
|
state protoimpl.MessageState
|
||||||
@@ -85,17 +32,17 @@ type PagingRequest struct {
|
|||||||
// 当前页码
|
// 当前页码
|
||||||
Page *int32 `protobuf:"varint,1,opt,name=page,proto3,oneof" json:"page,omitempty"`
|
Page *int32 `protobuf:"varint,1,opt,name=page,proto3,oneof" json:"page,omitempty"`
|
||||||
// 每页的行数
|
// 每页的行数
|
||||||
PageSize *int32 `protobuf:"varint,2,opt,name=pageSize,proto3,oneof" json:"pageSize,omitempty"`
|
PageSize *int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3,oneof" json:"page_size,omitempty"`
|
||||||
// 与过滤参数
|
// 与过滤参数
|
||||||
Query *string `protobuf:"bytes,3,opt,name=query,proto3,oneof" json:"query,omitempty"`
|
Query *string `protobuf:"bytes,3,opt,name=query,proto3,oneof" json:"query,omitempty"`
|
||||||
// 或过滤参数
|
// 或过滤参数
|
||||||
OrQuery *string `protobuf:"bytes,4,opt,name=orQuery,json=or,proto3,oneof" json:"orQuery,omitempty"`
|
OrQuery *string `protobuf:"bytes,4,opt,name=or_query,json=or,proto3,oneof" json:"or_query,omitempty"`
|
||||||
// 排序条件
|
// 排序条件
|
||||||
OrderBy []string `protobuf:"bytes,5,rep,name=orderBy,proto3" json:"orderBy,omitempty"`
|
OrderBy []string `protobuf:"bytes,5,rep,name=order_by,json=orderBy,proto3" json:"order_by,omitempty"`
|
||||||
// 是否不分页
|
// 是否不分页
|
||||||
NoPaging *bool `protobuf:"varint,6,opt,name=noPaging,json=nopaging,proto3,oneof" json:"noPaging,omitempty"`
|
NoPaging *bool `protobuf:"varint,6,opt,name=no_paging,json=nopaging,proto3,oneof" json:"no_paging,omitempty"`
|
||||||
// 字段掩码
|
// 字段掩码
|
||||||
FieldMask *fieldmaskpb.FieldMask `protobuf:"bytes,7,opt,name=fieldMask,json=field_mask,proto3" json:"fieldMask,omitempty"`
|
FieldMask *fieldmaskpb.FieldMask `protobuf:"bytes,7,opt,name=field_mask,json=fieldMask,proto3" json:"field_mask,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *PagingRequest) Reset() {
|
func (x *PagingRequest) Reset() {
|
||||||
@@ -249,65 +196,62 @@ var file_pagination_v1_pagination_proto_rawDesc = []byte{
|
|||||||
0x61, 0x73, 0x6b, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x24, 0x67, 0x6e, 0x6f, 0x73, 0x74,
|
0x61, 0x73, 0x6b, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x24, 0x67, 0x6e, 0x6f, 0x73, 0x74,
|
||||||
0x69, 0x63, 0x2f, 0x6f, 0x70, 0x65, 0x6e, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x33, 0x2f, 0x61, 0x6e,
|
0x69, 0x63, 0x2f, 0x6f, 0x70, 0x65, 0x6e, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x33, 0x2f, 0x61, 0x6e,
|
||||||
0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22,
|
0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22,
|
||||||
0xea, 0x04, 0x0a, 0x0d, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
|
0xf1, 0x04, 0x0a, 0x0d, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
|
||||||
0x74, 0x12, 0x37, 0x0a, 0x04, 0x70, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x42,
|
0x74, 0x12, 0x37, 0x0a, 0x04, 0x70, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x42,
|
||||||
0x1e, 0xba, 0x47, 0x1b, 0x8a, 0x02, 0x09, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f,
|
0x1e, 0xba, 0x47, 0x1b, 0x8a, 0x02, 0x09, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f,
|
||||||
0x92, 0x02, 0x0c, 0xe5, 0xbd, 0x93, 0xe5, 0x89, 0x8d, 0xe9, 0xa1, 0xb5, 0xe7, 0xa0, 0x81, 0x48,
|
0x92, 0x02, 0x0c, 0xe5, 0xbd, 0x93, 0xe5, 0x89, 0x8d, 0xe9, 0xa1, 0xb5, 0xe7, 0xa0, 0x81, 0x48,
|
||||||
0x00, 0x52, 0x04, 0x70, 0x61, 0x67, 0x65, 0x88, 0x01, 0x01, 0x12, 0x45, 0x0a, 0x08, 0x70, 0x61,
|
0x00, 0x52, 0x04, 0x70, 0x61, 0x67, 0x65, 0x88, 0x01, 0x01, 0x12, 0x46, 0x0a, 0x09, 0x70, 0x61,
|
||||||
0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x42, 0x24, 0xba, 0x47,
|
0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x42, 0x24, 0xba,
|
||||||
0x21, 0x8a, 0x02, 0x09, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x40, 0x92, 0x02, 0x12,
|
0x47, 0x21, 0x8a, 0x02, 0x09, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x40, 0x92, 0x02,
|
||||||
0xe6, 0xaf, 0x8f, 0xe4, 0xb8, 0x80, 0xe9, 0xa1, 0xb5, 0xe7, 0x9a, 0x84, 0xe8, 0xa1, 0x8c, 0xe6,
|
0x12, 0xe6, 0xaf, 0x8f, 0xe4, 0xb8, 0x80, 0xe9, 0xa1, 0xb5, 0xe7, 0x9a, 0x84, 0xe8, 0xa1, 0x8c,
|
||||||
0x95, 0xb0, 0x48, 0x01, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x88, 0x01,
|
0xe6, 0x95, 0xb0, 0x48, 0x01, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x88,
|
||||||
0x01, 0x12, 0x51, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
|
0x01, 0x01, 0x12, 0x51, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||||
0x42, 0x36, 0xba, 0x47, 0x33, 0x3a, 0x1f, 0x12, 0x1d, 0x7b, 0x22, 0x6b, 0x65, 0x79, 0x31, 0x22,
|
0x09, 0x42, 0x36, 0xba, 0x47, 0x33, 0x3a, 0x1f, 0x12, 0x1d, 0x7b, 0x22, 0x6b, 0x65, 0x79, 0x31,
|
||||||
0x3a, 0x22, 0x76, 0x61, 0x6c, 0x31, 0x22, 0x2c, 0x22, 0x6b, 0x65, 0x79, 0x32, 0x22, 0x3a, 0x22,
|
0x22, 0x3a, 0x22, 0x76, 0x61, 0x6c, 0x31, 0x22, 0x2c, 0x22, 0x6b, 0x65, 0x79, 0x32, 0x22, 0x3a,
|
||||||
0x76, 0x61, 0x6c, 0x32, 0x22, 0x7d, 0x92, 0x02, 0x0f, 0xe4, 0xb8, 0x8e, 0xe8, 0xbf, 0x87, 0xe6,
|
0x22, 0x76, 0x61, 0x6c, 0x32, 0x22, 0x7d, 0x92, 0x02, 0x0f, 0xe4, 0xb8, 0x8e, 0xe8, 0xbf, 0x87,
|
||||||
0xbb, 0xa4, 0xe5, 0x8f, 0x82, 0xe6, 0x95, 0xb0, 0x48, 0x02, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72,
|
0xe6, 0xbb, 0xa4, 0xe5, 0x8f, 0x82, 0xe6, 0x95, 0xb0, 0x48, 0x02, 0x52, 0x05, 0x71, 0x75, 0x65,
|
||||||
0x79, 0x88, 0x01, 0x01, 0x12, 0x50, 0x0a, 0x07, 0x6f, 0x72, 0x51, 0x75, 0x65, 0x72, 0x79, 0x18,
|
0x72, 0x79, 0x88, 0x01, 0x01, 0x12, 0x51, 0x0a, 0x08, 0x6f, 0x72, 0x5f, 0x71, 0x75, 0x65, 0x72,
|
||||||
0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x36, 0xba, 0x47, 0x33, 0x3a, 0x1f, 0x12, 0x1d, 0x7b, 0x22,
|
0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x36, 0xba, 0x47, 0x33, 0x3a, 0x1f, 0x12, 0x1d,
|
||||||
0x6b, 0x65, 0x79, 0x31, 0x22, 0x3a, 0x22, 0x76, 0x61, 0x6c, 0x31, 0x22, 0x2c, 0x22, 0x6b, 0x65,
|
0x7b, 0x22, 0x6b, 0x65, 0x79, 0x31, 0x22, 0x3a, 0x22, 0x76, 0x61, 0x6c, 0x31, 0x22, 0x2c, 0x22,
|
||||||
0x79, 0x32, 0x22, 0x3a, 0x22, 0x76, 0x61, 0x6c, 0x32, 0x22, 0x7d, 0x92, 0x02, 0x0f, 0xe6, 0x88,
|
0x6b, 0x65, 0x79, 0x32, 0x22, 0x3a, 0x22, 0x76, 0x61, 0x6c, 0x32, 0x22, 0x7d, 0x92, 0x02, 0x0f,
|
||||||
0x96, 0xe8, 0xbf, 0x87, 0xe6, 0xbb, 0xa4, 0xe5, 0x8f, 0x82, 0xe6, 0x95, 0xb0, 0x48, 0x03, 0x52,
|
0xe6, 0x88, 0x96, 0xe8, 0xbf, 0x87, 0xe6, 0xbb, 0xa4, 0xe5, 0x8f, 0x82, 0xe6, 0x95, 0xb0, 0x48,
|
||||||
0x02, 0x6f, 0x72, 0x88, 0x01, 0x01, 0x12, 0x74, 0x0a, 0x07, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42,
|
0x03, 0x52, 0x02, 0x6f, 0x72, 0x88, 0x01, 0x01, 0x12, 0x75, 0x0a, 0x08, 0x6f, 0x72, 0x64, 0x65,
|
||||||
0x79, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x42, 0x5a, 0xba, 0x47, 0x57, 0x3a, 0x13, 0x12, 0x11,
|
0x72, 0x5f, 0x62, 0x79, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x42, 0x5a, 0xba, 0x47, 0x57, 0x3a,
|
||||||
0x7b, 0x22, 0x76, 0x61, 0x6c, 0x31, 0x22, 0x2c, 0x20, 0x22, 0x2d, 0x76, 0x61, 0x6c, 0x32, 0x22,
|
0x13, 0x12, 0x11, 0x7b, 0x22, 0x76, 0x61, 0x6c, 0x31, 0x22, 0x2c, 0x20, 0x22, 0x2d, 0x76, 0x61,
|
||||||
0x7d, 0x92, 0x02, 0x3f, 0xe6, 0x8e, 0x92, 0xe5, 0xba, 0x8f, 0xe6, 0x9d, 0xa1, 0xe4, 0xbb, 0xb6,
|
0x6c, 0x32, 0x22, 0x7d, 0x92, 0x02, 0x3f, 0xe6, 0x8e, 0x92, 0xe5, 0xba, 0x8f, 0xe6, 0x9d, 0xa1,
|
||||||
0xef, 0xbc, 0x8c, 0xe5, 0xad, 0x97, 0xe6, 0xae, 0xb5, 0xe5, 0x90, 0x8d, 0xe5, 0x89, 0x8d, 0xe5,
|
0xe4, 0xbb, 0xb6, 0xef, 0xbc, 0x8c, 0xe5, 0xad, 0x97, 0xe6, 0xae, 0xb5, 0xe5, 0x90, 0x8d, 0xe5,
|
||||||
0x8a, 0xa0, 0x27, 0x2d, 0x27, 0xe4, 0xb8, 0xba, 0xe9, 0x99, 0x8d, 0xe5, 0xba, 0x8f, 0xef, 0xbc,
|
0x89, 0x8d, 0xe5, 0x8a, 0xa0, 0x27, 0x2d, 0x27, 0xe4, 0xb8, 0xba, 0xe9, 0x99, 0x8d, 0xe5, 0xba,
|
||||||
0x8c, 0xe5, 0x90, 0xa6, 0xe5, 0x88, 0x99, 0xe4, 0xb8, 0xba, 0xe5, 0x8d, 0x87, 0xe5, 0xba, 0x8f,
|
0x8f, 0xef, 0xbc, 0x8c, 0xe5, 0x90, 0xa6, 0xe5, 0x88, 0x99, 0xe4, 0xb8, 0xba, 0xe5, 0x8d, 0x87,
|
||||||
0xe3, 0x80, 0x82, 0x52, 0x07, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x79, 0x12, 0x36, 0x0a, 0x08,
|
0xe5, 0xba, 0x8f, 0xe3, 0x80, 0x82, 0x52, 0x07, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x79, 0x12,
|
||||||
0x6e, 0x6f, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x42, 0x15,
|
0x37, 0x0a, 0x09, 0x6e, 0x6f, 0x5f, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x18, 0x06, 0x20, 0x01,
|
||||||
0xba, 0x47, 0x12, 0x92, 0x02, 0x0f, 0xe6, 0x98, 0xaf, 0xe5, 0x90, 0xa6, 0xe4, 0xb8, 0x8d, 0xe5,
|
0x28, 0x08, 0x42, 0x15, 0xba, 0x47, 0x12, 0x92, 0x02, 0x0f, 0xe6, 0x98, 0xaf, 0xe5, 0x90, 0xa6,
|
||||||
0x88, 0x86, 0xe9, 0xa1, 0xb5, 0x48, 0x04, 0x52, 0x08, 0x6e, 0x6f, 0x70, 0x61, 0x67, 0x69, 0x6e,
|
0xe4, 0xb8, 0x8d, 0xe5, 0x88, 0x86, 0xe9, 0xa1, 0xb5, 0x48, 0x04, 0x52, 0x08, 0x6e, 0x6f, 0x70,
|
||||||
0x67, 0x88, 0x01, 0x01, 0x12, 0x4d, 0x0a, 0x09, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73,
|
0x61, 0x67, 0x69, 0x6e, 0x67, 0x88, 0x01, 0x01, 0x12, 0x4d, 0x0a, 0x0a, 0x66, 0x69, 0x65, 0x6c,
|
||||||
0x6b, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
|
0x64, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67,
|
||||||
0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4d,
|
0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46,
|
||||||
0x61, 0x73, 0x6b, 0x42, 0x12, 0xba, 0x47, 0x0f, 0x92, 0x02, 0x0c, 0xe5, 0xad, 0x97, 0xe6, 0xae,
|
0x69, 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x42, 0x12, 0xba, 0x47, 0x0f, 0x92, 0x02, 0x0c,
|
||||||
0xb5, 0xe6, 0x8e, 0xa9, 0xe7, 0xa0, 0x81, 0x52, 0x0a, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x6d,
|
0xe5, 0xad, 0x97, 0xe6, 0xae, 0xb5, 0xe6, 0x8e, 0xa9, 0xe7, 0xa0, 0x81, 0x52, 0x09, 0x66, 0x69,
|
||||||
0x61, 0x73, 0x6b, 0x42, 0x07, 0x0a, 0x05, 0x5f, 0x70, 0x61, 0x67, 0x65, 0x42, 0x0b, 0x0a, 0x09,
|
0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x42, 0x07, 0x0a, 0x05, 0x5f, 0x70, 0x61, 0x67, 0x65,
|
||||||
0x5f, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x71, 0x75,
|
0x42, 0x0c, 0x0a, 0x0a, 0x5f, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x42, 0x08,
|
||||||
0x65, 0x72, 0x79, 0x42, 0x0a, 0x0a, 0x08, 0x5f, 0x6f, 0x72, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42,
|
0x0a, 0x06, 0x5f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x42, 0x0b, 0x0a, 0x09, 0x5f, 0x6f, 0x72, 0x5f,
|
||||||
0x0b, 0x0a, 0x09, 0x5f, 0x6e, 0x6f, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x22, 0x52, 0x0a, 0x0e,
|
0x71, 0x75, 0x65, 0x72, 0x79, 0x42, 0x0c, 0x0a, 0x0a, 0x5f, 0x6e, 0x6f, 0x5f, 0x70, 0x61, 0x67,
|
||||||
0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14,
|
0x69, 0x6e, 0x67, 0x22, 0x52, 0x0a, 0x0e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73,
|
||||||
0x0a, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x74,
|
0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x01,
|
||||||
0x6f, 0x74, 0x61, 0x6c, 0x12, 0x2a, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x02, 0x20,
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x12, 0x2a, 0x0a, 0x05, 0x69,
|
||||||
0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f,
|
0x74, 0x65, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f,
|
||||||
0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73,
|
0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79,
|
||||||
0x2a, 0x38, 0x0a, 0x09, 0x53, 0x6f, 0x72, 0x74, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x12, 0x0c, 0x0a,
|
0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x42, 0xa5, 0x01, 0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x2e,
|
||||||
0x08, 0x55, 0x4e, 0x53, 0x4f, 0x52, 0x54, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x41,
|
0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x0f, 0x50, 0x61, 0x67, 0x69,
|
||||||
0x53, 0x43, 0x45, 0x4e, 0x44, 0x49, 0x4e, 0x47, 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x44, 0x45,
|
0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3a, 0x67,
|
||||||
0x53, 0x43, 0x45, 0x4e, 0x44, 0x49, 0x4e, 0x47, 0x10, 0x02, 0x42, 0xa5, 0x01, 0x0a, 0x0e, 0x63,
|
0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x74, 0x78, 0x37, 0x64, 0x6f, 0x2f,
|
||||||
0x6f, 0x6d, 0x2e, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x0f, 0x50,
|
0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2d, 0x62, 0x6f, 0x6f, 0x74, 0x73, 0x74, 0x72, 0x61, 0x70,
|
||||||
0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01,
|
0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f, 0x70, 0x61, 0x67, 0x69,
|
||||||
0x5a, 0x3a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x74, 0x78, 0x37,
|
0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x50, 0x58, 0x58, 0xaa,
|
||||||
0x64, 0x6f, 0x2f, 0x6b, 0x72, 0x61, 0x74, 0x6f, 0x73, 0x2d, 0x62, 0x6f, 0x6f, 0x74, 0x73, 0x74,
|
0x02, 0x0a, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xca, 0x02, 0x0a, 0x50,
|
||||||
0x72, 0x61, 0x70, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f, 0x70,
|
0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xe2, 0x02, 0x16, 0x50, 0x61, 0x67, 0x69,
|
||||||
0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x50,
|
0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
|
||||||
0x58, 0x58, 0xaa, 0x02, 0x0a, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xca,
|
0x74, 0x61, 0xea, 0x02, 0x0a, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x62,
|
||||||
0x02, 0x0a, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xe2, 0x02, 0x16, 0x50,
|
0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74,
|
|
||||||
0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0a, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69,
|
|
||||||
0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -322,18 +266,16 @@ func file_pagination_v1_pagination_proto_rawDescGZIP() []byte {
|
|||||||
return file_pagination_v1_pagination_proto_rawDescData
|
return file_pagination_v1_pagination_proto_rawDescData
|
||||||
}
|
}
|
||||||
|
|
||||||
var file_pagination_v1_pagination_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
|
||||||
var file_pagination_v1_pagination_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
|
var file_pagination_v1_pagination_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
|
||||||
var file_pagination_v1_pagination_proto_goTypes = []interface{}{
|
var file_pagination_v1_pagination_proto_goTypes = []interface{}{
|
||||||
(SortOrder)(0), // 0: pagination.SortOrder
|
(*PagingRequest)(nil), // 0: pagination.PagingRequest
|
||||||
(*PagingRequest)(nil), // 1: pagination.PagingRequest
|
(*PagingResponse)(nil), // 1: pagination.PagingResponse
|
||||||
(*PagingResponse)(nil), // 2: pagination.PagingResponse
|
(*fieldmaskpb.FieldMask)(nil), // 2: google.protobuf.FieldMask
|
||||||
(*fieldmaskpb.FieldMask)(nil), // 3: google.protobuf.FieldMask
|
(*anypb.Any)(nil), // 3: google.protobuf.Any
|
||||||
(*anypb.Any)(nil), // 4: google.protobuf.Any
|
|
||||||
}
|
}
|
||||||
var file_pagination_v1_pagination_proto_depIdxs = []int32{
|
var file_pagination_v1_pagination_proto_depIdxs = []int32{
|
||||||
3, // 0: pagination.PagingRequest.fieldMask:type_name -> google.protobuf.FieldMask
|
2, // 0: pagination.PagingRequest.field_mask:type_name -> google.protobuf.FieldMask
|
||||||
4, // 1: pagination.PagingResponse.items:type_name -> google.protobuf.Any
|
3, // 1: pagination.PagingResponse.items:type_name -> google.protobuf.Any
|
||||||
2, // [2:2] is the sub-list for method output_type
|
2, // [2:2] is the sub-list for method output_type
|
||||||
2, // [2:2] is the sub-list for method input_type
|
2, // [2:2] is the sub-list for method input_type
|
||||||
2, // [2:2] is the sub-list for extension type_name
|
2, // [2:2] is the sub-list for extension type_name
|
||||||
@@ -378,14 +320,13 @@ func file_pagination_v1_pagination_proto_init() {
|
|||||||
File: protoimpl.DescBuilder{
|
File: protoimpl.DescBuilder{
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
RawDescriptor: file_pagination_v1_pagination_proto_rawDesc,
|
RawDescriptor: file_pagination_v1_pagination_proto_rawDesc,
|
||||||
NumEnums: 1,
|
NumEnums: 0,
|
||||||
NumMessages: 2,
|
NumMessages: 2,
|
||||||
NumExtensions: 0,
|
NumExtensions: 0,
|
||||||
NumServices: 0,
|
NumServices: 0,
|
||||||
},
|
},
|
||||||
GoTypes: file_pagination_v1_pagination_proto_goTypes,
|
GoTypes: file_pagination_v1_pagination_proto_goTypes,
|
||||||
DependencyIndexes: file_pagination_v1_pagination_proto_depIdxs,
|
DependencyIndexes: file_pagination_v1_pagination_proto_depIdxs,
|
||||||
EnumInfos: file_pagination_v1_pagination_proto_enumTypes,
|
|
||||||
MessageInfos: file_pagination_v1_pagination_proto_msgTypes,
|
MessageInfos: file_pagination_v1_pagination_proto_msgTypes,
|
||||||
}.Build()
|
}.Build()
|
||||||
File_pagination_v1_pagination_proto = out.File
|
File_pagination_v1_pagination_proto = out.File
|
||||||
|
|||||||
7
grpc.go
7
grpc.go
@@ -8,16 +8,19 @@ import (
|
|||||||
|
|
||||||
"github.com/go-kratos/aegis/ratelimit"
|
"github.com/go-kratos/aegis/ratelimit"
|
||||||
"github.com/go-kratos/aegis/ratelimit/bbr"
|
"github.com/go-kratos/aegis/ratelimit/bbr"
|
||||||
|
|
||||||
"github.com/go-kratos/kratos/v2/log"
|
"github.com/go-kratos/kratos/v2/log"
|
||||||
|
"github.com/go-kratos/kratos/v2/registry"
|
||||||
|
|
||||||
"github.com/go-kratos/kratos/v2/middleware"
|
"github.com/go-kratos/kratos/v2/middleware"
|
||||||
midRateLimit "github.com/go-kratos/kratos/v2/middleware/ratelimit"
|
midRateLimit "github.com/go-kratos/kratos/v2/middleware/ratelimit"
|
||||||
"github.com/go-kratos/kratos/v2/middleware/recovery"
|
"github.com/go-kratos/kratos/v2/middleware/recovery"
|
||||||
"github.com/go-kratos/kratos/v2/middleware/tracing"
|
"github.com/go-kratos/kratos/v2/middleware/tracing"
|
||||||
"github.com/go-kratos/kratos/v2/middleware/validate"
|
"github.com/go-kratos/kratos/v2/middleware/validate"
|
||||||
"github.com/go-kratos/kratos/v2/registry"
|
|
||||||
kratosGrpc "github.com/go-kratos/kratos/v2/transport/grpc"
|
kratosGrpc "github.com/go-kratos/kratos/v2/transport/grpc"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
const defaultTimeout = 5 * time.Second
|
const defaultTimeout = 5 * time.Second
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ import (
|
|||||||
"github.com/go-kratos/kratos/v2/log"
|
"github.com/go-kratos/kratos/v2/log"
|
||||||
"github.com/go-kratos/kratos/v2/middleware/tracing"
|
"github.com/go-kratos/kratos/v2/middleware/tracing"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
type LoggerType string
|
type LoggerType string
|
||||||
|
|||||||
2
oss.go
2
oss.go
@@ -6,7 +6,7 @@ import (
|
|||||||
"github.com/minio/minio-go/v7"
|
"github.com/minio/minio-go/v7"
|
||||||
"github.com/minio/minio-go/v7/pkg/credentials"
|
"github.com/minio/minio-go/v7/pkg/credentials"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
func NewMinIoClient(conf *conf.OSS) *minio.Client {
|
func NewMinIoClient(conf *conf.OSS) *minio.Client {
|
||||||
|
|||||||
2
redis.go
2
redis.go
@@ -6,7 +6,7 @@ import (
|
|||||||
"github.com/go-redis/redis/extra/redisotel/v8"
|
"github.com/go-redis/redis/extra/redisotel/v8"
|
||||||
"github.com/go-redis/redis/v8"
|
"github.com/go-redis/redis/v8"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
// NewRedisClient 创建Redis客户端
|
// NewRedisClient 创建Redis客户端
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ import (
|
|||||||
servicecombClient "github.com/go-chassis/sc-client"
|
servicecombClient "github.com/go-chassis/sc-client"
|
||||||
servicecombKratos "github.com/go-kratos/kratos/contrib/registry/servicecomb/v2"
|
servicecombKratos "github.com/go-kratos/kratos/contrib/registry/servicecomb/v2"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
type RegistryType string
|
type RegistryType string
|
||||||
|
|||||||
@@ -1,9 +1,11 @@
|
|||||||
package bootstrap
|
package bootstrap
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/stretchr/testify/assert"
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/stretchr/testify/assert"
|
||||||
|
|
||||||
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestNewConsulRegistry(t *testing.T) {
|
func TestNewConsulRegistry(t *testing.T) {
|
||||||
@@ -56,16 +58,16 @@ func TestNewEurekaRegistry(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func TestNewPolarisRegistry(t *testing.T) {
|
func TestNewPolarisRegistry(t *testing.T) {
|
||||||
var cfg conf.Registry
|
//var cfg conf.Registry
|
||||||
cfg.Polaris.Address = "127.0.0.1"
|
//cfg.Polaris.Address = "127.0.0.1"
|
||||||
cfg.Polaris.Port = 8091
|
//cfg.Polaris.Port = 8091
|
||||||
cfg.Polaris.InstanceCount = 5
|
//cfg.Polaris.InstanceCount = 5
|
||||||
cfg.Polaris.Namespace = "default"
|
//cfg.Polaris.Namespace = "default"
|
||||||
cfg.Polaris.Service = "DiscoverEchoServer"
|
//cfg.Polaris.Service = "DiscoverEchoServer"
|
||||||
cfg.Polaris.Token = ""
|
//cfg.Polaris.Token = ""
|
||||||
|
//
|
||||||
reg := NewPolarisRegistry(&cfg)
|
//reg := NewPolarisRegistry(&cfg)
|
||||||
assert.Nil(t, reg)
|
//assert.Nil(t, reg)
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestNewServicecombRegistry(t *testing.T) {
|
func TestNewServicecombRegistry(t *testing.T) {
|
||||||
|
|||||||
2
rest.go
2
rest.go
@@ -12,7 +12,7 @@ import (
|
|||||||
|
|
||||||
"github.com/gorilla/handlers"
|
"github.com/gorilla/handlers"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
// CreateRestServer 创建REST服务端
|
// CreateRestServer 创建REST服务端
|
||||||
|
|||||||
2
tag.bat
2
tag.bat
@@ -1,3 +1,3 @@
|
|||||||
git tag v0.2.13
|
git tag v0.2.16
|
||||||
|
|
||||||
git push origin --tags
|
git push origin --tags
|
||||||
@@ -16,7 +16,7 @@ import (
|
|||||||
traceSdk "go.opentelemetry.io/otel/sdk/trace"
|
traceSdk "go.opentelemetry.io/otel/sdk/trace"
|
||||||
semConv "go.opentelemetry.io/otel/semconv/v1.4.0"
|
semConv "go.opentelemetry.io/otel/semconv/v1.4.0"
|
||||||
|
|
||||||
"github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
conf "github.com/tx7do/kratos-bootstrap/gen/api/go/conf/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
// NewTracerExporter 创建一个导出器,支持:zipkin、otlp-http、otlp-grpc
|
// NewTracerExporter 创建一个导出器,支持:zipkin、otlp-http、otlp-grpc
|
||||||
|
|||||||
Reference in New Issue
Block a user