v1

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 9, 2022 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const OperationEventServiceEvent = "/event.api.v1.EventService/Event"

Variables

View Source
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)

View Source
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

Cause function returns cause value.

func (EventRequestValidationError) Error

Error satisfies the builtin error interface

func (EventRequestValidationError) ErrorName

func (e EventRequestValidationError) ErrorName() string

ErrorName returns error name.

func (EventRequestValidationError) Field

Field function returns field value.

func (EventRequestValidationError) Key

Key function returns key value.

func (EventRequestValidationError) Reason

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.

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

type EventServiceHTTPServer

type EventServiceHTTPServer interface {
	Event(context.Context, *EventRequest) (*emptypb.Empty, error)
}

type EventServiceServer

type EventServiceServer interface {
	Event(context.Context, *EventRequest) (*emptypb.Empty, error)
}

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

Cause function returns cause value.

func (MessageProtoValidationError) Error

Error satisfies the builtin error interface

func (MessageProtoValidationError) ErrorName

func (e MessageProtoValidationError) ErrorName() string

ErrorName returns error name.

func (MessageProtoValidationError) Field

Field function returns field value.

func (MessageProtoValidationError) Key

Key function returns key value.

func (MessageProtoValidationError) Reason

Reason function returns reason value.

type UnimplementedEventServiceServer

type UnimplementedEventServiceServer struct {
}

UnimplementedEventServiceServer should be embedded to have forward compatible implementations.

func (UnimplementedEventServiceServer) Event

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.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL