object

package
v2.1.0-rc1+incompatible Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2020 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Overview

Package object is a generated protocol buffer package.

It is generated from these files:

object.proto

It has these top-level messages:

CleanResourcesRequest
CleanResourcesResponse
DataSource
MinioConfig
DataSourceEvent
GetMinioConfigRequest
GetMinioConfigResponse
StorageStatsRequest
StorageStatsResponse
GetDataSourceConfigRequest
GetDataSourceConfigResponse

Package object is a generated protocol buffer package.

It is generated from these files:

object.proto

It has these top-level messages:

CleanResourcesRequest
CleanResourcesResponse
DataSource
MinioConfig
DataSourceEvent
GetMinioConfigRequest
GetMinioConfigResponse
StorageStatsRequest
StorageStatsResponse
GetDataSourceConfigRequest
GetDataSourceConfigResponse

Index

Constants

This section is empty.

Variables

View Source
var DataSourceEvent_DSEventType_name = map[int32]string{
	0: "CREATE",
	1: "UPDATE",
	2: "DELETE",
	3: "ENABLED",
	4: "DISABLED",
}
View Source
var DataSourceEvent_DSEventType_value = map[string]int32{
	"CREATE":   0,
	"UPDATE":   1,
	"DELETE":   2,
	"ENABLED":  3,
	"DISABLED": 4,
}
View Source
var EncryptionMode_name = map[int32]string{
	0: "CLEAR",
	1: "MASTER",
	2: "USER",
	3: "USER_PWD",
}
View Source
var EncryptionMode_value = map[string]int32{
	"CLEAR":    0,
	"MASTER":   1,
	"USER":     2,
	"USER_PWD": 3,
}
View Source
var StorageType_name = map[int32]string{
	0: "LOCAL",
	1: "S3",
	2: "SMB",
	4: "CELLS",
	5: "AZURE",
	6: "GCS",
	7: "B2",
	8: "MANTA",
	9: "SIA",
}
View Source
var StorageType_value = map[string]int32{
	"LOCAL": 0,
	"S3":    1,
	"SMB":   2,
	"CELLS": 4,
	"AZURE": 5,
	"GCS":   6,
	"B2":    7,
	"MANTA": 8,
	"SIA":   9,
}

Functions

func RegisterDataSourceEndpointHandler

func RegisterDataSourceEndpointHandler(s server.Server, hdlr DataSourceEndpointHandler, opts ...server.HandlerOption)

func RegisterObjectsEndpointHandler

func RegisterObjectsEndpointHandler(s server.Server, hdlr ObjectsEndpointHandler, opts ...server.HandlerOption)

func RegisterResourceCleanerEndpointHandler

func RegisterResourceCleanerEndpointHandler(s server.Server, hdlr ResourceCleanerEndpointHandler, opts ...server.HandlerOption)

Types

type CleanResourcesRequest

type CleanResourcesRequest struct {
}

func (*CleanResourcesRequest) Descriptor

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

func (*CleanResourcesRequest) ProtoMessage

func (*CleanResourcesRequest) ProtoMessage()

func (*CleanResourcesRequest) Reset

func (m *CleanResourcesRequest) Reset()

func (*CleanResourcesRequest) String

func (m *CleanResourcesRequest) String() string

func (*CleanResourcesRequest) Validate added in v1.5.0

func (this *CleanResourcesRequest) Validate() error

type CleanResourcesResponse

type CleanResourcesResponse struct {
	Success bool   `protobuf:"varint,1,opt,name=Success" json:"Success,omitempty"`
	Message string `protobuf:"bytes,2,opt,name=Message" json:"Message,omitempty"`
}

func (*CleanResourcesResponse) Descriptor

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

func (*CleanResourcesResponse) GetMessage

func (m *CleanResourcesResponse) GetMessage() string

func (*CleanResourcesResponse) GetSuccess

func (m *CleanResourcesResponse) GetSuccess() bool

func (*CleanResourcesResponse) ProtoMessage

