runtimev1

package
v0.0.0-...-54e8470 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2023 License: MIT Imports: 28 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	HealthCheckResponse_ServingStatus_name = map[int32]string{
		0: "SERVING_STATUS_UNSPECIFIED",
		1: "SERVING_STATUS_SERVING",
		2: "SERVING_STATUS_NOT_SERVING",
		3: "SERVING_STATUS_SERVICE_UNKNOWN",
	}
	HealthCheckResponse_ServingStatus_value = map[string]int32{
		"SERVING_STATUS_UNSPECIFIED":     0,
		"SERVING_STATUS_SERVING":         1,
		"SERVING_STATUS_NOT_SERVING":     2,
		"SERVING_STATUS_SERVICE_UNKNOWN": 3,
	}
)

Enum value maps for HealthCheckResponse_ServingStatus.

View Source
var File_connect_runtime_v1_event_proto protoreflect.FileDescriptor
View Source
var File_connect_runtime_v1_health_proto protoreflect.FileDescriptor
View Source
var File_connect_runtime_v1_message_proto protoreflect.FileDescriptor

Functions

func GetEventDataContentType

func GetEventDataContentType(ctx context.Context) string

GetEventDataContentType returns the event data schema from the incoming context.

func GetEventDataSchema

func GetEventDataSchema(ctx context.Context) string

GetEventDataSchema returns the event data schema from the incoming context.

func GetEventID

func GetEventID(ctx context.Context) string

GetEventID returns the event id from the incoming context.

func GetEventSource

func GetEventSource(ctx context.Context) string

GetEventSource returns the event source from the incoming context.

func GetEventSpecVersion

func GetEventSpecVersion(ctx context.Context) string

GetEventSpecVersion returns the event spec version from the incoming context.

func GetEventSubject

func GetEventSubject(ctx context.Context) string

GetEventSubject returns the event subject from the incoming context.

func GetEventTime

func GetEventTime(ctx context.Context) time.Time

GetEventTime returns the event time from the incoming context.

func GetEventType

func GetEventType(ctx context.Context) string

GetEventType returns the event type from the incoming context.

Types

type Event

type Event struct {

	// Required. Id contains the event's identifier. Producers MUST ensure that
	// source + id is unique for each distinct event. If a duplicate event is
	// re-sent (e.g. due to a network error) it MAY have the same id. Consumers
	// MAY assume that Events with identical source and id are duplicates.
	// Example: 5cc0996e-facd-11ed-9c22-325096b39f47
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// Required. Source contains the context in which an event happened. Often
	// this will include information such as the type of the event source, the
	// organization publishing the event or the process that produced the event.
	// The exact syntax and semantics behind the data encoded in the URI is
	// defined by the event producer. Producers MUST ensure that source + id is
	// unique for each distinct event.
	//
	// Example: https://github.com/cloudevents, urn:uuid:6e8bc430-9c3a-11d9-9669-0800200c9a66, /cloudevents/spec/pull/123
	Source string `protobuf:"bytes,2,opt,name=source,proto3" json:"source,omitempty"`
	// Required. SpecVerion is the version of the CloudEvents specification which
	// the event uses. This enables the interpretation of the context. Compliant
	// event producers MUST use a value of 1.0 when referring to this version of
	// the specification. Currently, this attribute will only have the 'major' and
	// 'minor' version numbers included in it. This allows for 'patch' changes to
	// the specification to be made without changing this property's value in the
	// serialization. Note: for 'release candidate' releases a suffix might be
	// used for testing purposes.
	SpecVersion string `protobuf:"bytes,3,opt,name=spec_version,json=specVersion,proto3" json:"spec_version,omitempty"`
	// Required. Type attribute contains a value describing the type of event
	// related to the originating occurrence. Often this attribute is used for
	// routing, observability, policy enforcement, etc.
	//
	// Example: com.github.pull_request.opened, com.example.object.deleted
	Type string `protobuf:"bytes,4,opt,name=type,proto3" json:"type,omitempty"`
	// Optional. Extra attributes.
	Attributes map[string]*EventAttributeValue `` /* 161-byte string literal not displayed */
	// Optional. Contains the event's data.
	//
	// Types that are assignable to Data:
	//
	//	*Event_BinaryData
	//	*Event_TextData
	//	*Event_ProtoData
	Data isEvent_Data `protobuf_oneof:"data"`
	// contains filtered or unexported fields
}

Event represents an event.

func NewEvent

func NewEvent() *Event

NewEvent returns a new instance of connect.runtime.v1.Event message.

func (*Event) Descriptor deprecated

func (*Event) Descriptor() ([]byte, []int)

Deprecated: Use Event.ProtoReflect.Descriptor instead.

func (*Event) GetAttributes

func (x *Event) GetAttributes() map[string]*EventAttributeValue

func (*Event) GetBinaryData

func (x *Event) GetBinaryData() []byte

func (*Event) GetData

func (m *Event) GetData() isEvent_Data

func (*Event) GetDataAs

