opensaves

package
v0.2.0-beta2 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2021 License: Apache-2.0 Imports: 11 Imported by: 0

README

Open Saves API

This directory contains both the proto and generated Go code for running Open Saves.

open_saves.proto contains the source definition.

open_saves.pb.go is generated code containing message definitions.

open_saves_grpc.pb.go is generated code containing service definitions.

Proto documentation

To generate the reference page from open_saves.proto, do the following:

  1. Download the latest release of Protocol Buffers.

  2. Place the protoc binary somewhere in your PATH.

  3. Install the latest release of protoc-gen-doc.

  4. Run the following command:

    protoc \
       --proto_path=<path-to-protoc-include-dir> \
       --proto_path=<path-to-proto-dir> \
       --doc_out=<path-to-output-docs-folder> \
       --doc_opt=markdown,reference.md \
       <path-to-proto-file>
    

    The following is an example command:

    protoc \
       --proto_path=$HOME/projects/protoc-3.17.3-osx-x86_64/include/ \
       --proto_path=$HOME/projects/open-saves/api/ \
       --doc_out=$HOME/projects/open-saves/docs/ \
       --doc_opt=markdown,reference.md \
       $HOME/projects/open-saves/api/*.proto
    

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FilterOperator_name = map[int32]string{
		0: "EQUAL",
		1: "GREATER",
		2: "LESS",
		3: "GREATER_OR_EQUAL",
		4: "LESS_OR_EQUAL",
	}
	FilterOperator_value = map[string]int32{
		"EQUAL":            0,
		"GREATER":          1,
		"LESS":             2,
		"GREATER_OR_EQUAL": 3,
		"LESS_OR_EQUAL":    4,
	}
)

Enum value maps for FilterOperator.

View Source
var (
	Property_Type_name = map[int32]string{
		0: "DATATYPE_UNDEFINED",
		1: "INTEGER",
		2: "STRING",
		3: "BOOLEAN",
	}
	Property_Type_value = map[string]int32{
		"DATATYPE_UNDEFINED": 0,
		"INTEGER":            1,
		"STRING":             2,
		"BOOLEAN":            3,
	}
)

Enum value maps for Property_Type.

View Source
var File_api_open_saves_proto protoreflect.FileDescriptor
View Source
var OpenSaves_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "opensaves.OpenSaves",
	HandlerType: (*OpenSavesServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateStore",
			Handler:    _OpenSaves_CreateStore_Handler,
		},
		{
			MethodName: "GetStore",
			Handler:    _OpenSaves_GetStore_Handler,
		},
		{
			MethodName: "ListStores",
			Handler:    _OpenSaves_ListStores_Handler,
		},
		{
			MethodName: "DeleteStore",
			Handler:    _OpenSaves_DeleteStore_Handler,
		},
		{
			MethodName: "CreateRecord",
			Handler:    _OpenSaves_CreateRecord_Handler,
		},
		{
			MethodName: "GetRecord",
			Handler:    _OpenSaves_GetRecord_Handler,
		},
		{
			MethodName: "QueryRecords",
			Handler:    _OpenSaves_QueryRecords_Handler,
		},
		{
			MethodName: "UpdateRecord",
			Handler:    _OpenSaves_UpdateRecord_Handler,
		},
		{
			MethodName: "DeleteRecord",
			Handler:    _OpenSaves_DeleteRecord_Handler,
		},
		{
			MethodName: "CreateChunkedBlob",
			Handler:    _OpenSaves_CreateChunkedBlob_Handler,
		},
		{
			MethodName: "CommitChunkedUpload",
			Handler:    _OpenSaves_CommitChunkedUpload_Handler,
		},
		{
			MethodName: "AbortChunkedUpload",
			Handler:    _OpenSaves_AbortChunkedUpload_Handler,
		},
		{
			MethodName: "DeleteBlob",
			Handler:    _OpenSaves_DeleteBlob_Handler,
		},
		{
			MethodName: "Ping",
			Handler:    _OpenSaves_Ping_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "CreateBlob",
			Handler:       _OpenSaves_CreateBlob_Handler,
			ClientStreams: true,
		},
		{
			StreamName:    "UploadChunk",
			Handler:       _OpenSaves_UploadChunk_Handler,
			ClientStreams: true,
		},
		{
			StreamName:    "GetBlob",
			Handler:       _OpenSaves_GetBlob_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "GetBlobChunk",
			Handler:       _OpenSaves_GetBlobChunk_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "api/open_saves.proto",
}

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

Functions

func RegisterOpenSavesServer

func RegisterOpenSavesServer(s grpc.ServiceRegistrar, srv OpenSavesServer)

Types

type AbortChunkedUploadRequest

type AbortChunkedUploadRequest struct {

	// session_id is the ID of a chunked upload session to abort.
	SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"`
	// contains filtered or unexported fields
}

func (*AbortChunkedUploadRequest) Descriptor deprecated

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

Deprecated: Use AbortChunkedUploadRequest.ProtoReflect.Descriptor instead.

func (*AbortChunkedUploadRequest) GetSessionId

func (x *AbortChunkedUploadRequest) GetSessionId() string

func (*AbortChunkedUploadRequest) ProtoMessage

func (*AbortChunkedUploadRequest) ProtoMessage()

func (*AbortChunkedUploadRequest) ProtoReflect

func (*AbortChunkedUploadRequest) Reset

func (x *AbortChunkedUploadRequest) Reset()

func (*AbortChunkedUploadRequest) String

func (x *AbortChunkedUploadRequest) String() string

type BlobMetadata

type BlobMetadata struct {

	// store_key is the key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// record_key is the key of the record the new blob object belongs to.
	RecordKey string `protobuf:"bytes,2,opt,name=record_key,json=recordKey,proto3" json:"record_key,omitempty"`
	// size is the byte length of the object.
	Size int64 `protobuf:"varint,3,opt,name=size,proto3" json:"size,omitempty"`
	// Performance hints (write only).
	Hint *Hint `protobuf:"bytes,4,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

BlobMetadata contains necessary metadata when creating (uploading) a new blob object.

func (*BlobMetadata) Descriptor deprecated

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

Deprecated: Use BlobMetadata.ProtoReflect.Descriptor instead.

func (*BlobMetadata) GetHint

func (x *BlobMetadata) GetHint() *Hint

func (*BlobMetadata) GetRecordKey

func (x *BlobMetadata) GetRecordKey() string

func (*BlobMetadata) GetSize

func (x *BlobMetadata) GetSize() int64

func (*BlobMetadata) GetStoreKey

func (x *BlobMetadata) GetStoreKey() string

func (*BlobMetadata) ProtoMessage

func (*BlobMetadata) ProtoMessage()

func (*BlobMetadata) ProtoReflect

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

func (*BlobMetadata) Reset

func (x *BlobMetadata) Reset()

func (*BlobMetadata) String

func (x *BlobMetadata) String() string

type ChunkMetadata

type ChunkMetadata struct {

	// session_id is the ID of a chunk upload session. Not used for downloads.
	SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"`
	// number is the number
	Number int64 `protobuf:"varint,2,opt,name=number,proto3" json:"number,omitempty"`
	// size is a byte size of the chunk.
	Size int64 `protobuf:"varint,3,opt,name=size,proto3" json:"size,omitempty"`
	// Performance hints (write only).
	Hint *Hint `protobuf:"bytes,4,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*ChunkMetadata) Descriptor deprecated

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

Deprecated: Use ChunkMetadata.ProtoReflect.Descriptor instead.

func (*ChunkMetadata) GetHint

func (x *ChunkMetadata) GetHint() *Hint

func (*ChunkMetadata) GetNumber

func (x *ChunkMetadata) GetNumber() int64

func (*ChunkMetadata) GetSessionId

func (x *ChunkMetadata) GetSessionId() string

func (*ChunkMetadata) GetSize

func (x *ChunkMetadata) GetSize() int64

func (*ChunkMetadata) ProtoMessage

func (*ChunkMetadata) ProtoMessage()

func (*ChunkMetadata) ProtoReflect

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

func (*ChunkMetadata) Reset

func (x *ChunkMetadata) Reset()

func (*ChunkMetadata) String

func (x *ChunkMetadata) String() string

type CommitChunkedUploadRequest

type CommitChunkedUploadRequest struct {

	// session_id is the ID of a chunked upload session to commit.
	SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"`
	// contains filtered or unexported fields
}

func (*CommitChunkedUploadRequest) Descriptor deprecated

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

Deprecated: Use CommitChunkedUploadRequest.ProtoReflect.Descriptor instead.

func (*CommitChunkedUploadRequest) GetSessionId

func (x *CommitChunkedUploadRequest) GetSessionId() string

func (*CommitChunkedUploadRequest) ProtoMessage

func (*CommitChunkedUploadRequest) ProtoMessage()

func (*CommitChunkedUploadRequest) ProtoReflect

func (*CommitChunkedUploadRequest) Reset

func (x *CommitChunkedUploadRequest) Reset()

func (*CommitChunkedUploadRequest) String

func (x *CommitChunkedUploadRequest) String() string

type CreateBlobRequest

type CreateBlobRequest struct {

	// Types that are assignable to Request:
	//	*CreateBlobRequest_Metadata
	//	*CreateBlobRequest_Content
	Request isCreateBlobRequest_Request `protobuf_oneof:"request"`
	// contains filtered or unexported fields
}

CreateBlobRequest is used for CreateBlob, a client-streaming method. The first message should contain metadata, and the subsequent messages should contain content.

func (*CreateBlobRequest) Descriptor deprecated

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

Deprecated: Use CreateBlobRequest.ProtoReflect.Descriptor instead.

func (*CreateBlobRequest) GetContent

func (x *CreateBlobRequest) GetContent() []byte

func (*CreateBlobRequest) GetMetadata

func (x *CreateBlobRequest) GetMetadata() *BlobMetadata

func (*CreateBlobRequest) GetRequest

func (m *CreateBlobRequest) GetRequest() isCreateBlobRequest_Request

func (*CreateBlobRequest) ProtoMessage

func (*CreateBlobRequest) ProtoMessage()

func (*CreateBlobRequest) ProtoReflect

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

func (*CreateBlobRequest) Reset

func (x *CreateBlobRequest) Reset()

func (*CreateBlobRequest) String

func (x *CreateBlobRequest) String() string

type CreateBlobRequest_Content

type CreateBlobRequest_Content struct {
	// content is the binary content of the blob object.
	Content []byte `protobuf:"bytes,2,opt,name=content,proto3,oneof"`
}

type CreateBlobRequest_Metadata

type CreateBlobRequest_Metadata struct {
	// metadata is the metadata used to initialize the blob object with.
	Metadata *BlobMetadata `protobuf:"bytes,1,opt,name=metadata,proto3,oneof"`
}

type CreateChunkedBlobRequest

type CreateChunkedBlobRequest struct {

	// store_key is the key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// record_key is the key of the record the new blob object belongs to.
	RecordKey string `protobuf:"bytes,2,opt,name=record_key,json=recordKey,proto3" json:"record_key,omitempty"`
	// Size of each chunk
	ChunkSize int64 `protobuf:"varint,3,opt,name=chunk_size,json=chunkSize,proto3" json:"chunk_size,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateChunkedBlobRequest) Descriptor deprecated

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

Deprecated: Use CreateChunkedBlobRequest.ProtoReflect.Descriptor instead.

func (*CreateChunkedBlobRequest) GetChunkSize

func (x *CreateChunkedBlobRequest) GetChunkSize() int64

func (*CreateChunkedBlobRequest) GetRecordKey

func (x *CreateChunkedBlobRequest) GetRecordKey() string

func (*CreateChunkedBlobRequest) GetStoreKey

func (x *CreateChunkedBlobRequest) GetStoreKey() string

func (*CreateChunkedBlobRequest) ProtoMessage

func (*CreateChunkedBlobRequest) ProtoMessage()

func (*CreateChunkedBlobRequest) ProtoReflect

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

func (*CreateChunkedBlobRequest) Reset

func (x *CreateChunkedBlobRequest) Reset()

func (*CreateChunkedBlobRequest) String

func (x *CreateChunkedBlobRequest) String() string

type CreateChunkedBlobResponse

type CreateChunkedBlobResponse struct {

	// session_id is a chunked
	SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateChunkedBlobResponse) Descriptor deprecated

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

Deprecated: Use CreateChunkedBlobResponse.ProtoReflect.Descriptor instead.

func (*CreateChunkedBlobResponse) GetSessionId

func (x *CreateChunkedBlobResponse) GetSessionId() string

func (*CreateChunkedBlobResponse) ProtoMessage

func (*CreateChunkedBlobResponse) ProtoMessage()

func (*CreateChunkedBlobResponse) ProtoReflect

func (*CreateChunkedBlobResponse) Reset

func (x *CreateChunkedBlobResponse) Reset()

func (*CreateChunkedBlobResponse) String

func (x *CreateChunkedBlobResponse) String() string

type CreateRecordRequest

type CreateRecordRequest struct {

	// The key of the store to create the record into.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// The record to create.
	Record *Record `protobuf:"bytes,2,opt,name=record,proto3" json:"record,omitempty"`
	// Performance hints.
	Hint *Hint `protobuf:"bytes,3,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateRecordRequest) Descriptor deprecated

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

Deprecated: Use CreateRecordRequest.ProtoReflect.Descriptor instead.

func (*CreateRecordRequest) GetHint

func (x *CreateRecordRequest) GetHint() *Hint

func (*CreateRecordRequest) GetRecord

func (x *CreateRecordRequest) GetRecord() *Record

func (*CreateRecordRequest) GetStoreKey

func (x *CreateRecordRequest) GetStoreKey() string

func (*CreateRecordRequest) ProtoMessage

func (*CreateRecordRequest) ProtoMessage()

func (*CreateRecordRequest) ProtoReflect

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

func (*CreateRecordRequest) Reset

func (x *CreateRecordRequest) Reset()

func (*CreateRecordRequest) String

func (x *CreateRecordRequest) String() string

type CreateStoreRequest

type CreateStoreRequest struct {

	// Store to create.
	Store *Store `protobuf:"bytes,1,opt,name=store,proto3" json:"store,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateStoreRequest) Descriptor deprecated

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

Deprecated: Use CreateStoreRequest.ProtoReflect.Descriptor instead.

func (*CreateStoreRequest) GetStore

func (x *CreateStoreRequest) GetStore() *Store

func (*CreateStoreRequest) ProtoMessage

func (*CreateStoreRequest) ProtoMessage()

func (*CreateStoreRequest) ProtoReflect

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

func (*CreateStoreRequest) Reset

func (x *CreateStoreRequest) Reset()

func (*CreateStoreRequest) String

func (x *CreateStoreRequest) String() string

type DeleteBlobRequest

type DeleteBlobRequest struct {

	// The key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// The key of the record to delete a blob from.
	RecordKey string `protobuf:"bytes,2,opt,name=record_key,json=recordKey,proto3" json:"record_key,omitempty"`
	// Performance hints.
	Hint *Hint `protobuf:"bytes,3,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteBlobRequest) Descriptor deprecated

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

Deprecated: Use DeleteBlobRequest.ProtoReflect.Descriptor instead.

func (*DeleteBlobRequest) GetHint

func (x *DeleteBlobRequest) GetHint() *Hint

func (*DeleteBlobRequest) GetRecordKey

func (x *DeleteBlobRequest) GetRecordKey() string

func (*DeleteBlobRequest) GetStoreKey

func (x *DeleteBlobRequest) GetStoreKey() string

func (*DeleteBlobRequest) ProtoMessage

func (*DeleteBlobRequest) ProtoMessage()

func (*DeleteBlobRequest) ProtoReflect

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

func (*DeleteBlobRequest) Reset

func (x *DeleteBlobRequest) Reset()

func (*DeleteBlobRequest) String

func (x *DeleteBlobRequest) String() string

type DeleteRecordRequest

type DeleteRecordRequest struct {

	// The key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// The key of the record to delete.
	Key string `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteRecordRequest) Descriptor deprecated

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

Deprecated: Use DeleteRecordRequest.ProtoReflect.Descriptor instead.

func (*DeleteRecordRequest) GetKey

func (x *DeleteRecordRequest) GetKey() string

func (*DeleteRecordRequest) GetStoreKey

func (x *DeleteRecordRequest) GetStoreKey() string

func (*DeleteRecordRequest) ProtoMessage

func (*DeleteRecordRequest) ProtoMessage()

func (*DeleteRecordRequest) ProtoReflect

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

func (*DeleteRecordRequest) Reset

func (x *DeleteRecordRequest) Reset()

func (*DeleteRecordRequest) String

func (x *DeleteRecordRequest) String() string

type DeleteStoreRequest

type DeleteStoreRequest struct {

	// The key of the store to delete.
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteStoreRequest) Descriptor deprecated

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

Deprecated: Use DeleteStoreRequest.ProtoReflect.Descriptor instead.

func (*DeleteStoreRequest) GetKey

func (x *DeleteStoreRequest) GetKey() string

func (*DeleteStoreRequest) ProtoMessage

func (*DeleteStoreRequest) ProtoMessage()

func (*DeleteStoreRequest) ProtoReflect

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

func (*DeleteStoreRequest) Reset

func (x *DeleteStoreRequest) Reset()

func (*DeleteStoreRequest) String

func (x *DeleteStoreRequest) String() string

type FilterOperator

type FilterOperator int32

FilterOperator has a list of comperators.

const (
	// =
	FilterOperator_EQUAL FilterOperator = 0
	// >
	FilterOperator_GREATER FilterOperator = 1
	// <
	FilterOperator_LESS FilterOperator = 2
	// >=
	FilterOperator_GREATER_OR_EQUAL FilterOperator = 3
	// <=
	FilterOperator_LESS_OR_EQUAL FilterOperator = 4
)

func (FilterOperator) Descriptor

func (FilterOperator) Enum

func (x FilterOperator) Enum() *FilterOperator

func (FilterOperator) EnumDescriptor deprecated

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

Deprecated: Use FilterOperator.Descriptor instead.

func (FilterOperator) Number

func (FilterOperator) String

func (x FilterOperator) String() string

func (FilterOperator) Type

type GetBlobChunkRequest

type GetBlobChunkRequest struct {

	// The key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// The key of the record to get.
	RecordKey string `protobuf:"bytes,2,opt,name=record_key,json=recordKey,proto3" json:"record_key,omitempty"`
	// chunk_number is the number of the chunk to get.
	ChunkNumber int64 `protobuf:"varint,3,opt,name=chunk_number,json=chunkNumber,proto3" json:"chunk_number,omitempty"`
	// Performance hints.
	Hint *Hint `protobuf:"bytes,4,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*GetBlobChunkRequest) Descriptor deprecated

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

Deprecated: Use GetBlobChunkRequest.ProtoReflect.Descriptor instead.

func (*GetBlobChunkRequest) GetChunkNumber

func (x *GetBlobChunkRequest) GetChunkNumber() int64

func (*GetBlobChunkRequest) GetHint

func (x *GetBlobChunkRequest) GetHint() *Hint

func (*GetBlobChunkRequest) GetRecordKey

func (x *GetBlobChunkRequest) GetRecordKey() string

func (*GetBlobChunkRequest) GetStoreKey

func (x *GetBlobChunkRequest) GetStoreKey() string

func (*GetBlobChunkRequest) ProtoMessage

func (*GetBlobChunkRequest) ProtoMessage()

func (*GetBlobChunkRequest) ProtoReflect

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

func (*GetBlobChunkRequest) Reset

func (x *GetBlobChunkRequest) Reset()

func (*GetBlobChunkRequest) String

func (x *GetBlobChunkRequest) String() string

type GetBlobChunkResponse

type GetBlobChunkResponse struct {

	// Types that are assignable to Response:
	//	*GetBlobChunkResponse_Metadata
	//	*GetBlobChunkResponse_Content
	Response isGetBlobChunkResponse_Response `protobuf_oneof:"response"`
	// contains filtered or unexported fields
}

GetBlobChunkResponse is a server-streaming response to return metadata and content of a chunked blob object. The first message contains metadata and the subsequent messages contain the binary data of the chunk inthe content field.

func (*GetBlobChunkResponse) Descriptor deprecated

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

Deprecated: Use GetBlobChunkResponse.ProtoReflect.Descriptor instead.

func (*GetBlobChunkResponse) GetContent

func (x *GetBlobChunkResponse) GetContent() []byte

func (*GetBlobChunkResponse) GetMetadata

func (x *GetBlobChunkResponse) GetMetadata() *ChunkMetadata

func (*GetBlobChunkResponse) GetResponse

func (m *GetBlobChunkResponse) GetResponse() isGetBlobChunkResponse_Response

func (*GetBlobChunkResponse) ProtoMessage

func (*GetBlobChunkResponse) ProtoMessage()

func (*GetBlobChunkResponse) ProtoReflect

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

func (*GetBlobChunkResponse) Reset

func (x *GetBlobChunkResponse) Reset()

func (*GetBlobChunkResponse) String

func (x *GetBlobChunkResponse) String() string

type GetBlobChunkResponse_Content

type GetBlobChunkResponse_Content struct {
	Content []byte `protobuf:"bytes,2,opt,name=content,proto3,oneof"`
}

type GetBlobChunkResponse_Metadata

type GetBlobChunkResponse_Metadata struct {
	Metadata *ChunkMetadata `protobuf:"bytes,1,opt,name=metadata,proto3,oneof"`
}

type GetBlobRequest

type GetBlobRequest struct {

	// The key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// The key of the record to get.
	RecordKey string `protobuf:"bytes,2,opt,name=record_key,json=recordKey,proto3" json:"record_key,omitempty"`
	// Performance hints.
	Hint *Hint `protobuf:"bytes,3,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*GetBlobRequest) Descriptor deprecated

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

Deprecated: Use GetBlobRequest.ProtoReflect.Descriptor instead.

func (*GetBlobRequest) GetHint

func (x *GetBlobRequest) GetHint() *Hint

func (*GetBlobRequest) GetRecordKey

func (x *GetBlobRequest) GetRecordKey() string

func (*GetBlobRequest) GetStoreKey

func (x *GetBlobRequest) GetStoreKey() string

func (*GetBlobRequest) ProtoMessage

func (*GetBlobRequest) ProtoMessage()

func (*GetBlobRequest) ProtoReflect

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

func (*GetBlobRequest) Reset

func (x *GetBlobRequest) Reset()

func (*GetBlobRequest) String

func (x *GetBlobRequest) String() string

type GetBlobResponse

type GetBlobResponse struct {

	// Types that are assignable to Response:
	//	*GetBlobResponse_Metadata
	//	*GetBlobResponse_Content
	Response isGetBlobResponse_Response `protobuf_oneof:"response"`
	// contains filtered or unexported fields
}

GetBlobResponse is a server-streaming response to return metadata and content of a blob object. The first message contains metadata and the subsequent messages contain the rest of the binary blob in the content field.

func (*GetBlobResponse) Descriptor deprecated

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

Deprecated: Use GetBlobResponse.ProtoReflect.Descriptor instead.

func (*GetBlobResponse) GetContent

func (x *GetBlobResponse) GetContent() []byte

func (*GetBlobResponse) GetMetadata

func (x *GetBlobResponse) GetMetadata() *BlobMetadata

func (*GetBlobResponse) GetResponse

func (m *GetBlobResponse) GetResponse() isGetBlobResponse_Response

func (*GetBlobResponse) ProtoMessage

func (*GetBlobResponse) ProtoMessage()

func (*GetBlobResponse) ProtoReflect

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

func (*GetBlobResponse) Reset

func (x *GetBlobResponse) Reset()

func (*GetBlobResponse) String

func (x *GetBlobResponse) String() string

type GetBlobResponse_Content

type GetBlobResponse_Content struct {
	// content is the binary content of the blob object.
	Content []byte `protobuf:"bytes,2,opt,name=content,proto3,oneof"`
}

type GetBlobResponse_Metadata

type GetBlobResponse_Metadata struct {
	// metadata is the metadata used to initialize the blob object with.
	Metadata *BlobMetadata `protobuf:"bytes,1,opt,name=metadata,proto3,oneof"`
}

type GetRecordRequest

type GetRecordRequest struct {

	// The key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// The key of the record to get.
	Key string `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
	// Performance hints.
	Hint *Hint `protobuf:"bytes,3,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*GetRecordRequest) Descriptor deprecated

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

Deprecated: Use GetRecordRequest.ProtoReflect.Descriptor instead.

func (*GetRecordRequest) GetHint

func (x *GetRecordRequest) GetHint() *Hint

func (*GetRecordRequest) GetKey

func (x *GetRecordRequest) GetKey() string

func (*GetRecordRequest) GetStoreKey

func (x *GetRecordRequest) GetStoreKey() string

func (*GetRecordRequest) ProtoMessage

func (*GetRecordRequest) ProtoMessage()

func (*GetRecordRequest) ProtoReflect

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

func (*GetRecordRequest) Reset

func (x *GetRecordRequest) Reset()

func (*GetRecordRequest) String

func (x *GetRecordRequest) String() string

type GetStoreRequest

type GetStoreRequest struct {

	// The key of the store to retrieve.
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*GetStoreRequest) Descriptor deprecated

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

Deprecated: Use GetStoreRequest.ProtoReflect.Descriptor instead.

func (*GetStoreRequest) GetKey

func (x *GetStoreRequest) GetKey() string

func (*GetStoreRequest) ProtoMessage

func (*GetStoreRequest) ProtoMessage()

func (*GetStoreRequest) ProtoReflect

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

func (*GetStoreRequest) Reset

func (x *GetStoreRequest) Reset()

func (*GetStoreRequest) String

func (x *GetStoreRequest) String() string

type Hint

type Hint struct {

	// If true, do not cache the record for future requests.
	DoNotCache bool `protobuf:"varint,1,opt,name=do_not_cache,json=doNotCache,proto3" json:"do_not_cache,omitempty"`
	// If true, skip the cache check and always check the metadata server.
	// If false, allow file size to determine cache checks.
	SkipCache bool `protobuf:"varint,2,opt,name=skip_cache,json=skipCache,proto3" json:"skip_cache,omitempty"`
	// If true, always store the blob in blob storage, rather than in the metadata
	// server. If false, allow file size to determine where to store the blob.
	ForceBlobStore bool `protobuf:"varint,3,opt,name=force_blob_store,json=forceBlobStore,proto3" json:"force_blob_store,omitempty"`
	// Tells the server to not use blob storage. Always store the blob into
	// the metadata entity. The server will return an error if the blob is too
	// large. The exact size limit depends on the backend implementation.
	ForceInlineBlob bool `protobuf:"varint,4,opt,name=force_inline_blob,json=forceInlineBlob,proto3" json:"force_inline_blob,omitempty"`
	// contains filtered or unexported fields
}

Performance optimization hints for the server. The server may silently ignore the hints when not feasible.

func (*Hint) Descriptor deprecated

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

Deprecated: Use Hint.ProtoReflect.Descriptor instead.

func (*Hint) GetDoNotCache

func (x *Hint) GetDoNotCache() bool

func (*Hint) GetForceBlobStore

func (x *Hint) GetForceBlobStore() bool

func (*Hint) GetForceInlineBlob

func (x *Hint) GetForceInlineBlob() bool

func (*Hint) GetSkipCache

func (x *Hint) GetSkipCache() bool

func (*Hint) ProtoMessage

func (*Hint) ProtoMessage()

func (*Hint) ProtoReflect

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

func (*Hint) Reset

func (x *Hint) Reset()

func (*Hint) String

func (x *Hint) String() string

type ListStoresRequest

type ListStoresRequest struct {

	// Store name. This is an exact match.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// List of tags
	Tags []string `protobuf:"bytes,2,rep,name=tags,proto3" json:"tags,omitempty"`
	// owner_id is the owner of stores, represented as an external user ID.
	OwnerId string `protobuf:"bytes,3,opt,name=owner_id,json=ownerId,proto3" json:"owner_id,omitempty"`
	// contains filtered or unexported fields
}

ListStoresRequest contains conditions to filter stores. Multiple conditions are AND'ed together.

func (*ListStoresRequest) Descriptor deprecated

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

Deprecated: Use ListStoresRequest.ProtoReflect.Descriptor instead.

func (*ListStoresRequest) GetName

func (x *ListStoresRequest) GetName() string

func (*ListStoresRequest) GetOwnerId

func (x *ListStoresRequest) GetOwnerId() string

func (*ListStoresRequest) GetTags

func (x *ListStoresRequest) GetTags() []string

func (*ListStoresRequest) ProtoMessage

func (*ListStoresRequest) ProtoMessage()

func (*ListStoresRequest) ProtoReflect

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

func (*ListStoresRequest) Reset

func (x *ListStoresRequest) Reset()

func (*ListStoresRequest) String

func (x *ListStoresRequest) String() string

type ListStoresResponse

type ListStoresResponse struct {

	// List of stores that match the provided criteria.
	Stores []*Store `protobuf:"bytes,1,rep,name=stores,proto3" json:"stores,omitempty"`
	// contains filtered or unexported fields
}

func (*ListStoresResponse) Descriptor deprecated

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

Deprecated: Use ListStoresResponse.ProtoReflect.Descriptor instead.

func (*ListStoresResponse) GetStores

func (x *ListStoresResponse) GetStores() []*Store

func (*ListStoresResponse) ProtoMessage

func (*ListStoresResponse) ProtoMessage()

func (*ListStoresResponse) ProtoReflect

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

func (*ListStoresResponse) Reset

func (x *ListStoresResponse) Reset()

func (*ListStoresResponse) String

func (x *ListStoresResponse) String() string

type OpenSavesClient

type OpenSavesClient interface {
	// CreateStore creates and returns a new store.
	CreateStore(ctx context.Context, in *CreateStoreRequest, opts ...grpc.CallOption) (*Store, error)
	// GetStore fetches store with the specified key.
	GetStore(ctx context.Context, in *GetStoreRequest, opts ...grpc.CallOption) (*Store, error)
	// ListStore returns stores matching the provided criteria.
	ListStores(ctx context.Context, in *ListStoresRequest, opts ...grpc.CallOption) (*ListStoresResponse, error)
	// DeleteStore deletes a single store with the specified key.
	DeleteStore(ctx context.Context, in *DeleteStoreRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// CreateRecord creates a new record. This returns an error if the
	// specified key already exists.
	CreateRecord(ctx context.Context, in *CreateRecordRequest, opts ...grpc.CallOption) (*Record, error)
	// GetRecord returns a record with the specified key.
	GetRecord(ctx context.Context, in *GetRecordRequest, opts ...grpc.CallOption) (*Record, error)
	// QueryRecords performs a query and returns matching records.
	QueryRecords(ctx context.Context, in *QueryRecordsRequest, opts ...grpc.CallOption) (*QueryRecordsResponse, error)
	// UpdateRecord updates an existing record. This returns an error and
	// does not create a new record if the key doesn't exist.
	UpdateRecord(ctx context.Context, in *UpdateRecordRequest, opts ...grpc.CallOption) (*Record, error)
	// DeleteRecord deletes a single record with the specified key.
	DeleteRecord(ctx context.Context, in *DeleteRecordRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// CreateBlob adds a new blob to a record.
	CreateBlob(ctx context.Context, opts ...grpc.CallOption) (OpenSaves_CreateBlobClient, error)
	// CreateChunkedBlob starts a new chunked blob upload session.
	CreateChunkedBlob(ctx context.Context, in *CreateChunkedBlobRequest, opts ...grpc.CallOption) (*CreateChunkedBlobResponse, error)
	// UploadChunk uploads and stores each each chunk.
	UploadChunk(ctx context.Context, opts ...grpc.CallOption) (OpenSaves_UploadChunkClient, error)
	// CommitChunkedUpload commits a chunked blob upload session and
	// makes the blob available for reads.
	CommitChunkedUpload(ctx context.Context, in *CommitChunkedUploadRequest, opts ...grpc.CallOption) (*BlobMetadata, error)
	// AbortChunkedUploads aborts a chunked blob upload session and
	// discards temporary objects.
	AbortChunkedUpload(ctx context.Context, in *AbortChunkedUploadRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// GetBlob retrieves a blob object in a record.
	// Currently this method does not support chunked blobs and
	// returns an UNIMPLEMENTED error if called for chunked blobs.
	// TODO(yuryu): Support chunked blobs and return such objects entirely.
	GetBlob(ctx context.Context, in *GetBlobRequest, opts ...grpc.CallOption) (OpenSaves_GetBlobClient, error)
	// GetBlobChunk returns a chunk of a blob object uploaded using
	// CreateChunkedBlob. It returns an INVALID_ARGUMENT error if the blob is not
	// a chunked object.
	GetBlobChunk(ctx context.Context, in *GetBlobChunkRequest, opts ...grpc.CallOption) (OpenSaves_GetBlobChunkClient, error)
	// DeleteBlob removes an blob object from a record.
	DeleteBlob(ctx context.Context, in *DeleteBlobRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// Ping returns the same string provided by the client.
	// The string is optional and the server returns an empty string if
	// omitted.
	Ping(ctx context.Context, in *PingRequest, opts ...grpc.CallOption) (*PingResponse, error)
}

OpenSavesClient is the client API for OpenSaves 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 NewOpenSavesClient

func NewOpenSavesClient(cc grpc.ClientConnInterface) OpenSavesClient

type OpenSavesServer

type OpenSavesServer interface {
	// CreateStore creates and returns a new store.
	CreateStore(context.Context, *CreateStoreRequest) (*Store, error)
	// GetStore fetches store with the specified key.
	GetStore(context.Context, *GetStoreRequest) (*Store, error)
	// ListStore returns stores matching the provided criteria.
	ListStores(context.Context, *ListStoresRequest) (*ListStoresResponse, error)
	// DeleteStore deletes a single store with the specified key.
	DeleteStore(context.Context, *DeleteStoreRequest) (*emptypb.Empty, error)
	// CreateRecord creates a new record. This returns an error if the
	// specified key already exists.
	CreateRecord(context.Context, *CreateRecordRequest) (*Record, error)
	// GetRecord returns a record with the specified key.
	GetRecord(context.Context, *GetRecordRequest) (*Record, error)
	// QueryRecords performs a query and returns matching records.
	QueryRecords(context.Context, *QueryRecordsRequest) (*QueryRecordsResponse, error)
	// UpdateRecord updates an existing record. This returns an error and
	// does not create a new record if the key doesn't exist.
	UpdateRecord(context.Context, *UpdateRecordRequest) (*Record, error)
	// DeleteRecord deletes a single record with the specified key.
	DeleteRecord(context.Context, *DeleteRecordRequest) (*emptypb.Empty, error)
	// CreateBlob adds a new blob to a record.
	CreateBlob(OpenSaves_CreateBlobServer) error
	// CreateChunkedBlob starts a new chunked blob upload session.
	CreateChunkedBlob(context.Context, *CreateChunkedBlobRequest) (*CreateChunkedBlobResponse, error)
	// UploadChunk uploads and stores each each chunk.
	UploadChunk(OpenSaves_UploadChunkServer) error
	// CommitChunkedUpload commits a chunked blob upload session and
	// makes the blob available for reads.
	CommitChunkedUpload(context.Context, *CommitChunkedUploadRequest) (*BlobMetadata, error)
	// AbortChunkedUploads aborts a chunked blob upload session and
	// discards temporary objects.
	AbortChunkedUpload(context.Context, *AbortChunkedUploadRequest) (*emptypb.Empty, error)
	// GetBlob retrieves a blob object in a record.
	// Currently this method does not support chunked blobs and
	// returns an UNIMPLEMENTED error if called for chunked blobs.
	// TODO(yuryu): Support chunked blobs and return such objects entirely.
	GetBlob(*GetBlobRequest, OpenSaves_GetBlobServer) error
	// GetBlobChunk returns a chunk of a blob object uploaded using
	// CreateChunkedBlob. It returns an INVALID_ARGUMENT error if the blob is not
	// a chunked object.
	GetBlobChunk(*GetBlobChunkRequest, OpenSaves_GetBlobChunkServer) error
	// DeleteBlob removes an blob object from a record.
	DeleteBlob(context.Context, *DeleteBlobRequest) (*emptypb.Empty, error)
	// Ping returns the same string provided by the client.
	// The string is optional and the server returns an empty string if
	// omitted.
	Ping(context.Context, *PingRequest) (*PingResponse, error)
	// contains filtered or unexported methods
}

OpenSavesServer is the server API for OpenSaves service. All implementations must embed UnimplementedOpenSavesServer for forward compatibility

type OpenSaves_CreateBlobClient

type OpenSaves_CreateBlobClient interface {
	Send(*CreateBlobRequest) error
	CloseAndRecv() (*BlobMetadata, error)
	grpc.ClientStream
}

type OpenSaves_CreateBlobServer

type OpenSaves_CreateBlobServer interface {
	SendAndClose(*BlobMetadata) error
	Recv() (*CreateBlobRequest, error)
	grpc.ServerStream
}

type OpenSaves_GetBlobChunkClient

type OpenSaves_GetBlobChunkClient interface {
	Recv() (*GetBlobChunkResponse, error)
	grpc.ClientStream
}

type OpenSaves_GetBlobChunkServer

type OpenSaves_GetBlobChunkServer interface {
	Send(*GetBlobChunkResponse) error
	grpc.ServerStream
}

type OpenSaves_GetBlobClient

type OpenSaves_GetBlobClient interface {
	Recv() (*GetBlobResponse, error)
	grpc.ClientStream
}

type OpenSaves_GetBlobServer

type OpenSaves_GetBlobServer interface {
	Send(*GetBlobResponse) error
	grpc.ServerStream
}

type OpenSaves_UploadChunkClient

type OpenSaves_UploadChunkClient interface {
	Send(*UploadChunkRequest) error
	CloseAndRecv() (*ChunkMetadata, error)
	grpc.ClientStream
}

type OpenSaves_UploadChunkServer

type OpenSaves_UploadChunkServer interface {
	SendAndClose(*ChunkMetadata) error
	Recv() (*UploadChunkRequest, error)
	grpc.ServerStream
}

type PingRequest

type PingRequest struct {

	// An optional string to send with the ping message.
	Ping string `protobuf:"bytes,1,opt,name=ping,proto3" json:"ping,omitempty"`
	// contains filtered or unexported fields
}

func (*PingRequest) Descriptor deprecated

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

Deprecated: Use PingRequest.ProtoReflect.Descriptor instead.

func (*PingRequest) GetPing

func (x *PingRequest) GetPing() string

func (*PingRequest) ProtoMessage

func (*PingRequest) ProtoMessage()

func (*PingRequest) ProtoReflect

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

func (*PingRequest) Reset

func (x *PingRequest) Reset()

func (*PingRequest) String

func (x *PingRequest) String() string

type PingResponse

type PingResponse struct {

	// An optional string that is copied from PingRequest.
	Pong string `protobuf:"bytes,1,opt,name=pong,proto3" json:"pong,omitempty"`
	// contains filtered or unexported fields
}

func (*PingResponse) Descriptor deprecated

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

Deprecated: Use PingResponse.ProtoReflect.Descriptor instead.

func (*PingResponse) GetPong

func (x *PingResponse) GetPong() string

func (*PingResponse) ProtoMessage

func (*PingResponse) ProtoMessage()

func (*PingResponse) ProtoReflect

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

func (*PingResponse) Reset

func (x *PingResponse) Reset()

func (*PingResponse) String

func (x *PingResponse) String() string

type Property

type Property struct {
	Type Property_Type `protobuf:"varint,1,opt,name=type,proto3,enum=opensaves.Property_Type" json:"type,omitempty"`
	// Types that are assignable to Value:
	//	*Property_IntegerValue
	//	*Property_StringValue
	//	*Property_BooleanValue
	Value isProperty_Value `protobuf_oneof:"value"`
	// contains filtered or unexported fields
}

Property represents typed data in Open Saves. This is limited to one type per key.

func (*Property) Descriptor deprecated

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

Deprecated: Use Property.ProtoReflect.Descriptor instead.

func (*Property) GetBooleanValue

func (x *Property) GetBooleanValue() bool

func (*Property) GetIntegerValue

func (x *Property) GetIntegerValue() int64

func (*Property) GetStringValue

func (x *Property) GetStringValue() string

func (*Property) GetType

func (x *Property) GetType() Property_Type

func (*Property) GetValue

func (m *Property) GetValue() isProperty_Value

func (*Property) ProtoMessage

func (*Property) ProtoMessage()

func (*Property) ProtoReflect

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

func (*Property) Reset

func (x *Property) Reset()

func (*Property) String

func (x *Property) String() string

type Property_BooleanValue

type Property_BooleanValue struct {
	BooleanValue bool `protobuf:"varint,4,opt,name=boolean_value,json=booleanValue,proto3,oneof"`
}

type Property_IntegerValue

type Property_IntegerValue struct {
	IntegerValue int64 `protobuf:"varint,2,opt,name=integer_value,json=integerValue,proto3,oneof"`
}

type Property_StringValue

type Property_StringValue struct {
	StringValue string `protobuf:"bytes,3,opt,name=string_value,json=stringValue,proto3,oneof"`
}

type Property_Type

type Property_Type int32

Supported structured data types

const (
	Property_DATATYPE_UNDEFINED Property_Type = 0
	Property_INTEGER            Property_Type = 1
	Property_STRING             Property_Type = 2
	Property_BOOLEAN            Property_Type = 3
)

func (Property_Type) Descriptor

func (Property_Type) Enum

func (x Property_Type) Enum() *Property_Type

func (Property_Type) EnumDescriptor deprecated

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

Deprecated: Use Property_Type.Descriptor instead.

func (Property_Type) Number

func (Property_Type) String

func (x Property_Type) String() string

func (Property_Type) Type

type QueryFilter

type QueryFilter struct {

	// Propety name of the filter.
	PropertyName string `protobuf:"bytes,1,opt,name=property_name,json=propertyName,proto3" json:"property_name,omitempty"`
	// Operator of the filter.
	Operator FilterOperator `protobuf:"varint,2,opt,name=operator,proto3,enum=opensaves.FilterOperator" json:"operator,omitempty"`
	// Value to compare the property with.
	Value *Property `protobuf:"bytes,3,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

QueryFilter is a filtering condition when querying records.

func (*QueryFilter) Descriptor deprecated

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

Deprecated: Use QueryFilter.ProtoReflect.Descriptor instead.

func (*QueryFilter) GetOperator

func (x *QueryFilter) GetOperator() FilterOperator

func (*QueryFilter) GetPropertyName

func (x *QueryFilter) GetPropertyName() string

func (*QueryFilter) GetValue

func (x *QueryFilter) GetValue() *Property

func (*QueryFilter) ProtoMessage

func (*QueryFilter) ProtoMessage()

func (*QueryFilter) ProtoReflect

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

func (*QueryFilter) Reset

func (x *QueryFilter) Reset()

func (*QueryFilter) String

func (x *QueryFilter) String() string

type QueryRecordsRequest

type QueryRecordsRequest struct {

	// store_key is the primary key of the store.
	// Optional and the method queries all stores when omitted.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// List of filters
	Filters []*QueryFilter `protobuf:"bytes,2,rep,name=filters,proto3" json:"filters,omitempty"`
	// List of tags
	Tags []string `protobuf:"bytes,3,rep,name=tags,proto3" json:"tags,omitempty"`
	// owner_id is the owner of records, represented as an external user ID.
	OwnerId string `protobuf:"bytes,4,opt,name=owner_id,json=ownerId,proto3" json:"owner_id,omitempty"`
	// contains filtered or unexported fields
}

QueryRecordsRequest contains conditions to search particular records. Multiple conditions are AND'ed together.

func (*QueryRecordsRequest) Descriptor deprecated

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

Deprecated: Use QueryRecordsRequest.ProtoReflect.Descriptor instead.

func (*QueryRecordsRequest) GetFilters

func (x *QueryRecordsRequest) GetFilters() []*QueryFilter

func (*QueryRecordsRequest) GetOwnerId

func (x *QueryRecordsRequest) GetOwnerId() string

func (*QueryRecordsRequest) GetStoreKey

func (x *QueryRecordsRequest) GetStoreKey() string

func (*QueryRecordsRequest) GetTags

func (x *QueryRecordsRequest) GetTags() []string

func (*QueryRecordsRequest) ProtoMessage

func (*QueryRecordsRequest) ProtoMessage()

func (*QueryRecordsRequest) ProtoReflect

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

func (*QueryRecordsRequest) Reset

func (x *QueryRecordsRequest) Reset()

func (*QueryRecordsRequest) String

func (x *QueryRecordsRequest) String() string

type QueryRecordsResponse

type QueryRecordsResponse struct {

	// List of records that match the criteria.
	Records []*Record `protobuf:"bytes,1,rep,name=records,proto3" json:"records,omitempty"`
	// List of store keys that each of the records belongs to.
	// The order of keys is the same as the records field,
	// e.g. store_keys[0] is the store for records[0], and so on.
	StoreKeys []string `protobuf:"bytes,2,rep,name=store_keys,json=storeKeys,proto3" json:"store_keys,omitempty"`
	// Performance hints.
	// Query caching is not supported at the moment
	Hint *Hint `protobuf:"bytes,3,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*QueryRecordsResponse) Descriptor deprecated

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

Deprecated: Use QueryRecordsResponse.ProtoReflect.Descriptor instead.

func (*QueryRecordsResponse) GetHint

func (x *QueryRecordsResponse) GetHint() *Hint

func (*QueryRecordsResponse) GetRecords

func (x *QueryRecordsResponse) GetRecords() []*Record

func (*QueryRecordsResponse) GetStoreKeys

func (x *QueryRecordsResponse) GetStoreKeys() []string

func (*QueryRecordsResponse) ProtoMessage

func (*QueryRecordsResponse) ProtoMessage()

func (*QueryRecordsResponse) ProtoReflect

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

func (*QueryRecordsResponse) Reset

func (x *QueryRecordsResponse) Reset()

func (*QueryRecordsResponse) String

func (x *QueryRecordsResponse) String() string

type Record

type Record struct {

	// key is the user defined primary key.
	// It is recommended to use uniformally distributed key (e.g. UUID) rather
	// than monotonically increasing values for performance reasons. See
	// https://cloud.google.com/datastore/docs/best-practices#keys for details.
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// Byte length of the blob (read-only)
	BlobSize int64 `protobuf:"varint,3,opt,name=blob_size,json=blobSize,proto3" json:"blob_size,omitempty"`
	// Typed values that are indexed and searchable.
	// The number of properties allowed in a record is backend dependent.
	Properties map[string]*Property `` /* 161-byte string literal not displayed */
	// owner_id is the owner of the record, represented as an external user ID.
	// Open Saves doesn't maintain list of valid users and it is the
	// responsibility of the client to keep track of user IDs.
	OwnerId string `protobuf:"bytes,5,opt,name=owner_id,json=ownerId,proto3" json:"owner_id,omitempty"`
	// tags are queryable strings to categorize records
	// Examples: "player:1", "system", "inventory:xxx"
	Tags []string `protobuf:"bytes,6,rep,name=tags,proto3" json:"tags,omitempty"`
	// created_at is the point in time in UTC when the Record is created
	// on the Open Saves server. It is managed and set by the server.
	CreatedAt *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
	// updated_at is the point in time in UTC when the Record is updated
	// on the Open Saves server. It is managed by the server and updated every
	// time the Record is updated.
	UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
	// chunked is set true if the attached blob is chunked, otherwise false.
	Chunked bool `protobuf:"varint,9,opt,name=chunked,proto3" json:"chunked,omitempty"`
	// Number of chunks.
	NumberOfChunks int64 `protobuf:"varint,10,opt,name=number_of_chunks,json=numberOfChunks,proto3" json:"number_of_chunks,omitempty"`
	// Opaque string where you can store any utf-8 string (e.g. JSON) that is too
	// big and does not fit in the properties. This will not be indexed or
	// queryable. The current size limit is 32KiB.
	OpaqueString string `protobuf:"bytes,11,opt,name=opaque_string,json=opaqueString,proto3" json:"opaque_string,omitempty"`
	// contains filtered or unexported fields
}

