healthv1

package
v0.0.0-...-3c43ea6 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: MIT Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	HealthCheckResponse_ServingStatus_name = map[int32]string{
		0: "UNKNOWN",
		1: "SERVING",
		2: "NOT_SERVING",
		3: "SERVICE_UNKNOWN",
	}
	HealthCheckResponse_ServingStatus_value = map[string]int32{
		"UNKNOWN":         0,
		"SERVING":         1,
		"NOT_SERVING":     2,
		"SERVICE_UNKNOWN": 3,
	}
)

Enum value maps for HealthCheckResponse_ServingStatus.

View Source
var File_grpc_health_v1_health_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type HealthCheckRequest

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

func (*HealthCheckRequest) Default

func (x *HealthCheckRequest) Default()

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=grpc.health.v1.HealthCheckResponse_ServingStatus" json:"status,omitempty"`
	// contains filtered or unexported fields
}

func (*HealthCheckResponse) Default

func (x *HealthCheckResponse) Default()

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_UNKNOWN         HealthCheckResponse_ServingStatus = 0
	HealthCheckResponse_SERVING         HealthCheckResponse_ServingStatus = 1
	HealthCheckResponse_NOT_SERVING     HealthCheckResponse_ServingStatus = 2
	HealthCheckResponse_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 grpc.health.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 grpc.health.v1.HealthServiceClient client.

type HealthServiceRegistry

type HealthServiceRegistry map[string]HealthService

HealthServiceRegistry represents a map of grpc.health.v1.HealthService service.

func (*HealthServiceRegistry) Check

Check checks the health of a given service.

type NopHealthServiceClient

type NopHealthServiceClient struct{}

NopHealthServiceClient is a no-op implementation of the grpc.health.v1.HealthServiceClient client.

func (*NopHealthServiceClient) Check

Check implements HealthServiceClient.

Directories

Path Synopsis
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