func (*CleanResourcesResponse) ProtoMessage()

func (*CleanResourcesResponse) Reset

func (m *CleanResourcesResponse) Reset()

func (*CleanResourcesResponse) String

func (m *CleanResourcesResponse) String() string

func (*CleanResourcesResponse) Validate added in v1.5.0

func (this *CleanResourcesResponse) Validate() error

type DataSource

type DataSource struct {
	// Name of the data source (max length 34)
	Name string `protobuf:"bytes,1,opt,name=Name" json:"Name,omitempty"`
	// Whether this data source is disabled or running
	Disabled bool `protobuf:"varint,2,opt,name=Disabled" json:"Disabled,omitempty"`
	// Type of underlying storage (LOCAL, S3, AZURE, GCS)
	StorageType StorageType `protobuf:"varint,3,opt,name=StorageType,enum=object.StorageType" json:"StorageType,omitempty"`
	// List of key values describing storage configuration
	StorageConfiguration map[string]string `` /* 160-byte string literal not displayed */
	// Corresponding objects service name (underlying s3 service)
	ObjectsServiceName string `protobuf:"bytes,18,opt,name=ObjectsServiceName" json:"ObjectsServiceName,omitempty"`
	// Corresponding objects service host
	ObjectsHost string `protobuf:"bytes,12,opt,name=ObjectsHost" json:"ObjectsHost,omitempty"`
	// Corresponding objects service port
	ObjectsPort int32 `protobuf:"varint,5,opt,name=ObjectsPort" json:"ObjectsPort,omitempty"`
	// Corresponding objects service connection type
	ObjectsSecure bool `protobuf:"varint,13,opt,name=ObjectsSecure" json:"ObjectsSecure,omitempty"`
	// Corresponding objects service bucket
	ObjectsBucket string `protobuf:"bytes,14,opt,name=ObjectsBucket" json:"ObjectsBucket,omitempty"`
	// Corresponding objects service base folder inside the bucket
	ObjectsBaseFolder string `protobuf:"bytes,15,opt,name=ObjectsBaseFolder" json:"ObjectsBaseFolder,omitempty"`
	// Corresponding objects service api key
	ApiKey string `protobuf:"bytes,16,opt,name=ApiKey" json:"ApiKey,omitempty"`
	// Corresponding objects service api secret
	ApiSecret string `protobuf:"bytes,17,opt,name=ApiSecret" json:"ApiSecret,omitempty"`
	// Peer address of the data source
	PeerAddress string `protobuf:"bytes,19,opt,name=PeerAddress" json:"PeerAddress,omitempty"`
	// Not implemented, whether to watch for underlying changes on the FS
	Watch bool `protobuf:"varint,6,opt,name=Watch" json:"Watch,omitempty"`
	// Type of encryption applied before sending data to storage
	EncryptionMode EncryptionMode `protobuf:"varint,7,opt,name=EncryptionMode,enum=object.EncryptionMode" json:"EncryptionMode,omitempty"`
	// Encryption key used for encrypting data
	EncryptionKey string `protobuf:"bytes,8,opt,name=EncryptionKey" json:"EncryptionKey,omitempty"`
	// Versioning policy describes how files are kept in the versioning queue
	VersioningPolicyName string `protobuf:"bytes,9,opt,name=VersioningPolicyName" json:"VersioningPolicyName,omitempty"`
	// Data Source creation date
	CreationDate int32 `protobuf:"varint,10,opt,name=CreationDate" json:"CreationDate,omitempty"`
	// Data Source last synchronization date
	LastSynchronizationDate int32 `protobuf:"varint,11,opt,name=LastSynchronizationDate" json:"LastSynchronizationDate,omitempty"`
}

DataSource Object description

func (*DataSource) BuildUrl

func (d *DataSource) BuildUrl() string

Builds the url used for clients

func (*DataSource) CreateClient

func (d *DataSource) CreateClient() (*minio.Core, error)

Creates a Minio.Core client from the datasource parameters

