Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterServiceServer(s grpc.ServiceRegistrar, srv ServiceServer)
- type CreateOperatorRequest
- func (*CreateOperatorRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateOperatorRequest) GetAction() string
- func (x *CreateOperatorRequest) GetCreateBy() string
- func (x *CreateOperatorRequest) GetMeta() map[string]string
- func (x *CreateOperatorRequest) GetNamespace() string
- func (x *CreateOperatorRequest) GetPath() string
- func (x *CreateOperatorRequest) GetRemoteIp() string
- func (x *CreateOperatorRequest) GetResource() string
- func (x *CreateOperatorRequest) GetService() string
- func (x *CreateOperatorRequest) GetUserAgent() string
- func (*CreateOperatorRequest) ProtoMessage()
- func (x *CreateOperatorRequest) ProtoReflect() protoreflect.Message
- func (x *CreateOperatorRequest) Reset()
- func (x *CreateOperatorRequest) String() string
- type OperatorLog
- func (*OperatorLog) Descriptor() ([]byte, []int)deprecated
- func (x *OperatorLog) GetCreateAt() int64
- func (x *OperatorLog) GetSpec() *CreateOperatorRequest
- func (*OperatorLog) ProtoMessage()
- func (x *OperatorLog) ProtoReflect() protoreflect.Message
- func (x *OperatorLog) Reset()
- func (x *OperatorLog) String() string
- type OperatorResponse
- func (*OperatorResponse) Descriptor() ([]byte, []int)deprecated
- func (x *OperatorResponse) GetDescription() string
- func (x *OperatorResponse) GetRoleName() string
- func (*OperatorResponse) ProtoMessage()
- func (x *OperatorResponse) ProtoReflect() protoreflect.Message
- func (x *OperatorResponse) Reset()
- func (x *OperatorResponse) String() string
- type OperatorSet
- func (s *OperatorSet) Add(req *OperatorLog)
- func (*OperatorSet) Descriptor() ([]byte, []int)deprecated
- func (x *OperatorSet) GetItems() []*OperatorLog
- func (x *OperatorSet) GetTotal() int64
- func (*OperatorSet) ProtoMessage()
- func (x *OperatorSet) ProtoReflect() protoreflect.Message
- func (x *OperatorSet) Reset()
- func (x *OperatorSet) String() string
- type QueryOperatorRequest
- func (*QueryOperatorRequest) Descriptor() ([]byte, []int)deprecated
- func (x *QueryOperatorRequest) GetPage() *request.PageRequest
- func (x *QueryOperatorRequest) GetUserName() string
- func (*QueryOperatorRequest) ProtoMessage()
- func (x *QueryOperatorRequest) ProtoReflect() protoreflect.Message
- func (x *QueryOperatorRequest) Reset()
- func (x *QueryOperatorRequest) String() string
- type Service
- type ServiceClient
- type ServiceServer
- type UnimplementedServiceServer
- type UnsafeServiceServer
Constants ¶
const (
AppName = "audit"
)
Variables ¶
var File_apps_audit_pb_audit_proto protoreflect.FileDescriptor
var Service_ServiceDesc = grpc.ServiceDesc{ ServiceName: "keyauth.audit.Service", HandlerType: (*ServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "OperatorLog", Handler: _Service_OperatorLog_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "apps/audit/pb/audit.proto", }
Service_ServiceDesc is the grpc.ServiceDesc for Service service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterServiceServer ¶
func RegisterServiceServer(s grpc.ServiceRegistrar, srv ServiceServer)
Types ¶
type CreateOperatorRequest ¶
type CreateOperatorRequest struct { // @gotags: json:"user_name" bson:"user_name" CreateBy string `protobuf:"bytes,2,opt,name=create_by,json=createBy,proto3" json:"user_name" bson:"user_name"` // @gotags: json:"action" bson:"action" Action string `protobuf:"bytes,3,opt,name=action,proto3" json:"action" bson:"action"` // @gotags: json:"resource" bson:"resource" Resource string `protobuf:"bytes,4,opt,name=resource,proto3" json:"resource" bson:"resource"` // @gotags: json:"service" bson:"service" Service string `protobuf:"bytes,5,opt,name=service,proto3" json:"service" bson:"service"` // @gotags: json:"path" bson:"path" Path string `protobuf:"bytes,8,opt,name=path,proto3" json:"path" bson:"path"` // @gotags: json:"namespace" bson:"namespace" Namespace string `protobuf:"bytes,9,opt,name=namespace,proto3" json:"namespace" bson:"namespace"` // @gotags: json:"user_agent" bson:"user_agent" UserAgent string `protobuf:"bytes,10,opt,name=user_agent,json=userAgent,proto3" json:"user_agent" bson:"user_agent"` // @gotags: json:"remote_ip" bson:"remote_ip" RemoteIp string `protobuf:"bytes,11,opt,name=remote_ip,json=remoteIp,proto3" json:"remote_ip" bson:"remote_ip"` // @gotags: json:"meta" bson:"meta" Meta map[string]string `` /* 152-byte string literal not displayed */ // contains filtered or unexported fields }
func NewCreateOperatorRequest ¶
func NewCreateOperatorRequest() *CreateOperatorRequest
func (*CreateOperatorRequest) Descriptor
deprecated
func (*CreateOperatorRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateOperatorRequest.ProtoReflect.Descriptor instead.
func (*CreateOperatorRequest) GetAction ¶
func (x *CreateOperatorRequest) GetAction() string
func (*CreateOperatorRequest) GetCreateBy ¶
func (x *CreateOperatorRequest) GetCreateBy() string
func (*CreateOperatorRequest) GetMeta ¶
func (x *CreateOperatorRequest) GetMeta() map[string]string
func (*CreateOperatorRequest) GetNamespace ¶
func (x *CreateOperatorRequest) GetNamespace() string
func (*CreateOperatorRequest) GetPath ¶
func (x *CreateOperatorRequest) GetPath() string
func (*CreateOperatorRequest) GetRemoteIp ¶
func (x *CreateOperatorRequest) GetRemoteIp() string
func (*CreateOperatorRequest) GetResource ¶
func (x *CreateOperatorRequest) GetResource() string
func (*CreateOperatorRequest) GetService ¶
func (x *CreateOperatorRequest) GetService() string
func (*CreateOperatorRequest) GetUserAgent ¶
func (x *CreateOperatorRequest) GetUserAgent() string
func (*CreateOperatorRequest) ProtoMessage ¶
func (*CreateOperatorRequest) ProtoMessage()
func (*CreateOperatorRequest) ProtoReflect ¶
func (x *CreateOperatorRequest) ProtoReflect() protoreflect.Message
func (*CreateOperatorRequest) Reset ¶
func (x *CreateOperatorRequest) Reset()
func (*CreateOperatorRequest) String ¶
func (x *CreateOperatorRequest) String() string
type OperatorLog ¶
type OperatorLog struct { // @gotags: json:"create_at" bson:"create_at" CreateAt int64 `protobuf:"varint,1,opt,name=create_at,json=createAt,proto3" json:"create_at" bson:"create_at"` // @gotags: json:"spec" bson:"spec" Spec *CreateOperatorRequest `protobuf:"bytes,2,opt,name=spec,proto3" json:"spec" bson:"spec"` // contains filtered or unexported fields }
func NewDefaultOperatorLog ¶
func NewDefaultOperatorLog() *OperatorLog
func NewOperatorLog ¶
func NewOperatorLog(req *CreateOperatorRequest) *OperatorLog
func (*OperatorLog) Descriptor
deprecated
func (*OperatorLog) Descriptor() ([]byte, []int)
Deprecated: Use OperatorLog.ProtoReflect.Descriptor instead.
func (*OperatorLog) GetCreateAt ¶
func (x *OperatorLog) GetCreateAt() int64
func (*OperatorLog) GetSpec ¶
func (x *OperatorLog) GetSpec() *CreateOperatorRequest
func (*OperatorLog) ProtoMessage ¶
func (*OperatorLog) ProtoMessage()
func (*OperatorLog) ProtoReflect ¶
func (x *OperatorLog) ProtoReflect() protoreflect.Message
func (*OperatorLog) Reset ¶
func (x *OperatorLog) Reset()
func (*OperatorLog) String ¶
func (x *OperatorLog) String() string
type OperatorResponse ¶
type OperatorResponse struct { // @gotags: json:"description" bson:"description" Description string `protobuf:"bytes,1,opt,name=description,proto3" json:"description" bson:"description"` // @gotags: json:"role_name" bson:"role_name" RoleName string `protobuf:"bytes,2,opt,name=role_name,json=roleName,proto3" json:"role_name" bson:"role_name"` // contains filtered or unexported fields }
func (*OperatorResponse) Descriptor
deprecated
func (*OperatorResponse) Descriptor() ([]byte, []int)
Deprecated: Use OperatorResponse.ProtoReflect.Descriptor instead.
func (*OperatorResponse) GetDescription ¶
func (x *OperatorResponse) GetDescription() string
func (*OperatorResponse) GetRoleName ¶
func (x *OperatorResponse) GetRoleName() string
func (*OperatorResponse) ProtoMessage ¶
func (*OperatorResponse) ProtoMessage()
func (*OperatorResponse) ProtoReflect ¶
func (x *OperatorResponse) ProtoReflect() protoreflect.Message
func (*OperatorResponse) Reset ¶
func (x *OperatorResponse) Reset()
func (*OperatorResponse) String ¶
func (x *OperatorResponse) String() string
type OperatorSet ¶
type OperatorSet struct { // @gotags: json:"total" bson:"total" Total int64 `protobuf:"varint,1,opt,name=total,proto3" json:"total" bson:"total"` // @gotags: json:"items" bson:"items" Items []*OperatorLog `protobuf:"bytes,2,rep,name=items,proto3" json:"items" bson:"items"` // contains filtered or unexported fields }
func NewOperatorSet ¶
func NewOperatorSet() *OperatorSet
func (*OperatorSet) Add ¶
func (s *OperatorSet) Add(req *OperatorLog)
func (*OperatorSet) Descriptor
deprecated
func (*OperatorSet) Descriptor() ([]byte, []int)
Deprecated: Use OperatorSet.ProtoReflect.Descriptor instead.
func (*OperatorSet) GetItems ¶
func (x *OperatorSet) GetItems() []*OperatorLog
func (*OperatorSet) GetTotal ¶
func (x *OperatorSet) GetTotal() int64
func (*OperatorSet) ProtoMessage ¶
func (*OperatorSet) ProtoMessage()
func (*OperatorSet) ProtoReflect ¶
func (x *OperatorSet) ProtoReflect() protoreflect.Message
func (*OperatorSet) Reset ¶
func (x *OperatorSet) Reset()
func (*OperatorSet) String ¶
func (x *OperatorSet) String() string
type QueryOperatorRequest ¶
type QueryOperatorRequest struct { // 分页参数 // @gotags: json:"page" Page *request.PageRequest `protobuf:"bytes,1,opt,name=page,proto3" json:"page"` // 关键字参数 // @gotags: json:"user_name" UserName string `protobuf:"bytes,2,opt,name=user_name,json=userName,proto3" json:"user_name"` // contains filtered or unexported fields }
func NewQueryOpeatorRequest ¶
func NewQueryOpeatorRequest(r *http.Request) *QueryOperatorRequest
func (*QueryOperatorRequest) Descriptor
deprecated
func (*QueryOperatorRequest) Descriptor() ([]byte, []int)
Deprecated: Use QueryOperatorRequest.ProtoReflect.Descriptor instead.
func (*QueryOperatorRequest) GetPage ¶
func (x *QueryOperatorRequest) GetPage() *request.PageRequest
func (*QueryOperatorRequest) GetUserName ¶
func (x *QueryOperatorRequest) GetUserName() string
func (*QueryOperatorRequest) ProtoMessage ¶
func (*QueryOperatorRequest) ProtoMessage()
func (*QueryOperatorRequest) ProtoReflect ¶
func (x *QueryOperatorRequest) ProtoReflect() protoreflect.Message
func (*QueryOperatorRequest) Reset ¶
func (x *QueryOperatorRequest) Reset()
func (*QueryOperatorRequest) String ¶
func (x *QueryOperatorRequest) String() string
type Service ¶
type Service interface { QueryOperator(ctx context.Context, request *QueryOperatorRequest) (*OperatorSet, error) ServiceServer }
type ServiceClient ¶
type ServiceClient interface {
OperatorLog(ctx context.Context, in *CreateOperatorRequest, opts ...grpc.CallOption) (*OperatorResponse, error)
}
ServiceClient is the client API for Service service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewServiceClient ¶
func NewServiceClient(cc grpc.ClientConnInterface) ServiceClient
type ServiceServer ¶
type ServiceServer interface { OperatorLog(context.Context, *CreateOperatorRequest) (*OperatorResponse, error) // contains filtered or unexported methods }
ServiceServer is the server API for Service service. All implementations must embed UnimplementedServiceServer for forward compatibility
type UnimplementedServiceServer ¶
type UnimplementedServiceServer struct { }
UnimplementedServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedServiceServer) OperatorLog ¶
func (UnimplementedServiceServer) OperatorLog(context.Context, *CreateOperatorRequest) (*OperatorResponse, error)
type UnsafeServiceServer ¶
type UnsafeServiceServer interface {
// contains filtered or unexported methods
}
UnsafeServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ServiceServer will result in compilation errors.