Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterEventServiceHTTPServer(s *http.Server, srv EventServiceHTTPServer)
- func RegisterEventServiceServer(s grpc.ServiceRegistrar, srv EventServiceServer)
- type EventRequest
- func (*EventRequest) Descriptor() ([]byte, []int)deprecated
- func (x *EventRequest) GetMessage() *MessageProto
- func (x *EventRequest) GetService() string
- func (*EventRequest) ProtoMessage()
- func (x *EventRequest) ProtoReflect() protoreflect.Message
- func (x *EventRequest) Reset()
- func (x *EventRequest) String() string
- func (m *EventRequest) Validate() error
- func (m *EventRequest) ValidateAll() error
- type EventRequestMultiError
- type EventRequestValidationError
- func (e EventRequestValidationError) Cause() error
- func (e EventRequestValidationError) Error() string
- func (e EventRequestValidationError) ErrorName() string
- func (e EventRequestValidationError) Field() string
- func (e EventRequestValidationError) Key() bool
- func (e EventRequestValidationError) Reason() string
- type EventServiceClient
- type EventServiceHTTPClient
- type EventServiceHTTPClientImpl
- type EventServiceHTTPServer
- type EventServiceServer
- type MessageProto
- func (*MessageProto) Descriptor() ([]byte, []int)deprecated
- func (x *MessageProto) GetHeader() map[string]string
- func (x *MessageProto) GetKey() string
- func (x *MessageProto) GetValue() []byte
- func (*MessageProto) ProtoMessage()
- func (x *MessageProto) ProtoReflect() protoreflect.Message
- func (x *MessageProto) Reset()
- func (x *MessageProto) String() string
- func (x *MessageProto) ToEvent() event.Event
- func (m *MessageProto) Validate() error
- func (m *MessageProto) ValidateAll() error
- type MessageProtoMultiError
- type MessageProtoValidationError
- func (e MessageProtoValidationError) Cause() error
- func (e MessageProtoValidationError) Error() string
- func (e MessageProtoValidationError) ErrorName() string
- func (e MessageProtoValidationError) Field() string
- func (e MessageProtoValidationError) Key() bool
- func (e MessageProtoValidationError) Reason() string
- type UnimplementedEventServiceServer
- type UnsafeEventServiceServer
Constants ¶
const OperationEventServiceEvent = "/event.api.v1.EventService/Event"
Variables ¶
var EventService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "event.api.v1.EventService", HandlerType: (*EventServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Event", Handler: _EventService_Event_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "event/api/v1/event.proto", }
EventService_ServiceDesc is the grpc.ServiceDesc for EventService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_event_api_v1_event_proto protoreflect.FileDescriptor
Functions ¶
func RegisterEventServiceHTTPServer ¶
func RegisterEventServiceHTTPServer(s *http.Server, srv EventServiceHTTPServer)
func RegisterEventServiceServer ¶
func RegisterEventServiceServer(s grpc.ServiceRegistrar, srv EventServiceServer)
Types ¶
type EventRequest ¶
type EventRequest struct { Service string `protobuf:"bytes,1,opt,name=service,proto3" json:"service,omitempty"` Message *MessageProto `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` // contains filtered or unexported fields }
func (*EventRequest) Descriptor
deprecated
func (*EventRequest) Descriptor() ([]byte, []int)
Deprecated: Use EventRequest.ProtoReflect.Descriptor instead.
func (*EventRequest) GetMessage ¶
func (x *EventRequest) GetMessage() *MessageProto
func (*EventRequest) GetService ¶
func (x *EventRequest) GetService() string
func (*EventRequest) ProtoMessage ¶
func (*EventRequest) ProtoMessage()
func (*EventRequest) ProtoReflect ¶
func (x *EventRequest) ProtoReflect() protoreflect.Message
func (*EventRequest) Reset ¶
func (x *EventRequest) Reset()
func (*EventRequest) String ¶
func (x *EventRequest) String() string
func (*EventRequest) Validate ¶
func (m *EventRequest) Validate() error
Validate checks the field values on EventRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*EventRequest) ValidateAll ¶
func (m *EventRequest) ValidateAll() error
ValidateAll checks the field values on EventRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in EventRequestMultiError, or nil if none found.
type EventRequestMultiError ¶
type EventRequestMultiError []error
EventRequestMultiError is an error wrapping multiple validation errors returned by EventRequest.ValidateAll() if the designated constraints aren't met.
func (EventRequestMultiError) AllErrors ¶
func (m EventRequestMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (EventRequestMultiError) Error ¶
func (m EventRequestMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type EventRequestValidationError ¶
type EventRequestValidationError struct {
// contains filtered or unexported fields
}
EventRequestValidationError is the validation error returned by EventRequest.Validate if the designated constraints aren't met.
func (EventRequestValidationError) Cause ¶
func (e EventRequestValidationError) Cause() error
Cause function returns cause value.
func (EventRequestValidationError) Error ¶
func (e EventRequestValidationError) Error() string
Error satisfies the builtin error interface
func (EventRequestValidationError) ErrorName ¶
func (e EventRequestValidationError) ErrorName() string
ErrorName returns error name.
func (EventRequestValidationError) Field ¶
func (e EventRequestValidationError) Field() string
Field function returns field value.
func (EventRequestValidationError) Key ¶
func (e EventRequestValidationError) Key() bool
Key function returns key value.
func (EventRequestValidationError) Reason ¶
func (e EventRequestValidationError) Reason() string
Reason function returns reason value.
type EventServiceClient ¶
type EventServiceClient interface {
Event(ctx context.Context, in *EventRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
}
EventServiceClient is the client API for EventService 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 NewEventServiceClient ¶
func NewEventServiceClient(cc grpc.ClientConnInterface) EventServiceClient
type EventServiceHTTPClient ¶
type EventServiceHTTPClient interface {
Event(ctx context.Context, req *EventRequest, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
}
func NewEventServiceHTTPClient ¶
func NewEventServiceHTTPClient(client *http.Client) EventServiceHTTPClient
type EventServiceHTTPClientImpl ¶
type EventServiceHTTPClientImpl struct {
// contains filtered or unexported fields
}
func (*EventServiceHTTPClientImpl) Event ¶
func (c *EventServiceHTTPClientImpl) Event(ctx context.Context, in *EventRequest, opts ...http.CallOption) (*emptypb.Empty, error)
type EventServiceHTTPServer ¶
type EventServiceServer ¶
EventServiceServer is the server API for EventService service. All implementations should embed UnimplementedEventServiceServer for forward compatibility
func NewEventServiceClientProxy ¶
func NewEventServiceClientProxy(cc EventServiceClient) EventServiceServer
type MessageProto ¶
type MessageProto struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` Header map[string]string `` /* 153-byte string literal not displayed */ // contains filtered or unexported fields }
func FromEvent ¶
func FromEvent(e event.Event) *MessageProto
func (*MessageProto) Descriptor
deprecated
func (*MessageProto) Descriptor() ([]byte, []int)
Deprecated: Use MessageProto.ProtoReflect.Descriptor instead.
func (*MessageProto) GetHeader ¶
func (x *MessageProto) GetHeader() map[string]string
func (*MessageProto) GetKey ¶
func (x *MessageProto) GetKey() string
func (*MessageProto) GetValue ¶
func (x *MessageProto) GetValue() []byte
func (*MessageProto) ProtoMessage ¶
func (*MessageProto) ProtoMessage()
func (*MessageProto) ProtoReflect ¶
func (x *MessageProto) ProtoReflect() protoreflect.Message
func (*MessageProto) Reset ¶
func (x *MessageProto) Reset()
func (*MessageProto) String ¶
func (x *MessageProto) String() string
func (*MessageProto) ToEvent ¶
func (x *MessageProto) ToEvent() event.Event
func (*MessageProto) Validate ¶
func (m *MessageProto) Validate() error
Validate checks the field values on MessageProto with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*MessageProto) ValidateAll ¶
func (m *MessageProto) ValidateAll() error
ValidateAll checks the field values on MessageProto with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in MessageProtoMultiError, or nil if none found.
type MessageProtoMultiError ¶
type MessageProtoMultiError []error
MessageProtoMultiError is an error wrapping multiple validation errors returned by MessageProto.ValidateAll() if the designated constraints aren't met.
func (MessageProtoMultiError) AllErrors ¶
func (m MessageProtoMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (MessageProtoMultiError) Error ¶
func (m MessageProtoMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type MessageProtoValidationError ¶
type MessageProtoValidationError struct {
// contains filtered or unexported fields
}
MessageProtoValidationError is the validation error returned by MessageProto.Validate if the designated constraints aren't met.
func (MessageProtoValidationError) Cause ¶
func (e MessageProtoValidationError) Cause() error
Cause function returns cause value.
func (MessageProtoValidationError) Error ¶
func (e MessageProtoValidationError) Error() string
Error satisfies the builtin error interface
func (MessageProtoValidationError) ErrorName ¶
func (e MessageProtoValidationError) ErrorName() string
ErrorName returns error name.
func (MessageProtoValidationError) Field ¶
func (e MessageProtoValidationError) Field() string
Field function returns field value.
func (MessageProtoValidationError) Key ¶
func (e MessageProtoValidationError) Key() bool
Key function returns key value.
func (MessageProtoValidationError) Reason ¶
func (e MessageProtoValidationError) Reason() string
Reason function returns reason value.
type UnimplementedEventServiceServer ¶
type UnimplementedEventServiceServer struct { }
UnimplementedEventServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedEventServiceServer) Event ¶
func (UnimplementedEventServiceServer) Event(context.Context, *EventRequest) (*emptypb.Empty, error)
type UnsafeEventServiceServer ¶
type UnsafeEventServiceServer interface {
// contains filtered or unexported methods
}
UnsafeEventServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to EventServiceServer will result in compilation errors.