func (*DataSource) Descriptor

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

func (*DataSource) GetApiKey

func (m *DataSource) GetApiKey() string

func (*DataSource) GetApiSecret

func (m *DataSource) GetApiSecret() string

func (*DataSource) GetCreationDate

func (m *DataSource) GetCreationDate() int32

func (*DataSource) GetDisabled

func (m *DataSource) GetDisabled() bool

func (*DataSource) GetEncryptionKey

func (m *DataSource) GetEncryptionKey() string

func (*DataSource) GetEncryptionMode

func (m *DataSource) GetEncryptionMode() EncryptionMode

func (*DataSource) GetLastSynchronizationDate

func (m *DataSource) GetLastSynchronizationDate() int32

func (*DataSource) GetName

func (m *DataSource) GetName() string

func (*DataSource) GetObjectsBaseFolder

func (m *DataSource) GetObjectsBaseFolder() string

func (*DataSource) GetObjectsBucket

func (m *DataSource) GetObjectsBucket() string

func (*DataSource) GetObjectsHost

func (m *DataSource) GetObjectsHost() string

func (*DataSource) GetObjectsPort

func (m *DataSource) GetObjectsPort() int32

func (*DataSource) GetObjectsSecure

func (m *DataSource) GetObjectsSecure() bool

func (*DataSource) GetObjectsServiceName

func (m *DataSource) GetObjectsServiceName() string

func (*DataSource) GetPeerAddress

func (m *DataSource) GetPeerAddress() string

func (*DataSource) GetStorageConfiguration

func (m *DataSource) GetStorageConfiguration() map[string]string

func (*DataSource) GetStorageType

func (m *DataSource) GetStorageType() StorageType

func (*DataSource) GetVersioningPolicyName

func (m *DataSource) GetVersioningPolicyName() string

func (*DataSource) GetWatch

func (m *DataSource) GetWatch() bool

func (*DataSource) MarshalLogObject

func (d *DataSource) MarshalLogObject(encoder zapcore.ObjectEncoder) error
LOGGING SUPPORT

MarshalLogObject implements custom marshalling for datasource, to avoid logging ApiKey

func (*DataSource) ProtoMessage

func (*DataSource) ProtoMessage()

func (*DataSource) Reset

func (m *DataSource) Reset()

func (*DataSource) String

func (m *DataSource) String() string

func (*DataSource) Validate added in v1.5.0

func (this *DataSource) Validate() error

type DataSourceEndpoint

type DataSourceEndpoint struct {
	DataSourceEndpointHandler
}

func (*DataSourceEndpoint) GetDataSourceConfig

type DataSourceEndpointClient

type DataSourceEndpointClient interface {
	GetDataSourceConfig(ctx context.Context, in *GetDataSourceConfigRequest, opts ...client.CallOption) (*GetDataSourceConfigResponse, error)
}

func NewDataSourceEndpointClient

func NewDataSourceEndpointClient(serviceName string, c client.Client) DataSourceEndpointClient

type DataSourceEndpointHandler

type DataSourceEndpointHandler interface {
	GetDataSourceConfig(context.Context, *GetDataSourceConfigRequest, *GetDataSourceConfigResponse) error
}

type DataSourceEvent

type DataSourceEvent struct {
	Type   DataSourceEvent_DSEventType `protobuf:"varint,1,opt,name=Type,enum=object.DataSourceEvent_DSEventType" json:"Type,omitempty"`
	Name   string                      `protobuf:"bytes,2,opt,name=Name" json:"Name,omitempty"`
	Config *DataSource                 `protobuf:"bytes,3,opt,name=Config" json:"Config,omitempty"`
}

Used to dispatch some specific events accross services

func (*DataSourceEvent) Descriptor

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

func (*DataSourceEvent) GetConfig

func (m *DataSourceEvent) GetConfig() *DataSource

func (*DataSourceEvent) GetName

func (m *DataSourceEvent) GetName() string

