Documentation
¶
Index ¶
- type Action
- type ActionGroup
- type Alias
- type AliasAction
- type AliasDetails
- type Allocation
- type Close
- type ComponentTemplate
- type Condition
- type Cron
- type CronDetails
- type Datastream
- type DatastreamTimestampFieldSpec
- type Delete
- type Destination
- type DestinationURL
- type ErrorNotification
- type ForceMerge
- type ISMPolicy
- type ISMPolicySpec
- type ISMTemplate
- type Index
- type IndexAlias
- type IndexPermissionSpec
- type IndexPriority
- type IndexTemplate
- type MessageTemplate
- type Notification
- type Open
- type ReRouteMoveAction
- type ReadOnly
- type ReadWrite
- type ReplicaCount
- type Retry
- type Role
- type RoleMapping
- type Rollover
- type Rollup
- type Shrink
- type Snapshot
- type SnapshotRepository
- type State
- type Tenant
- type TenantPermissionsSpec
- type Transition
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Action ¶
type Action struct { Alias *Alias `json:"alias,omitempty"` // Allocate the index to a node with a specific attribute set Allocation *Allocation `json:"allocation,omitempty"` // Closes the managed index. Close *Close `json:"close,omitempty"` // Deletes a managed index. Delete *Delete `json:"delete,omitempty"` // Reduces the number of Lucene segments by merging the segments of individual shards. ForceMerge *ForceMerge `json:"force_merge,omitempty"` // Set the priority for the index in a specific state. IndexPriority *IndexPriority `json:"index_priority,omitempty"` //Name string `json:"name,omitempty"` Notification *Notification `json:"notification,omitempty"` // Opens a managed index. Open *Open `json:"open,omitempty"` // Sets a managed index to be read only. ReadOnly *ReadOnly `json:"read_only,omitempty"` // Sets a managed index to be writeable. ReadWrite *ReadWrite `json:"read_write,omitempty"` // Sets the number of replicas to assign to an index. ReplicaCount *ReplicaCount `json:"replica_count,omitempty"` // The retry configuration for the action. Retry *Retry `json:"retry,omitempty"` // Rolls an alias over to a new index when the managed index meets one of the rollover conditions. Rollover *Rollover `json:"rollover,omitempty"` // Periodically reduce data granularity by rolling up old data into summarized indexes. Rollup *Rollup `json:"rollup,omitempty"` // Allows you to reduce the number of primary shards in your indexes Shrink *Shrink `json:"shrink,omitempty"` // Back up your cluster’s indexes and state Snapshot *Snapshot `json:"snapshot,omitempty"` // The timeout period for the action. Timeout *string `json:"timeout,omitempty"` }
Actions are the steps that the policy sequentially executes on entering a specific state.
type ActionGroup ¶
type Alias ¶
type Alias struct { // Allocate the index to a node with a specified attribute. Actions []AliasAction `json:"actions"` }
type AliasAction ¶
type AliasAction struct { Add *AliasDetails `json:"add,omitempty"` Remove *AliasDetails `json:"remove,omitempty"` }
type AliasDetails ¶
type AliasDetails struct { // The name of the index that the alias points to. Index *string `json:"index,omitempty"` // The name of the alias. Aliases []string `json:"aliases,omitempty"` // Limit search to an associated shard value Routing *string `json:"routing,omitempty"` // Specify the index that accepts any write operations to the alias. IsWriteIndex *bool `json:"is_write_index,omitempty"` }
type Allocation ¶
type Allocation struct { // Allocate the index to a node with a specified attribute. Exclude string `json:"exclude"` // Allocate the index to a node with any of the specified attributes. Include string `json:"include"` // Don’t allocate the index to a node with any of the specified attributes. Require string `json:"require"` // Wait for the policy to execute before allocating the index to a node with a specified attribute. WaitFor string `json:"wait_for"` }
type ComponentTemplate ¶
type ComponentTemplate struct { Template Index `json:"template"` Version int `json:"version,omitempty"` Meta *apiextensionsv1.JSON `json:"_meta,omitempty"` }
type Condition ¶
type Condition struct { // The cron job that triggers the transition if no other transition happens first. Cron *Cron `json:"cron,omitempty"` // The minimum document count of the index required to transition. MinDocCount *int64 `json:"min_doc_count,omitempty"` // The minimum age of the index required to transition. MinIndexAge *string `json:"min_index_age,omitempty"` // The minimum age required after a rollover has occurred to transition to the next state. MinRolloverAge *string `json:"min_rollover_age,omitempty"` // The minimum size of the total primary shard storage (not counting replicas) required to transition. MinSize *string `json:"min_size,omitempty"` }
type Cron ¶
type Cron struct {
CronDetails *CronDetails `json:"cron"`
}
type CronDetails ¶
type Datastream ¶
type Datastream struct {
TimestampField *DatastreamTimestampFieldSpec `json:"timestamp_field,omitempty"`
}
type DatastreamTimestampFieldSpec ¶
type DatastreamTimestampFieldSpec struct {
Name string `json:"name"`
}
type Destination ¶
type Destination struct { Slack *DestinationURL `json:"slack,omitempty"` Amazon *DestinationURL `json:"amazon,omitempty"` Chime *DestinationURL `json:"chime,omitempty"` CustomWebhook *DestinationURL `json:"custom_webhook,omitempty"` }
type DestinationURL ¶
type DestinationURL struct {
URL string `json:"url,omitempty"`
}
type ErrorNotification ¶
type ErrorNotification struct { // The destination URL. Destination *Destination `json:"destination,omitempty"` Channel string `json:"channel,omitempty"` // The text of the message MessageTemplate *MessageTemplate `json:"message_template,omitempty"` }
type ForceMerge ¶
type ForceMerge struct { // The number of segments to reduce the shard to. MaxNumSegments int64 `json:"max_num_segments"` }
type ISMPolicy ¶
type ISMPolicy struct {
Policy ISMPolicySpec `json:"policy"`
}
type ISMPolicySpec ¶
type ISMPolicySpec struct { // The default starting state for each index that uses this policy. DefaultState string `json:"default_state"` // A human-readable description of the policy. Description string `json:"description"` ErrorNotification *ErrorNotification `json:"error_notification,omitempty"` // Specify an ISM template pattern that matches the index to apply the policy. ISMTemplate []ISMTemplate `json:"ism_template,omitempty"` // The time the policy was last updated. // The states that you define in the policy. States []State `json:"states"` }
ISMPolicySpec is the specification for the ISM policy for OS.
type ISMTemplate ¶
type Index ¶
type Index struct { Settings *apiextensionsv1.JSON `json:"settings,omitempty"` Mappings *apiextensionsv1.JSON `json:"mappings,omitempty"` Aliases map[string]IndexAlias `json:"aliases,omitempty"` }
type IndexAlias ¶
type IndexPermissionSpec ¶
type IndexPermissionSpec struct { IndexPatterns []string `json:"index_patterns,omitempty"` DocumentLevelSecurity string `json:"dls,omitempty"` FieldLevelSecurity []string `json:"fls,omitempty"` AllowedActions []string `json:"allowed_actions,omitempty"` MaskedFields []string `json:"masked_fields,omitempty"` }
type IndexPriority ¶
type IndexPriority struct { // The priority for the index as soon as it enters a state. Priority int64 `json:"priority"` }
type IndexTemplate ¶
type IndexTemplate struct { IndexPatterns []string `json:"index_patterns"` DataStream *Datastream `json:"data_stream,omitempty"` Template Index `json:"template,omitempty"` ComposedOf []string `json:"composed_of,omitempty"` Priority int `json:"priority,omitempty"` Version int `json:"version,omitempty"` Meta *apiextensionsv1.JSON `json:"_meta,omitempty"` }
type MessageTemplate ¶
type MessageTemplate struct {
Source string `json:"source,omitempty"`
}
type Notification ¶
type Notification struct { Destination string `json:"destination"` MessageTemplate MessageTemplate `json:"message_template"` }
type ReRouteMoveAction ¶
type ReplicaCount ¶
type ReplicaCount struct {
NumberOfReplicas int64 `json:"number_of_replicas"`
}
type Role ¶
type Role struct { ClusterPermissions []string `json:"cluster_permissions,omitempty"` IndexPermissions []IndexPermissionSpec `json:"index_permissions,omitempty"` TenantPermissions []TenantPermissionsSpec `json:"tenant_permissions,omitempty"` }
type RoleMapping ¶
type Rollover ¶
type Rollover struct { // The minimum number of documents required to roll over the index. MinDocCount *int64 `json:"min_doc_count,omitempty"` // The minimum age required to roll over the index. MinIndexAge *string `json:"min_index_age,omitempty"` // The minimum storage size of a single primary shard required to roll over the index. MinPrimaryShardSize *string `json:"min_primary_shard_size,omitempty"` // The minimum size of the total primary shard storage (not counting replicas) required to roll over the index. MinSize *string `json:"min_size,omitempty"` }
type Shrink ¶
type Shrink struct { // If true, executes the shrink action even if there are no replicas. ForceUnsafe *bool `json:"force_unsafe,omitempty"` // The maximum size in bytes of a shard for the target index. MaxShardSize *string `json:"max_shard_size,omitempty"` // The maximum number of primary shards in the shrunken index. NumNewShards *int `json:"num_new_shards,omitempty"` // Percentage of the number of original primary shards to shrink. PercentageOfSourceShards *int64 `json:"percentage_of_source_shards,omitempty"` // The name of the shrunken index. TargetIndexNameTemplate *string `json:"target_index_name_template,omitempty"` }
type SnapshotRepository ¶
type State ¶
type State struct { // The actions to execute after entering a state. Actions []Action `json:"actions"` // The name of the state. Name string `json:"name"` // The next states and the conditions required to transition to those states. If no transitions exist, the policy assumes that it’s complete and can now stop managing the index Transitions []Transition `json:"transitions,omitempty"` }
type TenantPermissionsSpec ¶
type Transition ¶
Click to show internal directories.
Click to hide internal directories.