Documentation
¶
Index ¶
- Constants
- func IsKustoAsyncOperationStateCompleted(state string) bool
- func NewDispatcher(uploaders []Uploader) *dispatcher
- func NewUploader(kustoCli *azkustodata.Client, opts UploaderOpts) *uploader
- type AsyncOperationStatus
- type AuditDiskSpaceTask
- type DropUnusedTablesTask
- type IngestionMapping
- type KustoAsyncOperationState
- type ManagementCommandTask
- type SampleType
- type StatementExecutor
- type SummaryRuleTask
- type SyncFunctionsTask
- type Syncer
- func (s *Syncer) Close() error
- func (s *Syncer) EnsureDefaultMapping(table string) (string, error)
- func (s *Syncer) EnsureDefaultTable(table string) error
- func (s *Syncer) EnsureMapping(table string, mapping schema.SchemaMapping) (string, error)
- func (s *Syncer) EnsureTable(table string, mapping schema.SchemaMapping) error
- func (s *Syncer) Open(ctx context.Context) error
- type Table
- type TableDetail
- type Uploader
- type UploaderOpts
Constants ¶
View Source
const ConcurrentUploads = 50
Variables ¶
This section is empty.
Functions ¶
func IsKustoAsyncOperationStateCompleted ¶ added in v0.2.0
IsKustoAsyncOperationStateCompleted returns true if the async operation is completed (either succeeded or failed) This is used to determine if we should poll the async operation's status.
func NewDispatcher ¶
func NewDispatcher(uploaders []Uploader) *dispatcher
func NewUploader ¶
func NewUploader(kustoCli *azkustodata.Client, opts UploaderOpts) *uploader
Types ¶
type AsyncOperationStatus ¶ added in v0.2.0
type AuditDiskSpaceTask ¶ added in v0.2.0
type AuditDiskSpaceTask struct {
QueueSizer cluster.QueueSizer
StorageDir string
}
func NewAuditDiskSpaceTask ¶ added in v0.2.0
func NewAuditDiskSpaceTask(queueSizer cluster.QueueSizer, storageDir string) *AuditDiskSpaceTask
type DropUnusedTablesTask ¶
type DropUnusedTablesTask struct {
// contains filtered or unexported fields
}
func NewDropUnusedTablesTask ¶
func NewDropUnusedTablesTask(kustoCli StatementExecutor) *DropUnusedTablesTask
type IngestionMapping ¶
type KustoAsyncOperationState ¶ added in v0.2.0
type KustoAsyncOperationState string
const ( // KustoAsyncOperationStateCompleted indicates that the async operation has completed successfully KustoAsyncOperationStateCompleted KustoAsyncOperationState = "Completed" // KustoAsyncOperationStateFailed indicates that the async operation has failed KustoAsyncOperationStateFailed KustoAsyncOperationState = "Failed" // KustoAsyncOperationStateInProgress indicates that the async operation is in progress KustoAsyncOperationStateInProgress KustoAsyncOperationState = "InProgress" // KustoAsyncOperationStateThrottled indicates that the async operation is being throttled KustoAsyncOperationStateThrottled KustoAsyncOperationState = "Throttled" // KustoAsyncOperationStateScheduled indicates that the async operation is scheduled KustoAsyncOperationStateScheduled KustoAsyncOperationState = "Scheduled" )
type ManagementCommandTask ¶ added in v0.2.0
type ManagementCommandTask struct {
// ClusterLabels mirrors the ingestor cluster identity for management-command gating.
ClusterLabels map[string]string
// contains filtered or unexported fields
}
func NewManagementCommandsTask ¶ added in v0.2.0
func NewManagementCommandsTask(store storage.CRDHandler, kustoCli StatementExecutor, clusterLabels map[string]string) *ManagementCommandTask
type StatementExecutor ¶
type StatementExecutor interface {
Database() string
Endpoint() string
Mgmt(ctx context.Context, query azkustodata.Statement, options ...azkustodata.QueryOption) (kustov1.Dataset, error)
}
type SummaryRuleTask ¶ added in v0.2.0
type SummaryRuleTask struct {
SubmitRule func(ctx context.Context, rule v1.SummaryRule, startTime, endTime string) (string, error)
ClusterLabels map[string]string
Clock clock.Clock
// contains filtered or unexported fields
}
func NewSummaryRuleTask ¶ added in v0.2.0
func NewSummaryRuleTask(store storage.CRDHandler, kustoCli StatementExecutor, clusterLabels map[string]string) *SummaryRuleTask
type SyncFunctionsTask ¶
type SyncFunctionsTask struct {
// ClusterLabels carries the ingestor's cluster identity for criteriaExpression evaluation.
ClusterLabels map[string]string
// contains filtered or unexported fields
}
func NewSyncFunctionsTask ¶
func NewSyncFunctionsTask(store storage.Functions, kustoCli StatementExecutor, clusterLabels map[string]string) *SyncFunctionsTask
type Syncer ¶
type Syncer struct {
KustoCli mgmt
// contains filtered or unexported fields
}
func NewSyncer ¶
func NewSyncer(kustoCli mgmt, database string, defaultMapping schema.SchemaMapping, st SampleType) *Syncer
func (*Syncer) EnsureDefaultMapping ¶
EnsureMapping creates a schema mapping for the specified table if it does not exist. It returns the name of the mapping.
func (*Syncer) EnsureDefaultTable ¶
EnsureDefaultTable creates a table with the default schema mapping if it does not exist.
func (*Syncer) EnsureMapping ¶
EnsureMapping creates a schema mapping for the specified table if it does not exist. It returns the name of the mapping.
func (*Syncer) EnsureTable ¶
func (s *Syncer) EnsureTable(table string, mapping schema.SchemaMapping) error
EnsureTable creates a table with the specified schema mapping if it does not exist.
type TableDetail ¶
type Uploader ¶
type Uploader interface {
service.Component
Database() string
Endpoint() string
// UploadQueue returns a channel that can be used to upload files to kusto.
UploadQueue() chan *cluster.Batch
// Mgmt executes a management query against the database.
Mgmt(ctx context.Context, query azkustodata.Statement, options ...azkustodata.QueryOption) (kustov1.Dataset, error)
}
func NewFakeUploader ¶
type UploaderOpts ¶
type UploaderOpts struct {
StorageDir string
Database string
ConcurrentUploads int
Dimensions []string
DefaultMapping adxschema.SchemaMapping
SampleType SampleType
}
Click to show internal directories.
Click to hide internal directories.