func (*DataSourceEvent) GetType

func (*DataSourceEvent) ProtoMessage

func (*DataSourceEvent) ProtoMessage()

func (*DataSourceEvent) Reset

func (m *DataSourceEvent) Reset()

func (*DataSourceEvent) String

func (m *DataSourceEvent) String() string

func (*DataSourceEvent) Validate added in v1.5.0

func (this *DataSourceEvent) Validate() error

type DataSourceEvent_DSEventType

type DataSourceEvent_DSEventType int32
const (
	DataSourceEvent_CREATE   DataSourceEvent_DSEventType = 0
	DataSourceEvent_UPDATE   DataSourceEvent_DSEventType = 1
	DataSourceEvent_DELETE   DataSourceEvent_DSEventType = 2
	DataSourceEvent_ENABLED  DataSourceEvent_DSEventType = 3
	DataSourceEvent_DISABLED DataSourceEvent_DSEventType = 4
)

func (DataSourceEvent_DSEventType) EnumDescriptor

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

func (DataSourceEvent_DSEventType) String

type EncryptionMode

type EncryptionMode int32

Type of Encryption

const (
	EncryptionMode_CLEAR    EncryptionMode = 0
	EncryptionMode_MASTER   EncryptionMode = 1
	EncryptionMode_USER     EncryptionMode = 2
	EncryptionMode_USER_PWD EncryptionMode = 3
)

func (EncryptionMode) EnumDescriptor

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

func (EncryptionMode) String

func (x EncryptionMode) String() string

type GetDataSourceConfigRequest

type GetDataSourceConfigRequest struct {
}

func (*GetDataSourceConfigRequest) Descriptor

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

func (*GetDataSourceConfigRequest) ProtoMessage

func (*GetDataSourceConfigRequest) ProtoMessage()

func (*GetDataSourceConfigRequest) Reset

func (m *GetDataSourceConfigRequest) Reset()

func (*GetDataSourceConfigRequest) String

func (m *GetDataSourceConfigRequest) String() string

func (*GetDataSourceConfigRequest) Validate added in v1.5.0

func (this *GetDataSourceConfigRequest) Validate() error

type GetDataSourceConfigResponse

type GetDataSourceConfigResponse struct {
	DataSource *DataSource `protobuf:"bytes,1,opt,name=DataSource" json:"DataSource,omitempty"`
}

func (*GetDataSourceConfigResponse) Descriptor

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

func (*GetDataSourceConfigResponse) GetDataSource

func (m *GetDataSourceConfigResponse) GetDataSource() *DataSource

func (*GetDataSourceConfigResponse) ProtoMessage

func (*GetDataSourceConfigResponse) ProtoMessage()

func (*GetDataSourceConfigResponse) Reset

func (m *GetDataSourceConfigResponse) Reset()

func (*GetDataSourceConfigResponse) String

func (m *GetDataSourceConfigResponse) String() string

func (*GetDataSourceConfigResponse) Validate added in v1.5.0

func (this *GetDataSourceConfigResponse) Validate() error

type GetMinioConfigRequest

type GetMinioConfigRequest struct {
}

func (*GetMinioConfigRequest) Descriptor

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

func (*GetMinioConfigRequest) ProtoMessage

func (*GetMinioConfigRequest) ProtoMessage()

func (*GetMinioConfigRequest) Reset

func (m *GetMinioConfigRequest) Reset()

func (*GetMinioConfigRequest) String

func (m *GetMinioConfigRequest) String() string

func (*GetMinioConfigRequest) Validate added in v1.5.0

func (this *GetMinioConfigRequest) Validate() error

type GetMinioConfigResponse

type GetMinioConfigResponse struct {
	MinioConfig *MinioConfig `protobuf:"bytes,1,opt,name=MinioConfig" json:"MinioConfig,omitempty"`
}

func (*GetMinioConfigResponse) Descriptor

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

func (*GetMinioConfigResponse) GetMinioConfig