Record represents each entity in the Open Saves database.

func (*Record) Descriptor deprecated

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

Deprecated: Use Record.ProtoReflect.Descriptor instead.

func (*Record) GetBlobSize

func (x *Record) GetBlobSize() int64

func (*Record) GetChunked

func (x *Record) GetChunked() bool

func (*Record) GetCreatedAt

func (x *Record) GetCreatedAt() *timestamppb.Timestamp

func (*Record) GetKey

func (x *Record) GetKey() string

func (*Record) GetNumberOfChunks

func (x *Record) GetNumberOfChunks() int64

func (*Record) GetOpaqueString

func (x *Record) GetOpaqueString() string

func (*Record) GetOwnerId

func (x *Record) GetOwnerId() string

func (*Record) GetProperties

func (x *Record) GetProperties() map[string]*Property

func (*Record) GetTags

func (x *Record) GetTags() []string

func (*Record) GetUpdatedAt

func (x *Record) GetUpdatedAt() *timestamppb.Timestamp

func (*Record) ProtoMessage

func (*Record) ProtoMessage()

func (*Record) ProtoReflect

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

func (*Record) Reset

func (x *Record) Reset()

func (*Record) String

func (x *Record) String() string

type Store

type Store struct {

	// key is the user defined primary key.
	// It is recommended to use uniformally distributed key (e.g. UUID) rather
	// than monotonically increasing values for performance reasons. See
	// https://cloud.google.com/datastore/docs/best-practices#keys for details.
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// name is a user defined name of the store.
	// It is indexed and queriable with ListStore, but is otherwise opaque to the
	// server.
	Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// tags are queryable strings to categorize stores
	// Examples: "player:1", "system", "inventory:xxx"
	Tags []string `protobuf:"bytes,3,rep,name=tags,proto3" json:"tags,omitempty"`
	// owner_id is the owner of the store, represented as an external user ID.
	// Open Saves doesn't maintain list of valid users and it is the
	// responsibility of the client to keep track of user IDs.
	OwnerId string `protobuf:"bytes,4,opt,name=owner_id,json=ownerId,proto3" json:"owner_id,omitempty"`
	// created_at is the point in time in UTC when the Store is created
	// on the Open Saves server. It is managed and set by the server.
	CreatedAt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
	// updated_at is the point in time in UTC when the Store is updated
	// on the Open Saves server. It is managed by the server and updated every
	// time the Store is updated.
	UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
	// contains filtered or unexported fields
}

