Documentation ¶
Index ¶
- Constants
- type AlterTableDesc
- type AlterTableOption
- func WithAddColumn(name string, typ types.Type) AlterTableOption
- func WithAddColumnFamilies(cf ...ColumnFamily) AlterTableOption
- func WithAddColumnMeta(column Column) AlterTableOption
- func WithAlterAttribute(key, value string) AlterTableOption
- func WithAlterColumnFamilies(cf ...ColumnFamily) AlterTableOption
- func WithAlterKeyBloomFilter(f FeatureFlag) AlterTableOption
- func WithAlterPartitionSettingsObject(ps PartitioningSettings) AlterTableOption
- func WithAlterReadReplicasSettings(rr ReadReplicasSettings) AlterTableOption
- func WithAlterStorageSettings(ss StorageSettings) AlterTableOption
- func WithDropColumn(name string) AlterTableOption
- func WithDropTimeToLive() AlterTableOption
- func WithSetTimeToLiveSettings(settings TimeToLiveSettings) AlterTableOption
- type CachingPolicyDescription
- type CachingPolicyOption
- type Column
- type ColumnFamily
- type ColumnFamilyCompression
- type CommitTransactionDesc
- type CommitTransactionOption
- type CompactionPolicyDescription
- type CompactionPolicyOption
- type CopyTableDesc
- type CopyTableOption
- type CreateTableDesc
- type CreateTableOption
- func WithAttribute(key, value string) CreateTableOption
- func WithColumn(name string, typ types.Type) CreateTableOption
- func WithColumnFamilies(cf ...ColumnFamily) CreateTableOption
- func WithColumnMeta(column Column) CreateTableOption
- func WithIndex(name string, opts ...IndexOption) CreateTableOption
- func WithKeyBloomFilter(f FeatureFlag) CreateTableOption
- func WithPartitioningSettings(opts ...PartitioningSettingsOption) CreateTableOption
- func WithPartitioningSettingsObject(ps PartitioningSettings) CreateTableOption
- func WithPrimaryKeyColumn(columns ...string) CreateTableOption
- func WithProfile(opts ...ProfileOption) CreateTableOption
- func WithReadReplicasSettings(rr ReadReplicasSettings) CreateTableOption
- func WithStorageSettings(ss StorageSettings) CreateTableOption
- func WithTimeToLiveSettings(settings TimeToLiveSettings) CreateTableOption
- type DescribeTableDesc
- type DescribeTableOption
- type Description
- type DropTableDesc
- type DropTableOption
- type ExecuteDataQueryDesc
- type ExecuteDataQueryOption
- type ExecuteScanQueryDesc
- type ExecuteScanQueryOption
- type ExecuteScanQueryRequestMode
- type ExecuteScanQueryStatsType
- type ExecuteSchemeQueryDesc
- type ExecuteSchemeQueryOption
- type ExecutionPolicyDescription
- type ExecutionPolicyOption
- type FeatureFlag
- type IndexDescription
- type IndexOption
- type IndexType
- type KeyRange
- type PartitionStats
- type PartitioningMode
- type PartitioningPolicyDescription
- type PartitioningPolicyOption
- func WithPartitioningPolicyExplicitPartitions(splitPoints ...types.Value) PartitioningPolicyOption
- func WithPartitioningPolicyMode(mode PartitioningMode) PartitioningPolicyOption
- func WithPartitioningPolicyPreset(name string) PartitioningPolicyOption
- func WithPartitioningPolicyUniformPartitions(n uint64) PartitioningPolicyOption
- type PartitioningSettings
- type PartitioningSettingsOption
- func WithMaxPartitionsCount(maxPartitionsCount uint64) PartitioningSettingsOption
- func WithMinPartitionsCount(minPartitionsCount uint64) PartitioningSettingsOption
- func WithPartitionSizeMb(partitionSizeMb uint64) PartitioningSettingsOption
- func WithPartitioningByLoad(flag FeatureFlag) PartitioningSettingsOption
- func WithPartitioningBySize(flag FeatureFlag) PartitioningSettingsOption
- type ProfileOption
- func WithCachingPolicy(opts ...CachingPolicyOption) ProfileOption
- func WithCompactionPolicy(opts ...CompactionPolicyOption) ProfileOption
- func WithExecutionPolicy(opts ...ExecutionPolicyOption) ProfileOption
- func WithPartitioningPolicy(opts ...PartitioningPolicyOption) ProfileOption
- func WithProfilePreset(name string) ProfileOption
- func WithReplicationPolicy(opts ...ReplicationPolicyOption) ProfileOption
- func WithStoragePolicy(opts ...StoragePolicyOption) ProfileOption
- type QueryCachePolicyOption
- type ReadReplicasSettings
- type ReadReplicasType
- type ReadTableDesc
- type ReadTableOption
- func ReadColumn(name string) ReadTableOption
- func ReadGreater(x types.Value) ReadTableOption
- func ReadGreaterOrEqual(x types.Value) ReadTableOption
- func ReadKeyRange(x KeyRange) ReadTableOption
- func ReadLess(x types.Value) ReadTableOption
- func ReadLessOrEqual(x types.Value) ReadTableOption
- func ReadOrdered() ReadTableOption
- func ReadRowLimit(n uint64) ReadTableOption
- type ReplicationPolicyDescription
- type ReplicationPolicyOption
- func WithReplicationPolicyAllowPromotion(flag FeatureFlag) ReplicationPolicyOption
- func WithReplicationPolicyCreatePerAZ(flag FeatureFlag) ReplicationPolicyOption
- func WithReplicationPolicyPreset(name string) ReplicationPolicyOption
- func WithReplicationPolicyReplicasCount(n uint32) ReplicationPolicyOption
- type SessionStatus
- type StoragePolicyDescription
- type StoragePolicyOption
- func WithStoragePolicyData(kind string) StoragePolicyOption
- func WithStoragePolicyExternal(kind string) StoragePolicyOption
- func WithStoragePolicyKeepInMemory(flag FeatureFlag) StoragePolicyOption
- func WithStoragePolicyLog(kind string) StoragePolicyOption
- func WithStoragePolicyPreset(name string) StoragePolicyOption
- func WithStoragePolicySyslog(kind string) StoragePolicyOption
- type StoragePool
- type StorageSettings
- type TTLSettingsdeprecated
- type TableOptionsDescription
- type TableProfileDescription
- type TableStats
- type TimeToLiveMode
- type TimeToLiveSettings
- type TimeToLiveUnit
Constants ¶
const ( FeatureEnabled = feature.Enabled FeatureDisabled = feature.Disabled )
const ( ExecuteScanQueryStatsTypeNone = iota ExecuteScanQueryStatsTypeBasic ExecuteScanQueryStatsTypeFull )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AlterTableDesc ¶
type AlterTableDesc Ydb_Table.AlterTableRequest
type AlterTableOption ¶
type AlterTableOption func(*AlterTableDesc)
func WithAddColumn ¶
func WithAddColumn(name string, typ types.Type) AlterTableOption
func WithAddColumnFamilies ¶
func WithAddColumnFamilies(cf ...ColumnFamily) AlterTableOption
func WithAddColumnMeta ¶
func WithAddColumnMeta(column Column) AlterTableOption
func WithAlterAttribute ¶
func WithAlterAttribute(key, value string) AlterTableOption
func WithAlterColumnFamilies ¶
func WithAlterColumnFamilies(cf ...ColumnFamily) AlterTableOption
func WithAlterKeyBloomFilter ¶
func WithAlterKeyBloomFilter(f FeatureFlag) AlterTableOption
func WithAlterPartitionSettingsObject ¶
func WithAlterPartitionSettingsObject(ps PartitioningSettings) AlterTableOption
func WithAlterReadReplicasSettings ¶
func WithAlterReadReplicasSettings(rr ReadReplicasSettings) AlterTableOption
func WithAlterStorageSettings ¶
func WithAlterStorageSettings(ss StorageSettings) AlterTableOption
func WithDropColumn ¶
func WithDropColumn(name string) AlterTableOption
func WithDropTimeToLive ¶
func WithDropTimeToLive() AlterTableOption
func WithSetTimeToLiveSettings ¶
func WithSetTimeToLiveSettings(settings TimeToLiveSettings) AlterTableOption
type CachingPolicyOption ¶
type CachingPolicyOption func(*cachingPolicy)
func WithCachingPolicyPreset ¶
func WithCachingPolicyPreset(name string) CachingPolicyOption
type ColumnFamily ¶
type ColumnFamily struct { Name string Data StoragePool Compression ColumnFamilyCompression KeepInMemory FeatureFlag }
func NewColumnFamily ¶
func NewColumnFamily(c *Ydb_Table.ColumnFamily) ColumnFamily
type ColumnFamilyCompression ¶
type ColumnFamilyCompression byte
const ( ColumnFamilyCompressionUnknown ColumnFamilyCompression = iota ColumnFamilyCompressionNone ColumnFamilyCompressionLZ4 )
func (ColumnFamilyCompression) String ¶
func (c ColumnFamilyCompression) String() string
type CommitTransactionDesc ¶
type CommitTransactionDesc Ydb_Table.CommitTransactionRequest
type CommitTransactionOption ¶
type CommitTransactionOption func(*CommitTransactionDesc)
func WithCommitCollectStatsModeBasic ¶
func WithCommitCollectStatsModeBasic() CommitTransactionOption
func WithCommitCollectStatsModeNone ¶
func WithCommitCollectStatsModeNone() CommitTransactionOption
type CompactionPolicyOption ¶
type CompactionPolicyOption func(*compactionPolicy)
func WithCompactionPolicyPreset ¶
func WithCompactionPolicyPreset(name string) CompactionPolicyOption
type CopyTableDesc ¶
type CopyTableDesc Ydb_Table.CopyTableRequest
type CopyTableOption ¶
type CopyTableOption func(*CopyTableDesc)
type CreateTableDesc ¶
type CreateTableDesc Ydb_Table.CreateTableRequest
type CreateTableOption ¶
type CreateTableOption func(d *CreateTableDesc)
func WithAttribute ¶
func WithAttribute(key, value string) CreateTableOption
func WithColumn ¶
func WithColumn(name string, typ types.Type) CreateTableOption
func WithColumnFamilies ¶
func WithColumnFamilies(cf ...ColumnFamily) CreateTableOption
func WithColumnMeta ¶
func WithColumnMeta(column Column) CreateTableOption
func WithIndex ¶
func WithIndex(name string, opts ...IndexOption) CreateTableOption
func WithKeyBloomFilter ¶
func WithKeyBloomFilter(f FeatureFlag) CreateTableOption
func WithPartitioningSettings ¶ added in v3.3.2
func WithPartitioningSettings(opts ...PartitioningSettingsOption) CreateTableOption
func WithPartitioningSettingsObject ¶
func WithPartitioningSettingsObject(ps PartitioningSettings) CreateTableOption
func WithPrimaryKeyColumn ¶
func WithPrimaryKeyColumn(columns ...string) CreateTableOption
func WithProfile ¶
func WithProfile(opts ...ProfileOption) CreateTableOption
func WithReadReplicasSettings ¶
func WithReadReplicasSettings(rr ReadReplicasSettings) CreateTableOption
func WithStorageSettings ¶
func WithStorageSettings(ss StorageSettings) CreateTableOption
func WithTimeToLiveSettings ¶
func WithTimeToLiveSettings(settings TimeToLiveSettings) CreateTableOption
type DescribeTableDesc ¶
type DescribeTableDesc Ydb_Table.DescribeTableRequest
type DescribeTableOption ¶
type DescribeTableOption func(d *DescribeTableDesc)
func WithPartitionStats ¶
func WithPartitionStats() DescribeTableOption
func WithShardKeyBounds ¶
func WithShardKeyBounds() DescribeTableOption
func WithTableStats ¶
func WithTableStats() DescribeTableOption
type Description ¶
type Description struct { Name string Columns []Column PrimaryKey []string KeyRanges []KeyRange Stats *TableStats ColumnFamilies []ColumnFamily Attributes map[string]string ReadReplicaSettings ReadReplicasSettings StorageSettings StorageSettings KeyBloomFilter FeatureFlag PartitioningSettings PartitioningSettings Indexes []IndexDescription TimeToLiveSettings *TimeToLiveSettings }
type DropTableDesc ¶
type DropTableDesc Ydb_Table.DropTableRequest
type DropTableOption ¶
type DropTableOption func(*DropTableDesc)
type ExecuteDataQueryDesc ¶
type ExecuteDataQueryDesc Ydb_Table.ExecuteDataQueryRequest
type ExecuteDataQueryOption ¶
type ExecuteDataQueryOption func(*ExecuteDataQueryDesc)
func WithCollectStatsModeBasic ¶
func WithCollectStatsModeBasic() ExecuteDataQueryOption
func WithCollectStatsModeNone ¶
func WithCollectStatsModeNone() ExecuteDataQueryOption
func WithKeepInCache ¶ added in v3.25.0
func WithKeepInCache(keepInCache bool) ExecuteDataQueryOption
WithKeepInCache manages keep-in-cache flag in query cache policy
By default all data queries executes with keep-in-cache policy
func WithQueryCachePolicy
deprecated
func WithQueryCachePolicy(opts ...QueryCachePolicyOption) ExecuteDataQueryOption
WithQueryCachePolicy manages query cache policy
Deprecated: use WithKeepInCache for disabling keep-in-cache policy
type ExecuteScanQueryDesc ¶
type ExecuteScanQueryDesc Ydb_Table.ExecuteScanQueryRequest
type ExecuteScanQueryOption ¶
type ExecuteScanQueryOption func(*ExecuteScanQueryDesc)
func WithExecuteScanQueryMode ¶
func WithExecuteScanQueryMode(m ExecuteScanQueryRequestMode) ExecuteScanQueryOption
WithExecuteScanQueryMode defines scan query mode: execute or explain
func WithExecuteScanQueryStats ¶ added in v3.27.0
func WithExecuteScanQueryStats(stats ExecuteScanQueryStatsType) ExecuteScanQueryOption
WithExecuteScanQueryStats defines query statistics mode
type ExecuteScanQueryRequestMode ¶
type ExecuteScanQueryRequestMode byte
const ( ExecuteScanQueryRequestModeExec ExecuteScanQueryRequestMode = iota ExecuteScanQueryRequestModeExplain )
type ExecuteScanQueryStatsType ¶ added in v3.27.0
type ExecuteScanQueryStatsType uint32
ExecuteScanQueryStatsType specified scan query mode
type ExecuteSchemeQueryDesc ¶
type ExecuteSchemeQueryDesc Ydb_Table.ExecuteSchemeQueryRequest
type ExecuteSchemeQueryOption ¶
type ExecuteSchemeQueryOption func(*ExecuteSchemeQueryDesc)
type ExecutionPolicyOption ¶
type ExecutionPolicyOption func(*executionPolicy)
func WithExecutionPolicyPreset ¶
func WithExecutionPolicyPreset(name string) ExecutionPolicyOption
type FeatureFlag ¶
type IndexDescription ¶
type IndexDescription struct { Name string IndexColumns []string Status Ydb_Table.TableIndexDescription_Status }
type IndexOption ¶
type IndexOption func(d *indexDesc)
func WithIndexColumns ¶
func WithIndexColumns(columns ...string) IndexOption
func WithIndexType ¶
func WithIndexType(t IndexType) IndexOption
type IndexType ¶
type IndexType interface {
// contains filtered or unexported methods
}
func GlobalAsyncIndex ¶
func GlobalAsyncIndex() IndexType
func GlobalIndex ¶
func GlobalIndex() IndexType
type PartitionStats ¶
type PartitioningMode ¶
type PartitioningMode byte
const ( PartitioningUnknown PartitioningMode = iota PartitioningDisabled PartitioningAutoSplit PartitioningAutoSplitMerge )
type PartitioningPolicyOption ¶
type PartitioningPolicyOption func(*partitioningPolicy)
func WithPartitioningPolicyExplicitPartitions ¶
func WithPartitioningPolicyExplicitPartitions(splitPoints ...types.Value) PartitioningPolicyOption
func WithPartitioningPolicyMode ¶
func WithPartitioningPolicyMode(mode PartitioningMode) PartitioningPolicyOption
func WithPartitioningPolicyPreset ¶
func WithPartitioningPolicyPreset(name string) PartitioningPolicyOption
func WithPartitioningPolicyUniformPartitions ¶
func WithPartitioningPolicyUniformPartitions(n uint64) PartitioningPolicyOption
type PartitioningSettings ¶
type PartitioningSettings struct { PartitioningBySize FeatureFlag PartitionSizeMb uint64 PartitioningByLoad FeatureFlag MinPartitionsCount uint64 MaxPartitionsCount uint64 }
func NewPartitioningSettings ¶
func NewPartitioningSettings(ps *Ydb_Table.PartitioningSettings) PartitioningSettings
type PartitioningSettingsOption ¶
type PartitioningSettingsOption func(settings *ydbPartitioningSettings)
func WithMaxPartitionsCount ¶
func WithMaxPartitionsCount(maxPartitionsCount uint64) PartitioningSettingsOption
func WithMinPartitionsCount ¶
func WithMinPartitionsCount(minPartitionsCount uint64) PartitioningSettingsOption
func WithPartitionSizeMb ¶
func WithPartitionSizeMb(partitionSizeMb uint64) PartitioningSettingsOption
func WithPartitioningByLoad ¶
func WithPartitioningByLoad(flag FeatureFlag) PartitioningSettingsOption
func WithPartitioningBySize ¶
func WithPartitioningBySize(flag FeatureFlag) PartitioningSettingsOption
type ProfileOption ¶
type ProfileOption func(p *profile)
func WithCachingPolicy ¶
func WithCachingPolicy(opts ...CachingPolicyOption) ProfileOption
func WithCompactionPolicy ¶
func WithCompactionPolicy(opts ...CompactionPolicyOption) ProfileOption
func WithExecutionPolicy ¶
func WithExecutionPolicy(opts ...ExecutionPolicyOption) ProfileOption
func WithPartitioningPolicy ¶
func WithPartitioningPolicy(opts ...PartitioningPolicyOption) ProfileOption
func WithProfilePreset ¶
func WithProfilePreset(name string) ProfileOption
func WithReplicationPolicy ¶
func WithReplicationPolicy(opts ...ReplicationPolicyOption) ProfileOption
func WithStoragePolicy ¶
func WithStoragePolicy(opts ...StoragePolicyOption) ProfileOption
type QueryCachePolicyOption ¶
type QueryCachePolicyOption func(*queryCachePolicy)
func WithQueryCachePolicyKeepInCache
deprecated
func WithQueryCachePolicyKeepInCache() QueryCachePolicyOption
WithQueryCachePolicyKeepInCache manages keep-in-cache policy
Deprecated: data queries always executes with enabled keep-in-cache policy. Use WithKeepInCache for disabling keep-in-cache policy
type ReadReplicasSettings ¶
type ReadReplicasSettings struct { Type ReadReplicasType Count uint64 }
func NewReadReplicasSettings ¶
func NewReadReplicasSettings(rr *Ydb_Table.ReadReplicasSettings) ReadReplicasSettings
func (ReadReplicasSettings) ToYDB ¶
func (rr ReadReplicasSettings) ToYDB() *Ydb_Table.ReadReplicasSettings
type ReadReplicasType ¶
type ReadReplicasType byte
const ( ReadReplicasPerAzReadReplicas ReadReplicasType = iota ReadReplicasAnyAzReadReplicas )
type ReadTableOption ¶
type ReadTableOption func(*ReadTableDesc)
Read table options
func ReadColumn ¶
func ReadColumn(name string) ReadTableOption
func ReadGreater ¶
func ReadGreater(x types.Value) ReadTableOption
func ReadGreaterOrEqual ¶
func ReadGreaterOrEqual(x types.Value) ReadTableOption
func ReadKeyRange ¶
func ReadKeyRange(x KeyRange) ReadTableOption
ReadKeyRange returns ReadTableOption which makes ReadTable read values in range [x.From, x.To).
Both x.From and x.To may be nil.
func ReadLess ¶
func ReadLess(x types.Value) ReadTableOption
func ReadLessOrEqual ¶
func ReadLessOrEqual(x types.Value) ReadTableOption
func ReadOrdered ¶
func ReadOrdered() ReadTableOption
func ReadRowLimit ¶
func ReadRowLimit(n uint64) ReadTableOption
type ReplicationPolicyOption ¶
type ReplicationPolicyOption func(*replicationPolicy)
func WithReplicationPolicyAllowPromotion ¶
func WithReplicationPolicyAllowPromotion(flag FeatureFlag) ReplicationPolicyOption
func WithReplicationPolicyCreatePerAZ ¶
func WithReplicationPolicyCreatePerAZ(flag FeatureFlag) ReplicationPolicyOption
func WithReplicationPolicyPreset ¶
func WithReplicationPolicyPreset(name string) ReplicationPolicyOption
func WithReplicationPolicyReplicasCount ¶
func WithReplicationPolicyReplicasCount(n uint32) ReplicationPolicyOption
type SessionStatus ¶
type SessionStatus byte
const ( SessionStatusUnknown SessionStatus = iota SessionReady SessionBusy SessionClosing )
func (SessionStatus) String ¶
func (s SessionStatus) String() string
type StoragePolicyOption ¶
type StoragePolicyOption func(*storagePolicy)
func WithStoragePolicyData ¶
func WithStoragePolicyData(kind string) StoragePolicyOption
func WithStoragePolicyExternal ¶
func WithStoragePolicyExternal(kind string) StoragePolicyOption
func WithStoragePolicyKeepInMemory ¶
func WithStoragePolicyKeepInMemory(flag FeatureFlag) StoragePolicyOption
func WithStoragePolicyLog ¶
func WithStoragePolicyLog(kind string) StoragePolicyOption
func WithStoragePolicyPreset ¶
func WithStoragePolicyPreset(name string) StoragePolicyOption
func WithStoragePolicySyslog ¶
func WithStoragePolicySyslog(kind string) StoragePolicyOption
type StoragePool ¶
type StoragePool struct {
Media string
}
type StorageSettings ¶
type StorageSettings struct { TableCommitLog0 StoragePool TableCommitLog1 StoragePool External StoragePool StoreExternalBlobs FeatureFlag }
func NewStorageSettings ¶
func NewStorageSettings(ss *Ydb_Table.StorageSettings) StorageSettings
func (StorageSettings) ToYDB ¶
func (ss StorageSettings) ToYDB() *Ydb_Table.StorageSettings
type TTLSettings
deprecated
type TableOptionsDescription ¶
type TableOptionsDescription struct { TableProfilePresets []TableProfileDescription StoragePolicyPresets []StoragePolicyDescription CompactionPolicyPresets []CompactionPolicyDescription PartitioningPolicyPresets []PartitioningPolicyDescription ExecutionPolicyPresets []ExecutionPolicyDescription ReplicationPolicyPresets []ReplicationPolicyDescription CachingPolicyPresets []CachingPolicyDescription }
type TableProfileDescription ¶
type TableProfileDescription struct { Name string Labels map[string]string DefaultStoragePolicy string DefaultCompactionPolicy string DefaultPartitioningPolicy string DefaultExecutionPolicy string DefaultReplicationPolicy string DefaultCachingPolicy string AllowedStoragePolicies []string AllowedCompactionPolicies []string AllowedPartitioningPolicies []string AllowedExecutionPolicies []string AllowedReplicationPolicies []string AllowedCachingPolicies []string }
type TableStats ¶
type TimeToLiveMode ¶
type TimeToLiveMode byte
const ( TimeToLiveModeDateType TimeToLiveMode = iota TimeToLiveModeValueSinceUnixEpoch )
type TimeToLiveSettings ¶
type TimeToLiveSettings struct { ColumnName string // Mode specified mode Mode TimeToLiveMode // ExpireAfterSeconds specified expiration in seconds ExpireAfterSeconds uint32 // ColumnUnit valid with Mode = TimeToLiveModeValueSinceUnixEpoch ColumnUnit *TimeToLiveUnit }
func NewTimeToLiveSettings ¶
func NewTimeToLiveSettings(settings *Ydb_Table.TtlSettings) *TimeToLiveSettings
func (*TimeToLiveSettings) ToYDB ¶
func (ttl *TimeToLiveSettings) ToYDB() *Ydb_Table.TtlSettings
type TimeToLiveUnit ¶
type TimeToLiveUnit int32
const ( TimeToLiveUnitUnspecified TimeToLiveUnit = iota TimeToLiveUnitSeconds TimeToLiveUnitMilliseconds TimeToLiveUnitMicroseconds TimeToLiveUnitNanoseconds )
func (*TimeToLiveUnit) ToYDB ¶
func (unit *TimeToLiveUnit) ToYDB() Ydb_Table.ValueSinceUnixEpochModeSettings_Unit