func (m *GetMinioConfigResponse) GetMinioConfig() *MinioConfig

func (*GetMinioConfigResponse) ProtoMessage

func (*GetMinioConfigResponse) ProtoMessage()

func (*GetMinioConfigResponse) Reset

func (m *GetMinioConfigResponse) Reset()

func (*GetMinioConfigResponse) String

func (m *GetMinioConfigResponse) String() string

func (*GetMinioConfigResponse) Validate added in v1.5.0

func (this *GetMinioConfigResponse) Validate() error

type MinioConfig

type MinioConfig struct {
	// Name of the object service
	Name string `protobuf:"bytes,1,opt,name=Name" json:"Name,omitempty"`
	// Underlying storage type (LOCAL, S3, AZURE, GCS)
	StorageType StorageType `protobuf:"varint,2,opt,name=StorageType,enum=object.StorageType" json:"StorageType,omitempty"`
	// Host where this minio is running
	RunningHost string `protobuf:"bytes,3,opt,name=RunningHost" json:"RunningHost,omitempty"`
	// Whether it is exposed with TLS or not
	RunningSecure bool `protobuf:"varint,4,opt,name=RunningSecure" json:"RunningSecure,omitempty"`
	// Port where this minio is bound
	RunningPort int32 `protobuf:"varint,5,opt,name=RunningPort" json:"RunningPort,omitempty"`
	// Api Key to access this object service
	ApiKey string `protobuf:"bytes,6,opt,name=ApiKey" json:"ApiKey,omitempty"`
	// Api Secret to access this object service
	ApiSecret string `protobuf:"bytes,7,opt,name=ApiSecret" json:"ApiSecret,omitempty"`
	// Url to get info about this object service
	EndpointUrl string `protobuf:"bytes,10,opt,name=EndpointUrl" json:"EndpointUrl,omitempty"`
	// Specific to Local storage type
	LocalFolder string `protobuf:"bytes,8,opt,name=LocalFolder" json:"LocalFolder,omitempty"`
	// Restrict this service to run on a given peer
	PeerAddress string `protobuf:"bytes,9,opt,name=PeerAddress" json:"PeerAddress,omitempty"`
	// Additional configs
	GatewayConfiguration map[string]string `` /* 161-byte string literal not displayed */
}

Used a config storage for minio services

func (*MinioConfig) BuildUrl

func (d *MinioConfig) BuildUrl() string

Builds the url used for clients

func (*MinioConfig) Descriptor

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

func (*MinioConfig) GetApiKey

func (m *MinioConfig) GetApiKey() string

func (*MinioConfig) GetApiSecret

func (m *MinioConfig) GetApiSecret() string

func (*MinioConfig) GetEndpointUrl

func (m *MinioConfig) GetEndpointUrl() string

func (*MinioConfig) GetGatewayConfiguration added in v1.2.2

func (m *MinioConfig) GetGatewayConfiguration() map[string]string

func (*MinioConfig) GetLocalFolder

func (m *MinioConfig) GetLocalFolder() string

func (*MinioConfig) GetName

func (m *MinioConfig) GetName() string

func (*MinioConfig) GetPeerAddress

func (m *MinioConfig) GetPeerAddress() string

func (*MinioConfig) GetRunningHost

func (m *MinioConfig) GetRunningHost() string

func (*MinioConfig) GetRunningPort

func (m *MinioConfig) GetRunningPort() int32

func (*MinioConfig) GetRunningSecure

func (m *MinioConfig) GetRunningSecure() bool

func (*MinioConfig) GetStorageType

func (m *MinioConfig) GetStorageType() StorageType

func (*MinioConfig) MarshalLogObject

func (d *MinioConfig) MarshalLogObject(encoder zapcore.ObjectEncoder) error

MarshalLogObject implements custom marshalling for Minio, to avoid logging ApiKey

func (*MinioConfig) ProtoMessage

func (*MinioConfig) ProtoMessage()

func (*MinioConfig) Reset

func (m *MinioConfig) Reset()

