kinesisv1

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

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

Go to latest
Published: May 15, 2024 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Overview

Package kinesisv1 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	KinesisAPI_GetStream_FullMethodName        = "/clutch.aws.kinesis.v1.KinesisAPI/GetStream"
	KinesisAPI_UpdateShardCount_FullMethodName = "/clutch.aws.kinesis.v1.KinesisAPI/UpdateShardCount"
)

Variables

View Source
var File_aws_kinesis_v1_kinesis_proto protoreflect.FileDescriptor
View Source
var KinesisAPI_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "clutch.aws.kinesis.v1.KinesisAPI",
	HandlerType: (*KinesisAPIServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetStream",
			Handler:    _KinesisAPI_GetStream_Handler,
		},
		{
			MethodName: "UpdateShardCount",
			Handler:    _KinesisAPI_UpdateShardCount_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "aws/kinesis/v1/kinesis.proto",
}

KinesisAPI_ServiceDesc is the grpc.ServiceDesc for KinesisAPI service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterKinesisAPIHandler

func RegisterKinesisAPIHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterKinesisAPIHandler registers the http handlers for service KinesisAPI to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterKinesisAPIHandlerClient

func RegisterKinesisAPIHandlerClient(ctx context.Context, mux *runtime.ServeMux, client KinesisAPIClient) error

RegisterKinesisAPIHandlerClient registers the http handlers for service KinesisAPI to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "KinesisAPIClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "KinesisAPIClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "KinesisAPIClient" to call the correct interceptors.

func RegisterKinesisAPIHandlerFromEndpoint

func RegisterKinesisAPIHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterKinesisAPIHandlerFromEndpoint is same as RegisterKinesisAPIHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterKinesisAPIHandlerServer

func RegisterKinesisAPIHandlerServer(ctx context.Context, mux *runtime.ServeMux, server KinesisAPIServer) error

RegisterKinesisAPIHandlerServer registers the http handlers for service KinesisAPI to "mux". UnaryRPC :call KinesisAPIServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterKinesisAPIHandlerFromEndpoint instead.

func RegisterKinesisAPIServer

func RegisterKinesisAPIServer(s grpc.ServiceRegistrar, srv KinesisAPIServer)

Types

type GetStreamRequest

type GetStreamRequest struct {
	StreamName string `protobuf:"bytes,1,opt,name=stream_name,json=streamName,proto3" json:"stream_name,omitempty"`
	Region     string `protobuf:"bytes,2,opt,name=region,proto3" json:"region,omitempty"`
	Account    string `protobuf:"bytes,3,opt,name=account,proto3" json:"account,omitempty"`
	// contains filtered or unexported fields
}

func (*GetStreamRequest) Descriptor deprecated

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

Deprecated: Use GetStreamRequest.ProtoReflect.Descriptor instead.

func (*GetStreamRequest) GetAccount

func (x *GetStreamRequest) GetAccount() string

func (*GetStreamRequest) GetRegion

func (x *GetStreamRequest) GetRegion() string

func (*GetStreamRequest) GetStreamName

func (x *GetStreamRequest) GetStreamName() string

func (*GetStreamRequest) ProtoMessage

func (*GetStreamRequest) ProtoMessage()

func (*GetStreamRequest) ProtoReflect

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

func (*GetStreamRequest) Reset

func (x *GetStreamRequest) Reset()

func (*GetStreamRequest) String

func (x *GetStreamRequest) String() string

func (*GetStreamRequest) Validate

func (m *GetStreamRequest) Validate() error

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

func (m *GetStreamRequest) ValidateAll() error

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

type GetStreamRequestMultiError

type GetStreamRequestMultiError []error

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

func (GetStreamRequestMultiError) AllErrors