func (x *Event) GetDataAs(value interface{}) error

GetDataAs attempts to populate the provided data object with the event payload. The object should be a pointer type.

func (*Event) GetDataContentType

func (x *Event) GetDataContentType() string

GetDataContentType returns the DataContentType attribute.

func (*Event) GetDataSchema

func (x *Event) GetDataSchema() string

GetDataSchema returns the DataSchema attribute. It contains the schema that data adheres to. Incompatible changes to the schema SHOULD be reflected by a different URI.

func (*Event) GetId

func (x *Event) GetId() string

func (*Event) GetProtoData

func (x *Event) GetProtoData() *anypb.Any

func (*Event) GetSource

func (x *Event) GetSource() string

func (*Event) GetSpecVersion

func (x *Event) GetSpecVersion() string

func (*Event) GetSubject

func (x *Event) GetSubject() string

GetSubject returns the Subject attribute. It describes the subject of the event in the context of the event producer (identified by source). In publish-subscribe scenarios, a subscriber will typically subscribe to events emitted by a source, but the source identifier alone might not be sufficient as a qualifier for any specific event if the source context has internal sub-structure.

func (*Event) GetTextData

func (x *Event) GetTextData() string

func (*Event) GetTime

func (x *Event) GetTime() time.Time

GetTime returns the Time attribute. Timestamp of when the occurrence happened. If the time of the occurrence cannot be determined then this attribute MAY be set to some other time (such as the current time) by the CloudEvents producer, however all producers for the same source MUST be consistent in this respect. In other words, either they all use the actual time of the occurrence or they all use the same algorithm to determine the value used.

func (*Event) GetType

func (x *Event) GetType() string

func (*Event) MarshalJSON

func (msg *Event) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*Event) ProtoMessage

func (*Event) ProtoMessage()

func (*Event) ProtoReflect

func (x *Event) ProtoReflect() protoreflect.Message

func (*Event) Reset

func (x *Event) Reset()

func (*Event) SetData

func (x *Event) SetData(value interface{}) error

SetData encodes the given payload with the given content type. If the provided payload is a byte array, when marshalled to json it will be encoded as base64. If the provided payload is different from byte array, datacodec.Encode is invoked to attempt a marshalling to byte array.

func (*Event) SetDataContentType

func (x *Event) SetDataContentType(value string)

SetDataContentType sets the DataContentType attribute.

func (*Event) SetDataSchema

func (x *Event) SetDataSchema(value string)

SetDataSchema sets the DataSchema attribute.

func (*Event) SetExtension

func (x *Event) SetExtension(name string, value interface{})

SetExtension sets the Extension attribute.

func (*Event) SetId

func (x *Event) SetId(value string)

SetId sets the ID attribute.

func (*Event) SetSource

func (x *Event) SetSource(value string)

SetSource sets the Source attribute.

func (*Event) SetSpecVersion

func (x *Event) SetSpecVersion(value string)

SetSpecVersion sets the SpecVersion attribute.

func (*Event) SetSubject

func (x *Event) SetSubject(value string)

SetSubject sets the Subject attribute.

func (*Event) SetTime

func (x *Event) SetTime(value time.Time)

SetTime sets the Time attribute.

func (*Event) SetType

func (x *Event) SetType(value string)

SetType sets the Type attribute.

func (*Event) String

func (x *Event) String() string

func (*Event) UnmarshalJSON

func (msg *Event) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*Event) Validate

func (m *Event) Validate() error

Validate checks the field values on Event 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 (*Event) ValidateAll

func (m *Event) ValidateAll() error

ValidateAll checks the field values on Event 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 EventMultiError, or nil if none found.

type EventAttributeValue

type EventAttributeValue struct {

	// Types that are assignable to Attr:
	//
	//	*EventAttributeValue_CeBoolean
	//	*EventAttributeValue_CeInteger
	//	*EventAttributeValue_CeString
	//	*EventAttributeValue_CeBytes
	//	*EventAttributeValue_CeUri
	//	*EventAttributeValue_CeUriRef
	//	*EventAttributeValue_CeTimestamp
	Attr isEventAttributeValue_Attr `protobuf_oneof:"attr"`
	// contains filtered or unexported fields
}

EventAttributeValue represents an event attributes.

func (*EventAttributeValue) Descriptor deprecated

func (*EventAttributeValue) Descriptor() ([]byte, []int)

Deprecated: Use EventAttributeValue.ProtoReflect.Descriptor instead.

func (*EventAttributeValue) GetAttr

func (m *EventAttributeValue) GetAttr() isEventAttributeValue_Attr

func (*EventAttributeValue) GetCeBoolean

func (x *EventAttributeValue) GetCeBoolean() bool

func (*EventAttributeValue) GetCeBytes

func (x *EventAttributeValue) GetCeBytes() []byte

func (*EventAttributeValue) GetCeInteger

func (x *EventAttributeValue) GetCeInteger() int32

func (*EventAttributeValue) GetCeString