Store represents an internal bucket to contain records.

func (*Store) Descriptor deprecated

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

Deprecated: Use Store.ProtoReflect.Descriptor instead.

func (*Store) GetCreatedAt

func (x *Store) GetCreatedAt() *timestamppb.Timestamp

func (*Store) GetKey

func (x *Store) GetKey() string

func (*Store) GetName

func (x *Store) GetName() string

func (*Store) GetOwnerId

func (x *Store) GetOwnerId() string

func (*Store) GetTags

func (x *Store) GetTags() []string

func (*Store) GetUpdatedAt

func (x *Store) GetUpdatedAt() *timestamppb.Timestamp

func (*Store) ProtoMessage

func (*Store) ProtoMessage()

func (*Store) ProtoReflect

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

func (*Store) Reset

func (x *Store) Reset()

func (*Store) String

func (x *Store) String() string

type UnimplementedOpenSavesServer

type UnimplementedOpenSavesServer struct {
}

UnimplementedOpenSavesServer must be embedded to have forward compatible implementations.

func (UnimplementedOpenSavesServer) AbortChunkedUpload

func (UnimplementedOpenSavesServer) CommitChunkedUpload

func (UnimplementedOpenSavesServer) CreateBlob

func (UnimplementedOpenSavesServer) CreateChunkedBlob