func (*MinioConfig) String

func (m *MinioConfig) String() string

func (*MinioConfig) Validate added in v1.5.0

func (this *MinioConfig) Validate() error

type ObjectsEndpoint

type ObjectsEndpoint struct {
	ObjectsEndpointHandler
}

func (*ObjectsEndpoint) GetMinioConfig

func (*ObjectsEndpoint) StorageStats

type ObjectsEndpointClient

type ObjectsEndpointClient interface {
	GetMinioConfig(ctx context.Context, in *GetMinioConfigRequest, opts ...client.CallOption) (*GetMinioConfigResponse, error)
	StorageStats(ctx context.Context, in *StorageStatsRequest, opts ...client.CallOption) (*StorageStatsResponse, error)
}

func NewObjectsEndpointClient

func NewObjectsEndpointClient(serviceName string, c client.Client) ObjectsEndpointClient

type ObjectsEndpointHandler

type ObjectsEndpointHandler interface {
	GetMinioConfig(context.Context, *GetMinioConfigRequest, *GetMinioConfigResponse) error
	StorageStats(context.Context, *StorageStatsRequest, *StorageStatsResponse) error
}

type ResourceCleanerEndpoint

type ResourceCleanerEndpoint struct {
	ResourceCleanerEndpointHandler
}

func (*ResourceCleanerEndpoint) CleanResourcesBeforeDelete

func (h *ResourceCleanerEndpoint) CleanResourcesBeforeDelete(ctx context.Context, in *CleanResourcesRequest, out *CleanResourcesResponse) error

type ResourceCleanerEndpointClient

type ResourceCleanerEndpointClient interface {
	CleanResourcesBeforeDelete(ctx context.Context, in *CleanResourcesRequest, opts ...client.CallOption) (*CleanResourcesResponse, error)
}

func NewResourceCleanerEndpointClient

func NewResourceCleanerEndpointClient(serviceName string, c client.Client) ResourceCleanerEndpointClient

type ResourceCleanerEndpointHandler

type ResourceCleanerEndpointHandler interface {
	CleanResourcesBeforeDelete(context.Context, *CleanResourcesRequest, *CleanResourcesResponse) error
}

type StorageStatsRequest

type StorageStatsRequest struct {
}

func (*StorageStatsRequest) Descriptor

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

func (*StorageStatsRequest) ProtoMessage

func (*StorageStatsRequest) ProtoMessage()

func (*StorageStatsRequest) Reset

func (m *StorageStatsRequest) Reset()

func (*StorageStatsRequest) String

func (m *StorageStatsRequest) String() string

func (*StorageStatsRequest) Validate

func (this *StorageStatsRequest) Validate() error

type StorageStatsResponse

type StorageStatsResponse struct {
	Stats map[string]string `` /* 130-byte string literal not displayed */
}

func (*StorageStatsResponse) Descriptor

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

func (*StorageStatsResponse) GetStats

func (m *StorageStatsResponse) GetStats() map[string]string

func (*StorageStatsResponse) ProtoMessage

func (*StorageStatsResponse) ProtoMessage()

func (*StorageStatsResponse) Reset

func (m *StorageStatsResponse) Reset()

func (*StorageStatsResponse) String

func (m *StorageStatsResponse) String() string

func (*StorageStatsResponse) Validate

func (this *StorageStatsResponse) Validate() error

type StorageType

type StorageType int32

Type of Gateway

const (
	StorageType_LOCAL StorageType = 0
	StorageType_S3    StorageType = 1
	StorageType_SMB   StorageType = 2
	StorageType_CELLS StorageType = 4
	StorageType_AZURE StorageType = 5
	StorageType_GCS   StorageType = 6
	StorageType_B2    StorageType = 7
	StorageType_MANTA StorageType = 8
	StorageType_SIA   StorageType = 9
)

func (StorageType) EnumDescriptor

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

func (StorageType) String

func (x StorageType) String() string

Jump to

Keyboard shortcuts

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