func (x *EventAttributeValue) GetCeString() string

func (*EventAttributeValue) GetCeTimestamp

func (x *EventAttributeValue) GetCeTimestamp() *timestamppb.Timestamp

func (*EventAttributeValue) GetCeUri

func (x *EventAttributeValue) GetCeUri() string

func (*EventAttributeValue) GetCeUriRef

func (x *EventAttributeValue) GetCeUriRef() string

func (*EventAttributeValue) MarshalJSON

func (msg *EventAttributeValue) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*EventAttributeValue) ProtoMessage

func (*EventAttributeValue) ProtoMessage()

func (*EventAttributeValue) ProtoReflect

func (x *EventAttributeValue) ProtoReflect() protoreflect.Message

func (*EventAttributeValue) Reset

func (x *EventAttributeValue) Reset()

func (*EventAttributeValue) String

func (x *EventAttributeValue) String() string

func (*EventAttributeValue) UnmarshalJSON

func (msg *EventAttributeValue) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*EventAttributeValue) Validate

func (m *EventAttributeValue) Validate() error

Validate checks the field values on EventAttributeValue 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 (*EventAttributeValue) ValidateAll

func (m *EventAttributeValue) ValidateAll() error

ValidateAll checks the field values on EventAttributeValue 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 EventAttributeValueMultiError, or nil if none found.

type EventAttributeValueMultiError

type EventAttributeValueMultiError []error

EventAttributeValueMultiError is an error wrapping multiple validation errors returned by EventAttributeValue.ValidateAll() if the designated constraints aren't met.

func (EventAttributeValueMultiError) AllErrors

func (m EventAttributeValueMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (EventAttributeValueMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type EventAttributeValueValidationError

type EventAttributeValueValidationError struct {
	// contains filtered or unexported fields
}

EventAttributeValueValidationError is the validation error returned by EventAttributeValue.Validate if the designated constraints aren't met.

func (EventAttributeValueValidationError) Cause

Cause function returns cause value.

func (EventAttributeValueValidationError) Error

Error satisfies the builtin error interface

func (EventAttributeValueValidationError) ErrorName

ErrorName returns error name.

func (EventAttributeValueValidationError) Field

Field function returns field value.

func (EventAttributeValueValidationError) Key

Key function returns key value.

func (EventAttributeValueValidationError) Reason

Reason function returns reason value.

type EventAttributeValue_CeBoolean

type EventAttributeValue_CeBoolean struct {
	// CeBoolean is a boolean value.
	CeBoolean bool `protobuf:"varint,1,opt,name=ce_boolean,json=ceBoolean,proto3,oneof"`
}

type EventAttributeValue_CeBytes

type EventAttributeValue_CeBytes struct {
	// CeBytes is a bytes value.
	CeBytes []byte `protobuf:"bytes,4,opt,name=ce_bytes,json=ceBytes,proto3,oneof"`
}

type EventAttributeValue_CeInteger

type EventAttributeValue_CeInteger struct {
	// CeInteager is an integer value.
	CeInteger int32 `protobuf:"varint,2,opt,name=ce_integer,json=ceInteger,proto3,oneof"`
}

type EventAttributeValue_CeString

type EventAttributeValue_CeString struct {
	// CeString is a string value.
	CeString string `protobuf:"bytes,3,opt,name=ce_string,json=ceString,proto3,oneof"`
}

type EventAttributeValue_CeTimestamp

type EventAttributeValue_CeTimestamp struct {
	// CeTimestamp ia a timestamp value.
	CeTimestamp *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=ce_timestamp,json=ceTimestamp,proto3,oneof"`
}

type EventAttributeValue_CeUri

type EventAttributeValue_CeUri struct {
	// CeUri is a uri value.
	CeUri string `protobuf:"bytes,5,opt,name=ce_uri,json=ceUri,proto3,oneof"`
}

type EventAttributeValue_CeUriRef

type EventAttributeValue_CeUriRef struct {
	// CeUriRef is a uri ref value.
	CeUriRef string `protobuf:"bytes,6,opt,name=ce_uri_ref,json=ceUriRef,proto3,oneof"`
}

type EventBatch

type EventBatch struct {

	// Events collection.
	Events []*Event `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"`
	// contains filtered or unexported fields
}

EventBatch is a batch format.

func (*EventBatch) Descriptor deprecated

func (*EventBatch) Descriptor() ([]byte, []int)

Deprecated: Use EventBatch.ProtoReflect.Descriptor instead.

func (*EventBatch) GetEvents

func (x *EventBatch) GetEvents() []*Event

func (*EventBatch) MarshalJSON

func (msg *EventBatch) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*EventBatch) ProtoMessage

func (*EventBatch) ProtoMessage()

func (*EventBatch) ProtoReflect

func (x *EventBatch) ProtoReflect() protoreflect.Message

func (*EventBatch) Reset

func (x *EventBatch) Reset()

func (*EventBatch) String

func (x *EventBatch) String() string

func (*EventBatch) UnmarshalJSON

func (msg *EventBatch) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*EventBatch) Validate