func (UnimplementedOpenSavesServer) CreateRecord

func (UnimplementedOpenSavesServer) CreateStore

func (UnimplementedOpenSavesServer) DeleteBlob

func (UnimplementedOpenSavesServer) DeleteRecord

func (UnimplementedOpenSavesServer) DeleteStore

func (UnimplementedOpenSavesServer) GetBlob

func (UnimplementedOpenSavesServer) GetBlobChunk

func (UnimplementedOpenSavesServer) GetRecord

func (UnimplementedOpenSavesServer) GetStore

func (UnimplementedOpenSavesServer) ListStores

func (UnimplementedOpenSavesServer) Ping

func (UnimplementedOpenSavesServer) QueryRecords

func (UnimplementedOpenSavesServer) UpdateRecord

func (UnimplementedOpenSavesServer) UploadChunk

type UnsafeOpenSavesServer

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

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

type UpdateRecordRequest

type UpdateRecordRequest struct {

	// The key of the store that the record belongs to.
	StoreKey string `protobuf:"bytes,1,opt,name=store_key,json=storeKey,proto3" json:"store_key,omitempty"`
	// The content to update the record with.
	Record *Record `protobuf:"bytes,2,opt,name=record,proto3" json:"record,omitempty"`
	// Performance hints.
	Hint *Hint `protobuf:"bytes,3,opt,name=hint,proto3" json:"hint,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateRecordRequest) Descriptor deprecated

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

Deprecated: Use UpdateRecordRequest.ProtoReflect.Descriptor instead.

func (*UpdateRecordRequest) GetHint

func (x *UpdateRecordRequest) GetHint() *Hint

func (*UpdateRecordRequest) GetRecord

func (x *UpdateRecordRequest) GetRecord() *Record

func (*UpdateRecordRequest) GetStoreKey

func (x *UpdateRecordRequest) GetStoreKey() string

func (*UpdateRecordRequest) ProtoMessage

func (*UpdateRecordRequest) ProtoMessage()

func (*UpdateRecordRequest) ProtoReflect

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

func (*UpdateRecordRequest) Reset

func (x *UpdateRecordRequest) Reset()

func (*UpdateRecordRequest) String

func (x *UpdateRecordRequest) String() string

type UploadChunkRequest

type UploadChunkRequest struct {

	// Types that are assignable to Request:
	//	*UploadChunkRequest_Metadata
	//	*UploadChunkRequest_Content
	Request isUploadChunkRequest_Request `protobuf_oneof:"request"`
	// contains filtered or unexported fields
}

UploadChunkRequest is used by UploadChunk, which is a client-streaming method. The first message should contain the metadata, and the subsequent messages should contain the content field until EOF.

func (*UploadChunkRequest) Descriptor deprecated

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

Deprecated: Use UploadChunkRequest.ProtoReflect.Descriptor instead.

func (*UploadChunkRequest) GetContent

func (x *UploadChunkRequest) GetContent() []byte

func (*UploadChunkRequest) GetMetadata

func (x *UploadChunkRequest) GetMetadata() *ChunkMetadata

func (*UploadChunkRequest) GetRequest

func (m *UploadChunkRequest) GetRequest() isUploadChunkRequest_Request

func (*UploadChunkRequest) ProtoMessage

func (*UploadChunkRequest) ProtoMessage()

func (*UploadChunkRequest) ProtoReflect

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

func (*UploadChunkRequest) Reset

func (x *UploadChunkRequest) Reset()

func (*UploadChunkRequest) String

func (x *UploadChunkRequest) String() string

type UploadChunkRequest_Content

type UploadChunkRequest_Content struct {
	// content is the binary content of the chunk.
	Content []byte `protobuf:"bytes,2,opt,name=content,proto3,oneof"`
}

type UploadChunkRequest_Metadata

type UploadChunkRequest_Metadata struct {
	// metadata is the metadata to associate the chunk to.
	Metadata *ChunkMetadata `protobuf:"bytes,1,opt,name=metadata,proto3,oneof"`
}

Jump to

Keyboard shortcuts

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