func (m GetStreamRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (GetStreamRequestMultiError) Error

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

type GetStreamRequestValidationError

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

GetStreamRequestValidationError is the validation error returned by GetStreamRequest.Validate if the designated constraints aren't met.

func (GetStreamRequestValidationError) Cause

Cause function returns cause value.

func (GetStreamRequestValidationError) Error

Error satisfies the builtin error interface

func (GetStreamRequestValidationError) ErrorName

ErrorName returns error name.

func (GetStreamRequestValidationError) Field

Field function returns field value.

func (GetStreamRequestValidationError) Key

Key function returns key value.

func (GetStreamRequestValidationError) Reason

Reason function returns reason value.

type GetStreamResponse

type GetStreamResponse struct {
	Stream *Stream `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	// contains filtered or unexported fields
}

func (*GetStreamResponse) Descriptor deprecated

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

Deprecated: Use GetStreamResponse.ProtoReflect.Descriptor instead.

func (*GetStreamResponse) GetStream

func (x *GetStreamResponse) GetStream() *Stream

func (*GetStreamResponse) ProtoMessage

func (*GetStreamResponse) ProtoMessage()

func (*GetStreamResponse) ProtoReflect

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

func (*GetStreamResponse) Reset

func (x *GetStreamResponse) Reset()

func (*GetStreamResponse) String

func (x *GetStreamResponse) String() string

func (*GetStreamResponse) Validate

func (m *GetStreamResponse) Validate() error

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

func (m *GetStreamResponse) ValidateAll() error

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

type GetStreamResponseMultiError

type GetStreamResponseMultiError []error

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

func (GetStreamResponseMultiError) AllErrors

func (m GetStreamResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (GetStreamResponseMultiError) Error

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

type GetStreamResponseValidationError

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

GetStreamResponseValidationError is the validation error returned by GetStreamResponse.Validate if the designated constraints aren't met.

func (GetStreamResponseValidationError) Cause

Cause function returns cause value.

func (GetStreamResponseValidationError) Error

Error satisfies the builtin error interface

func (GetStreamResponseValidationError) ErrorName

ErrorName returns error name.

func (GetStreamResponseValidationError) Field

Field function returns field value.

func (GetStreamResponseValidationError) Key

Key function returns key value.

func (GetStreamResponseValidationError) Reason

Reason function returns reason value.

type KinesisAPIClient

type KinesisAPIClient interface {
	GetStream(ctx context.Context, in *GetStreamRequest, opts ...grpc.CallOption) (*GetStreamResponse, error)
	UpdateShardCount(ctx context.Context, in *UpdateShardCountRequest, opts ...grpc.CallOption) (*UpdateShardCountResponse, error)
}

KinesisAPIClient is the client API for KinesisAPI service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.golang.ir/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewKinesisAPIClient

func NewKinesisAPIClient(cc grpc.ClientConnInterface) KinesisAPIClient

type KinesisAPIServer

type KinesisAPIServer interface {
	GetStream(context.Context, *GetStreamRequest) (*GetStreamResponse, error)
	UpdateShardCount(context.Context, *UpdateShardCountRequest) (*UpdateShardCountResponse, error)
}

KinesisAPIServer is the server API for KinesisAPI service. All implementations should embed UnimplementedKinesisAPIServer for forward compatibility

type Stream

type Stream struct {
	StreamName        string `protobuf:"bytes,1,opt,name=stream_name,json=streamName,proto3" json:"stream_name,omitempty"`
	Region            string `protobuf:"bytes,2,opt,name=region,proto3" json:"region,omitempty"`
	CurrentShardCount int32  `protobuf:"varint,3,opt,name=current_shard_count,json=currentShardCount,proto3" json:"current_shard_count,omitempty"`
	Account           string `protobuf:"bytes,4,opt,name=account,proto3" json:"account,omitempty"`
	// contains filtered or unexported fields
}

func (*Stream) Descriptor deprecated

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

Deprecated: Use Stream.ProtoReflect.Descriptor instead.

func (*Stream) GetAccount

func (x *Stream) GetAccount() string

func (*Stream) GetCurrentShardCount

func (x *Stream) GetCurrentShardCount() int32

func (*Stream) GetRegion

func (x *Stream) GetRegion() string

func (*Stream) GetStreamName

func (x *Stream) GetStreamName() string

func (*Stream) ProtoMessage

func (*Stream) ProtoMessage()

func (*Stream) ProtoReflect

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

func (*Stream) Reset

func (x *Stream) Reset()

func (*Stream) String

func (x *Stream) String() string

func (*Stream) Validate

func (m *Stream) Validate() error

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

func (m *Stream) ValidateAll() error

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

type StreamMultiError

type StreamMultiError []error

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

func (StreamMultiError) AllErrors

func (m StreamMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (StreamMultiError) Error

func (m StreamMultiError) Error() string

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

type StreamValidationError

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

StreamValidationError is the validation error returned by Stream.Validate if the designated constraints aren't met.

func (StreamValidationError) Cause

func (e StreamValidationError) Cause() error

Cause function returns cause value.

func (StreamValidationError) Error

func (e StreamValidationError) Error() string

Error satisfies the builtin error interface

func (StreamValidationError) ErrorName

func (e StreamValidationError) ErrorName() string

ErrorName returns error name.

func (StreamValidationError) Field

func (e StreamValidationError) Field() string

Field function returns field value.

func (StreamValidationError) Key

func (e StreamValidationError) Key() bool

Key function returns key value.

func (StreamValidationError) Reason

func (e StreamValidationError) Reason() string

Reason function returns reason value.

type UnimplementedKinesisAPIServer

type UnimplementedKinesisAPIServer struct {
}

UnimplementedKinesisAPIServer should be embedded to have forward compatible implementations.

func (UnimplementedKinesisAPIServer) GetStream

func (UnimplementedKinesisAPIServer) UpdateShardCount

type UnsafeKinesisAPIServer

type UnsafeKinesisAPIServer interface {
	// contains filtered or unexported methods
}

UnsafeKinesisAPIServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to KinesisAPIServer will result in compilation errors.

type UpdateShardCountRequest

type UpdateShardCountRequest struct {
	StreamName       string `protobuf:"bytes,1,opt,name=stream_name,json=streamName,proto3" json:"stream_name,omitempty"`
	Region           string `protobuf:"bytes,2,opt,name=region,proto3" json:"region,omitempty"`
	TargetShardCount int32  `protobuf:"varint,3,opt,name=target_shard_count,json=targetShardCount,proto3" json:"target_shard_count,omitempty"`
	Account          string `protobuf:"bytes,4,opt,name=account,proto3" json:"account,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateShardCountRequest) Descriptor deprecated

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

Deprecated: Use UpdateShardCountRequest.ProtoReflect.Descriptor instead.

func (*UpdateShardCountRequest) GetAccount

func (x *UpdateShardCountRequest) GetAccount() string

func (*UpdateShardCountRequest) GetRegion

func (x *UpdateShardCountRequest) GetRegion() string

func (*UpdateShardCountRequest) GetStreamName

func (x *UpdateShardCountRequest) GetStreamName() string

func (*UpdateShardCountRequest) GetTargetShardCount

func (x *UpdateShardCountRequest) GetTargetShardCount() int32

func (*UpdateShardCountRequest) ProtoMessage

func (*UpdateShardCountRequest) ProtoMessage()

func (*UpdateShardCountRequest) ProtoReflect

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

func (*UpdateShardCountRequest) Reset

func (x *UpdateShardCountRequest) Reset()

func (*UpdateShardCountRequest) String

func (x *UpdateShardCountRequest) String() string

func (*UpdateShardCountRequest) Validate

func (m *UpdateShardCountRequest) Validate() error

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

func (m *UpdateShardCountRequest) ValidateAll() error

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

type UpdateShardCountRequestMultiError

type UpdateShardCountRequestMultiError []error

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

func (UpdateShardCountRequestMultiError) AllErrors

func (m UpdateShardCountRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UpdateShardCountRequestMultiError) Error

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

type UpdateShardCountRequestValidationError

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

UpdateShardCountRequestValidationError is the validation error returned by UpdateShardCountRequest.Validate if the designated constraints aren't met.

func (UpdateShardCountRequestValidationError) Cause

Cause function returns cause value.

func (UpdateShardCountRequestValidationError) Error

Error satisfies the builtin error interface

func (UpdateShardCountRequestValidationError) ErrorName

ErrorName returns error name.

func (UpdateShardCountRequestValidationError) Field

Field function returns field value.

func (UpdateShardCountRequestValidationError) Key

Key function returns key value.

func (UpdateShardCountRequestValidationError) Reason

Reason function returns reason value.

type UpdateShardCountResponse

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

func (*UpdateShardCountResponse) Descriptor deprecated

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

Deprecated: Use UpdateShardCountResponse.ProtoReflect.Descriptor instead.

func (*UpdateShardCountResponse) ProtoMessage

func (*UpdateShardCountResponse) ProtoMessage()

func (*UpdateShardCountResponse) ProtoReflect

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

func (*UpdateShardCountResponse) Reset

func (x *UpdateShardCountResponse) Reset()

func (*UpdateShardCountResponse) String

func (x *UpdateShardCountResponse) String() string

func (*UpdateShardCountResponse) Validate

func (m *UpdateShardCountResponse) Validate() error

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

func (m *UpdateShardCountResponse) ValidateAll() error

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

type UpdateShardCountResponseMultiError

type UpdateShardCountResponseMultiError []error

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

func (UpdateShardCountResponseMultiError) AllErrors

func (m UpdateShardCountResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UpdateShardCountResponseMultiError) Error

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

type UpdateShardCountResponseValidationError

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

UpdateShardCountResponseValidationError is the validation error returned by UpdateShardCountResponse.Validate if the designated constraints aren't met.

func (UpdateShardCountResponseValidationError) Cause

Cause function returns cause value.

func (UpdateShardCountResponseValidationError) Error

Error satisfies the builtin error interface

func (UpdateShardCountResponseValidationError) ErrorName

ErrorName returns error name.

func (UpdateShardCountResponseValidationError) Field

Field function returns field value.

func (UpdateShardCountResponseValidationError) Key

Key function returns key value.

func (UpdateShardCountResponseValidationError) Reason

Reason function returns reason value.

Jump to

Keyboard shortcuts

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