func (m *EventBatch) Validate() error

Validate checks the field values on EventBatch 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 (*EventBatch) ValidateAll

func (m *EventBatch) ValidateAll() error

ValidateAll checks the field values on EventBatch 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 EventBatchMultiError, or nil if none found.

type EventBatchMultiError

type EventBatchMultiError []error

EventBatchMultiError is an error wrapping multiple validation errors returned by EventBatch.ValidateAll() if the designated constraints aren't met.

func (EventBatchMultiError) AllErrors

func (m EventBatchMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (EventBatchMultiError) Error

func (m EventBatchMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type EventBatchValidationError

type EventBatchValidationError struct {
	// contains filtered or unexported fields
}

EventBatchValidationError is the validation error returned by EventBatch.Validate if the designated constraints aren't met.

func (EventBatchValidationError) Cause

func (e EventBatchValidationError) Cause() error

Cause function returns cause value.

func (EventBatchValidationError) Error

Error satisfies the builtin error interface

func (EventBatchValidationError) ErrorName

func (e EventBatchValidationError) ErrorName() string

ErrorName returns error name.

func (EventBatchValidationError) Field

Field function returns field value.

func (EventBatchValidationError) Key

Key function returns key value.

func (EventBatchValidationError) Reason

func (e EventBatchValidationError) Reason() string

Reason function returns reason value.

type EventMultiError

type EventMultiError []error

EventMultiError is an error wrapping multiple validation errors returned by Event.ValidateAll() if the designated constraints aren't met.

func (EventMultiError) AllErrors

func (m EventMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (EventMultiError) Error

func (m EventMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type EventService

type EventService interface {
	// PushEvent pushes a given event to connect.runtime.v1.EventService service.
	PushEvent(context.Context, *PushEventRequest) (*PushEventResponse, error)
}

The service that an application uses to consume events from a subscription via the Push method.

type EventServiceClient

type EventServiceClient interface {
	// PushEvent pushes a given event to connect.runtime.v1.EventService service.
	PushEvent(context.Context, *PushEventRequest) (*PushEventResponse, error)
}

The service client that an application uses to consume events from a subscription via the Push method.

type EventServiceHandler

type EventServiceHandler struct {
	// EventService contains an instance of connect.runtime.v1.EventService handler.
	EventService EventService
}

EventMessageService represents a message broker for connect.runtime.v1.EventServiceHandler handler.

func (*EventServiceHandler) PushMessage

PushMessage pushes a given event to connect.runtime.v1.MessageService service.

type EventServiceRegistry

type EventServiceRegistry map[string]EventService

EventServiceRegistry represents a map of connect.runtime.v1.EventService service.

func (*EventServiceRegistry) PushEvent

PushEvent implements EventService.

type EventValidationError

type EventValidationError struct {
	// contains filtered or unexported fields
}

EventValidationError is the validation error returned by Event.Validate if the designated constraints aren't met.

func (EventValidationError) Cause

func (e EventValidationError) Cause() error

Cause function returns cause value.

func (EventValidationError) Error

func (e EventValidationError) Error() string

Error satisfies the builtin error interface

func (EventValidationError) ErrorName

func (e EventValidationError) ErrorName() string

ErrorName returns error name.

func (EventValidationError) Field

func (e EventValidationError) Field() string

Field function returns field value.

func (EventValidationError) Key

func (e EventValidationError) Key() bool

Key function returns key value.

func (EventValidationError) Reason

func (e EventValidationError) Reason() string

Reason function returns reason value.

type Event_BinaryData

type Event_BinaryData struct {
	// BinaryData contains the data in binary format.
	BinaryData []byte `protobuf:"bytes,6,opt,name=binary_data,json=binaryData,proto3,oneof"`
}

type Event_ProtoData

type Event_ProtoData struct {
	// ProtoData contains the data in proto format.
	ProtoData *anypb.Any `protobuf:"bytes,8,opt,name=proto_data,json=protoData,proto3,oneof"`
}

type Event_TextData

type Event_TextData struct {
	// TextData contains the data in string format.
	TextData string `protobuf:"bytes,7,opt,name=text_data,json=textData,proto3,oneof"`
}

type HealthCheckRequest

type HealthCheckRequest struct {
	Service string `protobuf:"bytes,1,opt,name=service,proto3" json:"service,omitempty"`
	// contains filtered or unexported fields
}

HealthCheckRequest represents a request for connect.runtime.v1.HealthService.Check method.

func (*HealthCheckRequest) Descriptor deprecated

func (*HealthCheckRequest) Descriptor() ([]byte, []int)

Deprecated: Use HealthCheckRequest.ProtoReflect.Descriptor instead.

func (*HealthCheckRequest) GetService

func (x *HealthCheckRequest) GetService() string

func (*HealthCheckRequest) MarshalJSON

func (msg *HealthCheckRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*HealthCheckRequest) ProtoMessage

func (*HealthCheckRequest) ProtoMessage()

func (*HealthCheckRequest) ProtoReflect

func (x *HealthCheckRequest) ProtoReflect() protoreflect.Message

func (*HealthCheckRequest) Reset

func (x *HealthCheckRequest) Reset()

func (*HealthCheckRequest) String

func (x *HealthCheckRequest) String() string

func (*HealthCheckRequest) UnmarshalJSON

func (msg *HealthCheckRequest) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*HealthCheckRequest) Validate

func (m *HealthCheckRequest) Validate() error

Validate checks the field values on HealthCheckRequest 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 (*HealthCheckRequest) ValidateAll

func (m *HealthCheckRequest) ValidateAll() error

ValidateAll checks the field values on HealthCheckRequest 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 HealthCheckRequestMultiError, or nil if none found.

type HealthCheckRequestMultiError

type HealthCheckRequestMultiError []error

HealthCheckRequestMultiError is an error wrapping multiple validation errors returned by HealthCheckRequest.ValidateAll() if the designated constraints aren't met.

func (HealthCheckRequestMultiError) AllErrors

func (m HealthCheckRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (HealthCheckRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type HealthCheckRequestValidationError

type HealthCheckRequestValidationError struct {
	// contains filtered or unexported fields
}

HealthCheckRequestValidationError is the validation error returned by HealthCheckRequest.Validate if the designated constraints aren't met.

func (HealthCheckRequestValidationError) Cause

Cause function returns cause value.

func (HealthCheckRequestValidationError) Error

Error satisfies the builtin error interface

func (HealthCheckRequestValidationError) ErrorName

ErrorName returns error name.

func (HealthCheckRequestValidationError) Field

Field function returns field value.

func (HealthCheckRequestValidationError) Key

Key function returns key value.

func (HealthCheckRequestValidationError) Reason

Reason function returns reason value.

type HealthCheckResponse

type HealthCheckResponse struct {
	Status HealthCheckResponse_ServingStatus `protobuf:"varint,1,opt,name=status,proto3,enum=connect.runtime.v1.HealthCheckResponse_ServingStatus" json:"status,omitempty"`
	// contains filtered or unexported fields
}

HealthCheckResponse represents a response for connect.runtime.v1.HealthService.Check method.

func (*HealthCheckResponse) Descriptor deprecated

func (*HealthCheckResponse) Descriptor() ([]byte, []int)

Deprecated: Use HealthCheckResponse.ProtoReflect.Descriptor instead.

func (*HealthCheckResponse) GetStatus

func (*HealthCheckResponse) MarshalJSON

func (msg *HealthCheckResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*HealthCheckResponse) ProtoMessage

func (*HealthCheckResponse) ProtoMessage()

func (*HealthCheckResponse) ProtoReflect

func (x *HealthCheckResponse) ProtoReflect() protoreflect.Message

func (*HealthCheckResponse) Reset

func (x *HealthCheckResponse) Reset()

func (*HealthCheckResponse) String

func (x *HealthCheckResponse) String() string

func (*HealthCheckResponse) UnmarshalJSON

func (msg *HealthCheckResponse) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*HealthCheckResponse) Validate

func (m *HealthCheckResponse) Validate() error

Validate checks the field values on HealthCheckResponse 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 (*HealthCheckResponse) ValidateAll

func (m *HealthCheckResponse) ValidateAll() error

ValidateAll checks the field values on HealthCheckResponse 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 HealthCheckResponseMultiError, or nil if none found.

type HealthCheckResponseMultiError

type HealthCheckResponseMultiError []error

HealthCheckResponseMultiError is an error wrapping multiple validation errors returned by HealthCheckResponse.ValidateAll() if the designated constraints aren't met.

func (HealthCheckResponseMultiError) AllErrors

func (m HealthCheckResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (HealthCheckResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type HealthCheckResponseValidationError

type HealthCheckResponseValidationError struct {
	// contains filtered or unexported fields
}

HealthCheckResponseValidationError is the validation error returned by HealthCheckResponse.Validate if the designated constraints aren't met.

func (HealthCheckResponseValidationError) Cause

Cause function returns cause value.

func (HealthCheckResponseValidationError) Error

Error satisfies the builtin error interface

func (HealthCheckResponseValidationError) ErrorName

ErrorName returns error name.

func (HealthCheckResponseValidationError) Field

Field function returns field value.

func (HealthCheckResponseValidationError) Key

Key function returns key value.

func (HealthCheckResponseValidationError) Reason

Reason function returns reason value.

type HealthCheckResponse_ServingStatus

type HealthCheckResponse_ServingStatus int32
const (
	HealthCheckResponse_SERVING_STATUS_UNSPECIFIED     HealthCheckResponse_ServingStatus = 0
	HealthCheckResponse_SERVING_STATUS_SERVING         HealthCheckResponse_ServingStatus = 1
	HealthCheckResponse_SERVING_STATUS_NOT_SERVING     HealthCheckResponse_ServingStatus = 2
	HealthCheckResponse_SERVING_STATUS_SERVICE_UNKNOWN HealthCheckResponse_ServingStatus = 3 // Used only by the Watch method.
)

func (HealthCheckResponse_ServingStatus) Descriptor

func (HealthCheckResponse_ServingStatus) Enum

func (HealthCheckResponse_ServingStatus) EnumDescriptor deprecated

func (HealthCheckResponse_ServingStatus) EnumDescriptor() ([]byte, []int)

Deprecated: Use HealthCheckResponse_ServingStatus.Descriptor instead.

func (HealthCheckResponse_ServingStatus) Number

func (HealthCheckResponse_ServingStatus) String

func (HealthCheckResponse_ServingStatus) Type

type HealthService

type HealthService interface {
	// If the requested service is unknown, the call will fail with status
	// NOT_FOUND.
	Check(context.Context, *HealthCheckRequest) (*HealthCheckResponse, error)
}

HealthService is an implementation of the connect.runtime.v1.HealthService service.

type HealthServiceClient

type HealthServiceClient interface {
	// If the requested service is unknown, the call will fail with status
	// NOT_FOUND.
	Check(context.Context, *HealthCheckRequest) (*HealthCheckResponse, error)
}

HealthServiceClient is an implementation of the connect.runtime.v1.HealthServiceClient client.

type HealthServiceRegistry

type HealthServiceRegistry map[string]HealthService

HealthServiceRegistry represents a map of connect.runtime.v1.HealthService service.

func (*HealthServiceRegistry) Check

Check checks the health of a given service.

type Message

type Message struct {

	// The message payload. For JSON requests, the value of this field must be
	// base64-encoded.
	Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	// Attributes for this message.
	Attributes map[string]string `` /* 161-byte string literal not displayed */
	// contains filtered or unexported fields
}

A message data and its attributes.

func (*Message) Descriptor deprecated

func (*Message) Descriptor() ([]byte, []int)

Deprecated: Use Message.ProtoReflect.Descriptor instead.

func (*Message) GetAttributes

func (x *Message) GetAttributes() map[string]string

func (*Message) GetData

func (x *Message) GetData() []byte

func (*Message) MarshalJSON

func (msg *Message) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*Message) ProtoMessage

func (*Message) ProtoMessage()

func (*Message) ProtoReflect

func (x *Message) ProtoReflect() protoreflect.Message

func (*Message) Reset

func (x *Message) Reset()

func (*Message) String

func (x *Message) String() string

func (*Message) UnmarshalJSON

func (msg *Message) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*Message) Validate

func (m *Message) Validate() error

Validate checks the field values on Message 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 (*Message) ValidateAll

func (m *Message) ValidateAll() error

ValidateAll checks the field values on Message 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 MessageMultiError, or nil if none found.

type MessageMultiError

type MessageMultiError []error

MessageMultiError is an error wrapping multiple validation errors returned by Message.ValidateAll() if the designated constraints aren't met.

func (MessageMultiError) AllErrors

func (m MessageMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (MessageMultiError) Error

func (m MessageMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type MessageService

type MessageService interface {
	// PushEvent pushes a given message to connect.runtime.v1.MessageService service.
	PushMessage(context.Context, *PushMessageRequest) (*PushMessageResponse, error)
}

MessageService is an implementation of the connect.runtime.v1.MessageService service.

type MessageServiceClient

type MessageServiceClient interface {
	// PushEvent pushes a given message to connect.runtime.v1.MessageService service.
	PushMessage(context.Context, *PushMessageRequest) (*PushMessageResponse, error)
}

MessageServiceClient is an implementation of the connect.runtime.v1.MessageServiceClient client.

type MessageValidationError

type MessageValidationError struct {
	// contains filtered or unexported fields
}

MessageValidationError is the validation error returned by Message.Validate if the designated constraints aren't met.

func (MessageValidationError) Cause

func (e MessageValidationError) Cause() error

Cause function returns cause value.

func (MessageValidationError) Error

func (e MessageValidationError) Error() string

Error satisfies the builtin error interface

func (MessageValidationError) ErrorName

func (e MessageValidationError) ErrorName() string

ErrorName returns error name.

func (MessageValidationError) Field

func (e MessageValidationError) Field() string

Field function returns field value.

func (MessageValidationError) Key

func (e MessageValidationError) Key() bool

Key function returns key value.

func (MessageValidationError) Reason

func (e MessageValidationError) Reason() string

Reason function returns reason value.

type PushEventRequest

type PushEventRequest struct {

	// The event.
	Event *Event `protobuf:"bytes,1,opt,name=event,proto3" json:"event,omitempty"`
	// contains filtered or unexported fields
}

PushEventRequest represents a request for connect.runtime.v1.EventService.PushEvent method.

func (*PushEventRequest) Descriptor deprecated

func (*PushEventRequest) Descriptor() ([]byte, []int)

Deprecated: Use PushEventRequest.ProtoReflect.Descriptor instead.

func (*PushEventRequest) GetAttributes

func (x *PushEventRequest) GetAttributes() map[string]string

GetAttributes returns the attributes.

func (*PushEventRequest) GetData

func (x *PushEventRequest) GetData() []byte

GetData returns the data.

func (*PushEventRequest) GetEvent

func (x *PushEventRequest) GetEvent() *Event

func (*PushEventRequest) GetOrderingKey

func (x *PushEventRequest) GetOrderingKey() string

GetOrderingKey returns the ordering key.

func (*PushEventRequest) MarshalJSON

func (msg *PushEventRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PushEventRequest) ProtoMessage

func (*PushEventRequest) ProtoMessage()

func (*PushEventRequest) ProtoReflect

func (x *PushEventRequest) ProtoReflect() protoreflect.Message

func (*PushEventRequest) Reset

func (x *PushEventRequest) Reset()

func (*PushEventRequest) SetAttributes

func (x *PushEventRequest) SetAttributes(attributes map[string]string) error

SetAttributes sets the attributes.

func (*PushEventRequest) SetData

func (x *PushEventRequest) SetData(data []byte) error

SetData sets the data.

func (*PushEventRequest) String

func (x *PushEventRequest) String() string

func (*PushEventRequest) UnmarshalJSON

func (msg *PushEventRequest) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*PushEventRequest) Validate

func (m *PushEventRequest) Validate() error

Validate checks the field values on PushEventRequest 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 (*PushEventRequest) ValidateAll

func (m *PushEventRequest) ValidateAll() error

ValidateAll checks the field values on PushEventRequest 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 PushEventRequestMultiError, or nil if none found.

type PushEventRequestMultiError

type PushEventRequestMultiError []error

PushEventRequestMultiError is an error wrapping multiple validation errors returned by PushEventRequest.ValidateAll() if the designated constraints aren't met.

func (PushEventRequestMultiError) AllErrors

func (m PushEventRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (PushEventRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type PushEventRequestValidationError

type PushEventRequestValidationError struct {
	// contains filtered or unexported fields
}

PushEventRequestValidationError is the validation error returned by PushEventRequest.Validate if the designated constraints aren't met.

func (PushEventRequestValidationError) Cause

Cause function returns cause value.

func (PushEventRequestValidationError) Error

Error satisfies the builtin error interface

func (PushEventRequestValidationError) ErrorName

ErrorName returns error name.

func (PushEventRequestValidationError) Field

Field function returns field value.

func (PushEventRequestValidationError) Key

Key function returns key value.

func (PushEventRequestValidationError) Reason

Reason function returns reason value.

type PushEventResponse

type PushEventResponse struct {
	// contains filtered or unexported fields
}

PushEventResponse represents a response for connect.runtime.v1.EventService.PushEvent method.

func (*PushEventResponse) Descriptor deprecated

func (*PushEventResponse) Descriptor() ([]byte, []int)

Deprecated: Use PushEventResponse.ProtoReflect.Descriptor instead.

func (*PushEventResponse) MarshalJSON

func (msg *PushEventResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PushEventResponse) ProtoMessage

func (*PushEventResponse) ProtoMessage()

func (*PushEventResponse) ProtoReflect

func (x *PushEventResponse) ProtoReflect() protoreflect.Message

func (*PushEventResponse) Reset

func (x *PushEventResponse) Reset()

func (*PushEventResponse) String

func (x *PushEventResponse) String() string

func (*PushEventResponse) UnmarshalJSON

func (msg *PushEventResponse) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*PushEventResponse) Validate

func (m *PushEventResponse) Validate() error

Validate checks the field values on PushEventResponse 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 (*PushEventResponse) ValidateAll

func (m *PushEventResponse) ValidateAll() error

ValidateAll checks the field values on PushEventResponse 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 PushEventResponseMultiError, or nil if none found.

type PushEventResponseMultiError

type PushEventResponseMultiError []error

PushEventResponseMultiError is an error wrapping multiple validation errors returned by PushEventResponse.ValidateAll() if the designated constraints aren't met.

func (PushEventResponseMultiError) AllErrors

func (m PushEventResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (PushEventResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type PushEventResponseValidationError

type PushEventResponseValidationError struct {
	// contains filtered or unexported fields
}

PushEventResponseValidationError is the validation error returned by PushEventResponse.Validate if the designated constraints aren't met.

func (PushEventResponseValidationError) Cause

Cause function returns cause value.

func (PushEventResponseValidationError) Error

Error satisfies the builtin error interface

func (PushEventResponseValidationError) ErrorName

ErrorName returns error name.

func (PushEventResponseValidationError) Field

Field function returns field value.

func (PushEventResponseValidationError) Key

Key function returns key value.

func (PushEventResponseValidationError) Reason

Reason function returns reason value.

type PushMessageRequest

type PushMessageRequest struct {

	// The subscription from which messages should be pulled.
	Subscription string `protobuf:"bytes,1,opt,name=subscription,proto3" json:"subscription,omitempty"`
	// The message.
	Message *Message `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

PushMessageRequest represents a request for connect.runtime.v1.MessageService.PushMessage method.

func (*PushMessageRequest) Descriptor deprecated

func (*PushMessageRequest) Descriptor() ([]byte, []int)

Deprecated: Use PushMessageRequest.ProtoReflect.Descriptor instead.

func (*PushMessageRequest) GetMessage

func (x *PushMessageRequest) GetMessage() *Message

func (*PushMessageRequest) GetSubscription

func (x *PushMessageRequest) GetSubscription() string

func (*PushMessageRequest) MarshalJSON

func (msg *PushMessageRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PushMessageRequest) ProtoMessage

func (*PushMessageRequest) ProtoMessage()

func (*PushMessageRequest) ProtoReflect

func (x *PushMessageRequest) ProtoReflect() protoreflect.Message

func (*PushMessageRequest) Reset

func (x *PushMessageRequest) Reset()

func (*PushMessageRequest) String

func (x *PushMessageRequest) String() string

func (*PushMessageRequest) UnmarshalJSON

func (msg *PushMessageRequest) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*PushMessageRequest) Validate

func (m *PushMessageRequest) Validate() error

Validate checks the field values on PushMessageRequest 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 (*PushMessageRequest) ValidateAll

func (m *PushMessageRequest) ValidateAll() error

ValidateAll checks the field values on PushMessageRequest 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 PushMessageRequestMultiError, or nil if none found.

type PushMessageRequestMultiError

type PushMessageRequestMultiError []error

PushMessageRequestMultiError is an error wrapping multiple validation errors returned by PushMessageRequest.ValidateAll() if the designated constraints aren't met.

func (PushMessageRequestMultiError) AllErrors

func (m PushMessageRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (PushMessageRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type PushMessageRequestValidationError

type PushMessageRequestValidationError struct {
	// contains filtered or unexported fields
}

PushMessageRequestValidationError is the validation error returned by PushMessageRequest.Validate if the designated constraints aren't met.

func (PushMessageRequestValidationError) Cause

Cause function returns cause value.

func (PushMessageRequestValidationError) Error

Error satisfies the builtin error interface

func (PushMessageRequestValidationError) ErrorName

ErrorName returns error name.

func (PushMessageRequestValidationError) Field

Field function returns field value.

func (PushMessageRequestValidationError) Key

Key function returns key value.

func (PushMessageRequestValidationError) Reason

Reason function returns reason value.

type PushMessageResponse

type PushMessageResponse struct {
	// contains filtered or unexported fields
}

PushMessageResponse represents a response for connect.runtime.v1.MessageService.PushMessage method.

func (*PushMessageResponse) Descriptor deprecated

func (*PushMessageResponse) Descriptor() ([]byte, []int)

Deprecated: Use PushMessageResponse.ProtoReflect.Descriptor instead.

func (*PushMessageResponse) MarshalJSON

func (msg *PushMessageResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PushMessageResponse) ProtoMessage

func (*PushMessageResponse) ProtoMessage()

func (*PushMessageResponse) ProtoReflect

func (x *PushMessageResponse) ProtoReflect() protoreflect.Message

func (*PushMessageResponse) Reset

func (x *PushMessageResponse) Reset()

func (*PushMessageResponse) String

func (x *PushMessageResponse) String() string

func (*PushMessageResponse) UnmarshalJSON

func (msg *PushMessageResponse) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

func (*PushMessageResponse) Validate

func (m *PushMessageResponse) Validate() error

Validate checks the field values on PushMessageResponse 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 (*PushMessageResponse) ValidateAll

func (m *PushMessageResponse) ValidateAll() error

ValidateAll checks the field values on PushMessageResponse 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 PushMessageResponseMultiError, or nil if none found.

type PushMessageResponseMultiError

type PushMessageResponseMultiError []error

PushMessageResponseMultiError is an error wrapping multiple validation errors returned by PushMessageResponse.ValidateAll() if the designated constraints aren't met.

func (PushMessageResponseMultiError) AllErrors

func (m PushMessageResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (PushMessageResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type PushMessageResponseValidationError

type PushMessageResponseValidationError struct {
	// contains filtered or unexported fields
}

PushMessageResponseValidationError is the validation error returned by PushMessageResponse.Validate if the designated constraints aren't met.

func (PushMessageResponseValidationError) Cause

Cause function returns cause value.

func (PushMessageResponseValidationError) Error

Error satisfies the builtin error interface

func (PushMessageResponseValidationError) ErrorName

ErrorName returns error name.

func (PushMessageResponseValidationError) Field

Field function returns field value.

func (PushMessageResponseValidationError) Key

Key function returns key value.

func (PushMessageResponseValidationError) Reason

Reason function returns reason value.

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.
This package is intended for internal use by connect-grpc-go, and provides no backward compatibility guarantees whatsoever.
This package is intended for internal use by connect-grpc-go, and provides no backward compatibility guarantees whatsoever.
fake
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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