Documentation ¶
Overview ¶
Package beta is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Variables
- func RegisterSDKHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterSDKHandlerClient(ctx context.Context, mux *runtime.ServeMux, client SDKClient) error
- func RegisterSDKHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterSDKHandlerServer(ctx context.Context, mux *runtime.ServeMux, server SDKServer) error
- func RegisterSDKServer(s grpc.ServiceRegistrar, srv SDKServer)
- type AddListValueRequest
- func (*AddListValueRequest) Descriptor() ([]byte, []int)deprecated
- func (x *AddListValueRequest) GetName() string
- func (x *AddListValueRequest) GetValue() string
- func (*AddListValueRequest) ProtoMessage()
- func (x *AddListValueRequest) ProtoReflect() protoreflect.Message
- func (x *AddListValueRequest) Reset()
- func (x *AddListValueRequest) String() string
- type Counter
- func (*Counter) Descriptor() ([]byte, []int)deprecated
- func (x *Counter) GetCapacity() int64
- func (x *Counter) GetCount() int64
- func (x *Counter) GetName() string
- func (*Counter) ProtoMessage()
- func (x *Counter) ProtoReflect() protoreflect.Message
- func (x *Counter) Reset()
- func (x *Counter) String() string
- type CounterUpdateRequest
- func (*CounterUpdateRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CounterUpdateRequest) GetCapacity() *wrapperspb.Int64Value
- func (x *CounterUpdateRequest) GetCount() *wrapperspb.Int64Value
- func (x *CounterUpdateRequest) GetCountDiff() int64
- func (x *CounterUpdateRequest) GetName() string
- func (*CounterUpdateRequest) ProtoMessage()
- func (x *CounterUpdateRequest) ProtoReflect() protoreflect.Message
- func (x *CounterUpdateRequest) Reset()
- func (x *CounterUpdateRequest) String() string
- type Empty
- type GetCounterRequest
- type GetListRequest
- type List
- type RemoveListValueRequest
- func (*RemoveListValueRequest) Descriptor() ([]byte, []int)deprecated
- func (x *RemoveListValueRequest) GetName() string
- func (x *RemoveListValueRequest) GetValue() string
- func (*RemoveListValueRequest) ProtoMessage()
- func (x *RemoveListValueRequest) ProtoReflect() protoreflect.Message
- func (x *RemoveListValueRequest) Reset()
- func (x *RemoveListValueRequest) String() string
- type SDKClient
- type SDKServer
- type UnimplementedSDKServer
- func (UnimplementedSDKServer) AddListValue(context.Context, *AddListValueRequest) (*List, error)
- func (UnimplementedSDKServer) GetCounter(context.Context, *GetCounterRequest) (*Counter, error)
- func (UnimplementedSDKServer) GetList(context.Context, *GetListRequest) (*List, error)
- func (UnimplementedSDKServer) RemoveListValue(context.Context, *RemoveListValueRequest) (*List, error)
- func (UnimplementedSDKServer) UpdateCounter(context.Context, *UpdateCounterRequest) (*Counter, error)
- func (UnimplementedSDKServer) UpdateList(context.Context, *UpdateListRequest) (*List, error)
- type UnsafeSDKServer
- type UpdateCounterRequest
- func (*UpdateCounterRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateCounterRequest) GetCounterUpdateRequest() *CounterUpdateRequest
- func (*UpdateCounterRequest) ProtoMessage()
- func (x *UpdateCounterRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateCounterRequest) Reset()
- func (x *UpdateCounterRequest) String() string
- type UpdateListRequest
- func (*UpdateListRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateListRequest) GetList() *List
- func (x *UpdateListRequest) GetUpdateMask() *fieldmaskpb.FieldMask
- func (*UpdateListRequest) ProtoMessage()
- func (x *UpdateListRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateListRequest) Reset()
- func (x *UpdateListRequest) String() string
Constants ¶
This section is empty.
Variables ¶
var File_beta_proto protoreflect.FileDescriptor
var SDK_ServiceDesc = grpc.ServiceDesc{ ServiceName: "agones.dev.sdk.beta.SDK", HandlerType: (*SDKServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetCounter", Handler: _SDK_GetCounter_Handler, }, { MethodName: "UpdateCounter", Handler: _SDK_UpdateCounter_Handler, }, { MethodName: "GetList", Handler: _SDK_GetList_Handler, }, { MethodName: "UpdateList", Handler: _SDK_UpdateList_Handler, }, { MethodName: "AddListValue", Handler: _SDK_AddListValue_Handler, }, { MethodName: "RemoveListValue", Handler: _SDK_RemoveListValue_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "beta.proto", }
SDK_ServiceDesc is the grpc.ServiceDesc for SDK service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterSDKHandler ¶ added in v1.41.0
RegisterSDKHandler registers the http handlers for service SDK to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterSDKHandlerClient ¶ added in v1.41.0
RegisterSDKHandlerClient registers the http handlers for service SDK to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "SDKClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "SDKClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "SDKClient" to call the correct interceptors.
func RegisterSDKHandlerFromEndpoint ¶ added in v1.41.0
func RegisterSDKHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterSDKHandlerFromEndpoint is same as RegisterSDKHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterSDKHandlerServer ¶ added in v1.41.0
RegisterSDKHandlerServer registers the http handlers for service SDK to "mux". UnaryRPC :call SDKServer 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 RegisterSDKHandlerFromEndpoint instead.
func RegisterSDKServer ¶
func RegisterSDKServer(s grpc.ServiceRegistrar, srv SDKServer)
Types ¶
type AddListValueRequest ¶ added in v1.41.0
type AddListValueRequest struct { // The name of the List to add a value to. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
func (*AddListValueRequest) Descriptor
deprecated
added in
v1.41.0
func (*AddListValueRequest) Descriptor() ([]byte, []int)
Deprecated: Use AddListValueRequest.ProtoReflect.Descriptor instead.
func (*AddListValueRequest) GetName ¶ added in v1.41.0
func (x *AddListValueRequest) GetName() string
func (*AddListValueRequest) GetValue ¶ added in v1.41.0
func (x *AddListValueRequest) GetValue() string
func (*AddListValueRequest) ProtoMessage ¶ added in v1.41.0
func (*AddListValueRequest) ProtoMessage()
func (*AddListValueRequest) ProtoReflect ¶ added in v1.41.0
func (x *AddListValueRequest) ProtoReflect() protoreflect.Message
func (*AddListValueRequest) Reset ¶ added in v1.41.0
func (x *AddListValueRequest) Reset()
func (*AddListValueRequest) String ¶ added in v1.41.0
func (x *AddListValueRequest) String() string
type Counter ¶ added in v1.41.0
type Counter struct { // The name of the Counter Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // The current count of the Counter Count int64 `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"` // The maximum capacity of the Counter Capacity int64 `protobuf:"varint,3,opt,name=capacity,proto3" json:"capacity,omitempty"` // contains filtered or unexported fields }
A representation of a Counter.
func (*Counter) Descriptor
deprecated
added in
v1.41.0
func (*Counter) GetCapacity ¶ added in v1.41.0
func (*Counter) ProtoMessage ¶ added in v1.41.0
func (*Counter) ProtoMessage()
func (*Counter) ProtoReflect ¶ added in v1.41.0
func (x *Counter) ProtoReflect() protoreflect.Message
type CounterUpdateRequest ¶ added in v1.41.0
type CounterUpdateRequest struct { // The name of the Counter to update Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // The value to set the Counter Count Count *wrapperspb.Int64Value `protobuf:"bytes,2,opt,name=count,proto3" json:"count,omitempty"` // The value to set the Counter Capacity Capacity *wrapperspb.Int64Value `protobuf:"bytes,3,opt,name=capacity,proto3" json:"capacity,omitempty"` // countDiff tracks if a Counter Update Request is CountIncrement (positive), CountDecrement // (negative), 0 if a CountSet or CapacitySet request CountDiff int64 `protobuf:"varint,4,opt,name=countDiff,proto3" json:"countDiff,omitempty"` // contains filtered or unexported fields }
A representation of a Counter Update Request.
func (*CounterUpdateRequest) Descriptor
deprecated
added in
v1.41.0
func (*CounterUpdateRequest) Descriptor() ([]byte, []int)
Deprecated: Use CounterUpdateRequest.ProtoReflect.Descriptor instead.
func (*CounterUpdateRequest) GetCapacity ¶ added in v1.41.0
func (x *CounterUpdateRequest) GetCapacity() *wrapperspb.Int64Value
func (*CounterUpdateRequest) GetCount ¶ added in v1.41.0
func (x *CounterUpdateRequest) GetCount() *wrapperspb.Int64Value
func (*CounterUpdateRequest) GetCountDiff ¶ added in v1.41.0
func (x *CounterUpdateRequest) GetCountDiff() int64
func (*CounterUpdateRequest) GetName ¶ added in v1.41.0
func (x *CounterUpdateRequest) GetName() string
func (*CounterUpdateRequest) ProtoMessage ¶ added in v1.41.0
func (*CounterUpdateRequest) ProtoMessage()
func (*CounterUpdateRequest) ProtoReflect ¶ added in v1.41.0
func (x *CounterUpdateRequest) ProtoReflect() protoreflect.Message
func (*CounterUpdateRequest) Reset ¶ added in v1.41.0
func (x *CounterUpdateRequest) Reset()
func (*CounterUpdateRequest) String ¶ added in v1.41.0
func (x *CounterUpdateRequest) String() string
type Empty ¶ added in v1.41.0
type Empty struct {
// contains filtered or unexported fields
}
I am Empty
func (*Empty) Descriptor
deprecated
added in
v1.41.0
func (*Empty) ProtoMessage ¶ added in v1.41.0
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶ added in v1.41.0
func (x *Empty) ProtoReflect() protoreflect.Message
type GetCounterRequest ¶ added in v1.41.0
type GetCounterRequest struct { // The name of the Counter to get Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*GetCounterRequest) Descriptor
deprecated
added in
v1.41.0
func (*GetCounterRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetCounterRequest.ProtoReflect.Descriptor instead.
func (*GetCounterRequest) GetName ¶ added in v1.41.0
func (x *GetCounterRequest) GetName() string
func (*GetCounterRequest) ProtoMessage ¶ added in v1.41.0
func (*GetCounterRequest) ProtoMessage()
func (*GetCounterRequest) ProtoReflect ¶ added in v1.41.0
func (x *GetCounterRequest) ProtoReflect() protoreflect.Message
func (*GetCounterRequest) Reset ¶ added in v1.41.0
func (x *GetCounterRequest) Reset()
func (*GetCounterRequest) String ¶ added in v1.41.0
func (x *GetCounterRequest) String() string
type GetListRequest ¶ added in v1.41.0
type GetListRequest struct { // The name of the List to get Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*GetListRequest) Descriptor
deprecated
added in
v1.41.0
func (*GetListRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetListRequest.ProtoReflect.Descriptor instead.
func (*GetListRequest) GetName ¶ added in v1.41.0
func (x *GetListRequest) GetName() string
func (*GetListRequest) ProtoMessage ¶ added in v1.41.0
func (*GetListRequest) ProtoMessage()
func (*GetListRequest) ProtoReflect ¶ added in v1.41.0
func (x *GetListRequest) ProtoReflect() protoreflect.Message
func (*GetListRequest) Reset ¶ added in v1.41.0
func (x *GetListRequest) Reset()
func (*GetListRequest) String ¶ added in v1.41.0
func (x *GetListRequest) String() string
type List ¶ added in v1.41.0
type List struct { // The name of the List Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // The maximum capacity of the List Capacity int64 `protobuf:"varint,2,opt,name=capacity,proto3" json:"capacity,omitempty"` // The array of items in the List ["v1", "v2", …] Values []string `protobuf:"bytes,3,rep,name=values,proto3" json:"values,omitempty"` // contains filtered or unexported fields }
A representation of a List.
func (*List) Descriptor
deprecated
added in
v1.41.0
func (*List) GetCapacity ¶ added in v1.41.0
func (*List) ProtoMessage ¶ added in v1.41.0
func (*List) ProtoMessage()
func (*List) ProtoReflect ¶ added in v1.41.0
func (x *List) ProtoReflect() protoreflect.Message
type RemoveListValueRequest ¶ added in v1.41.0
type RemoveListValueRequest struct { // The name of the List to remove a value from. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
func (*RemoveListValueRequest) Descriptor
deprecated
added in
v1.41.0
func (*RemoveListValueRequest) Descriptor() ([]byte, []int)
Deprecated: Use RemoveListValueRequest.ProtoReflect.Descriptor instead.
func (*RemoveListValueRequest) GetName ¶ added in v1.41.0
func (x *RemoveListValueRequest) GetName() string
func (*RemoveListValueRequest) GetValue ¶ added in v1.41.0
func (x *RemoveListValueRequest) GetValue() string
func (*RemoveListValueRequest) ProtoMessage ¶ added in v1.41.0
func (*RemoveListValueRequest) ProtoMessage()
func (*RemoveListValueRequest) ProtoReflect ¶ added in v1.41.0
func (x *RemoveListValueRequest) ProtoReflect() protoreflect.Message
func (*RemoveListValueRequest) Reset ¶ added in v1.41.0
func (x *RemoveListValueRequest) Reset()
func (*RemoveListValueRequest) String ¶ added in v1.41.0
func (x *RemoveListValueRequest) String() string
type SDKClient ¶
type SDKClient interface { // Gets a Counter. Returns NOT_FOUND if the Counter does not exist. GetCounter(ctx context.Context, in *GetCounterRequest, opts ...grpc.CallOption) (*Counter, error) // UpdateCounter returns the updated Counter. Returns NOT_FOUND if the Counter does not exist (name cannot be updated). // Returns OUT_OF_RANGE if the Count is out of range [0,Capacity]. UpdateCounter(ctx context.Context, in *UpdateCounterRequest, opts ...grpc.CallOption) (*Counter, error) // Gets a List. Returns NOT_FOUND if the List does not exist. GetList(ctx context.Context, in *GetListRequest, opts ...grpc.CallOption) (*List, error) // UpdateList returns the updated List. Returns NOT_FOUND if the List does not exist (name cannot be updated). // **THIS WILL OVERWRITE ALL EXISTING LIST.VALUES WITH ANY REQUEST LIST.VALUES** // Use AddListValue() or RemoveListValue() for modifying the List.Values field. // Returns INVALID_ARGUMENT if the field mask path(s) are not field(s) of the List. // If a field mask path(s) is specified, but the value is not set in the request List object, // then the default value for the variable will be set (i.e. 0 for "capacity", empty list for "values"). UpdateList(ctx context.Context, in *UpdateListRequest, opts ...grpc.CallOption) (*List, error) // Adds a value to a List and returns updated List. Returns NOT_FOUND if the List does not exist. // Returns ALREADY_EXISTS if the value is already in the List. // Returns OUT_OF_RANGE if the List is already at Capacity. AddListValue(ctx context.Context, in *AddListValueRequest, opts ...grpc.CallOption) (*List, error) // Removes a value from a List and returns updated List. Returns NOT_FOUND if the List does not exist. // Returns NOT_FOUND if the value is not in the List. RemoveListValue(ctx context.Context, in *RemoveListValueRequest, opts ...grpc.CallOption) (*List, error) }
SDKClient is the client API for SDK 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 NewSDKClient ¶
func NewSDKClient(cc grpc.ClientConnInterface) SDKClient
type SDKServer ¶
type SDKServer interface { // Gets a Counter. Returns NOT_FOUND if the Counter does not exist. GetCounter(context.Context, *GetCounterRequest) (*Counter, error) // UpdateCounter returns the updated Counter. Returns NOT_FOUND if the Counter does not exist (name cannot be updated). // Returns OUT_OF_RANGE if the Count is out of range [0,Capacity]. UpdateCounter(context.Context, *UpdateCounterRequest) (*Counter, error) // Gets a List. Returns NOT_FOUND if the List does not exist. GetList(context.Context, *GetListRequest) (*List, error) // UpdateList returns the updated List. Returns NOT_FOUND if the List does not exist (name cannot be updated). // **THIS WILL OVERWRITE ALL EXISTING LIST.VALUES WITH ANY REQUEST LIST.VALUES** // Use AddListValue() or RemoveListValue() for modifying the List.Values field. // Returns INVALID_ARGUMENT if the field mask path(s) are not field(s) of the List. // If a field mask path(s) is specified, but the value is not set in the request List object, // then the default value for the variable will be set (i.e. 0 for "capacity", empty list for "values"). UpdateList(context.Context, *UpdateListRequest) (*List, error) // Adds a value to a List and returns updated List. Returns NOT_FOUND if the List does not exist. // Returns ALREADY_EXISTS if the value is already in the List. // Returns OUT_OF_RANGE if the List is already at Capacity. AddListValue(context.Context, *AddListValueRequest) (*List, error) // Removes a value from a List and returns updated List. Returns NOT_FOUND if the List does not exist. // Returns NOT_FOUND if the value is not in the List. RemoveListValue(context.Context, *RemoveListValueRequest) (*List, error) }
SDKServer is the server API for SDK service. All implementations should embed UnimplementedSDKServer for forward compatibility
type UnimplementedSDKServer ¶ added in v1.29.0
type UnimplementedSDKServer struct { }
UnimplementedSDKServer should be embedded to have forward compatible implementations.
func (UnimplementedSDKServer) AddListValue ¶ added in v1.41.0
func (UnimplementedSDKServer) AddListValue(context.Context, *AddListValueRequest) (*List, error)
func (UnimplementedSDKServer) GetCounter ¶ added in v1.41.0
func (UnimplementedSDKServer) GetCounter(context.Context, *GetCounterRequest) (*Counter, error)
func (UnimplementedSDKServer) GetList ¶ added in v1.41.0
func (UnimplementedSDKServer) GetList(context.Context, *GetListRequest) (*List, error)
func (UnimplementedSDKServer) RemoveListValue ¶ added in v1.41.0
func (UnimplementedSDKServer) RemoveListValue(context.Context, *RemoveListValueRequest) (*List, error)
func (UnimplementedSDKServer) UpdateCounter ¶ added in v1.41.0
func (UnimplementedSDKServer) UpdateCounter(context.Context, *UpdateCounterRequest) (*Counter, error)
func (UnimplementedSDKServer) UpdateList ¶ added in v1.41.0
func (UnimplementedSDKServer) UpdateList(context.Context, *UpdateListRequest) (*List, error)
type UnsafeSDKServer ¶ added in v1.29.0
type UnsafeSDKServer interface {
// contains filtered or unexported methods
}
UnsafeSDKServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to SDKServer will result in compilation errors.
type UpdateCounterRequest ¶ added in v1.41.0
type UpdateCounterRequest struct { // The requested update to make to the Counter CounterUpdateRequest *CounterUpdateRequest `protobuf:"bytes,1,opt,name=counterUpdateRequest,proto3" json:"counterUpdateRequest,omitempty"` // contains filtered or unexported fields }
func (*UpdateCounterRequest) Descriptor
deprecated
added in
v1.41.0
func (*UpdateCounterRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateCounterRequest.ProtoReflect.Descriptor instead.
func (*UpdateCounterRequest) GetCounterUpdateRequest ¶ added in v1.41.0
func (x *UpdateCounterRequest) GetCounterUpdateRequest() *CounterUpdateRequest
func (*UpdateCounterRequest) ProtoMessage ¶ added in v1.41.0
func (*UpdateCounterRequest) ProtoMessage()
func (*UpdateCounterRequest) ProtoReflect ¶ added in v1.41.0
func (x *UpdateCounterRequest) ProtoReflect() protoreflect.Message
func (*UpdateCounterRequest) Reset ¶ added in v1.41.0
func (x *UpdateCounterRequest) Reset()
func (*UpdateCounterRequest) String ¶ added in v1.41.0
func (x *UpdateCounterRequest) String() string
type UpdateListRequest ¶ added in v1.41.0
type UpdateListRequest struct { // The List to update List *List `protobuf:"bytes,1,opt,name=list,proto3" json:"list,omitempty"` // Required. Mask (list) of fields to update. // Fields are specified relative to the List // (e.g. `capacity`, `values`; *not* `List.capacity` or `List.values`). UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"` // contains filtered or unexported fields }
func (*UpdateListRequest) Descriptor
deprecated
added in
v1.41.0
func (*UpdateListRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateListRequest.ProtoReflect.Descriptor instead.
func (*UpdateListRequest) GetList ¶ added in v1.41.0
func (x *UpdateListRequest) GetList() *List
func (*UpdateListRequest) GetUpdateMask ¶ added in v1.41.0
func (x *UpdateListRequest) GetUpdateMask() *fieldmaskpb.FieldMask
func (*UpdateListRequest) ProtoMessage ¶ added in v1.41.0
func (*UpdateListRequest) ProtoMessage()
func (*UpdateListRequest) ProtoReflect ¶ added in v1.41.0
func (x *UpdateListRequest) ProtoReflect() protoreflect.Message
func (*UpdateListRequest) Reset ¶ added in v1.41.0
func (x *UpdateListRequest) Reset()
func (*UpdateListRequest) String ¶ added in v1.41.0
func (x *UpdateListRequest) String() string