Documentation
¶
Index ¶
- func AdjustBulkRequestBody(requestBody []byte, responseBody map[string]interface{}, ...) ([]byte, error)
- func AdjustBulkRequestBodyWithOnlyDocType(requestBody []byte, reservationType DocTypeReservationType) ([]byte, error)
- func ClusterVersionGte7(clusterVersion string) bool
- func ClusterVersionLte5(clusterVersion string) bool
- type BaseES
- func (es *BaseES) GetActionRuleMap() map[RequestActionType]*UriParserRule
- func (es *BaseES) GetAddresses() []string
- func (es *BaseES) GetMethodRuleMap() map[MethodType][]*MatchRule
- func (es *BaseES) GetPassword() string
- func (es *BaseES) GetSearchResponse(bodyMap map[string]interface{}) map[string]interface{}
- func (es *BaseES) GetUser() string
- func (es *BaseES) IsWrite(requestActionType RequestActionType) bool
- func (es *BaseES) MakeUri(c *gin.Context, uriPathParserResult *UriPathParserResult) (*UriPathMakeResult, error)
- func (es *BaseES) MatchRule(c *gin.Context) *UriPathParserResult
- func (es *BaseES) Request(c *gin.Context, bodyBytes []byte, parserUriResult *UriPathParserResult) (map[string]interface{}, int, error)
- type BulkRequestItem
- type BulkResponse
- type BulkResponseItem
- type ClusterHealthRespV5
- type ClusterVersion
- type Doc
- type DocTypeReservationType
- type ES
- type FixUnit
- type IESSettings
- type IResponse
- type MatchRule
- type MethodType
- type Operation
- type RequestActionType
- type ScrollOption
- type ScrollResult
- type ScrollResultV5
- type ScrollResultV7
- type ScrollResultV8
- type UriParserRule
- type UriPathMakeResult
- type UriPathParserResult
- type V0
- type V5
- func (es *V5) Bulk(buf *bytes.Buffer) error
- func (es *V5) BulkBody(index string, buf *bytes.Buffer, doc *Doc) error
- func (es *V5) ClearScroll(scrollId string) error
- func (es *V5) ClusterHealth(ctx context.Context) (map[string]interface{}, error)
- func (es *V5) Count(ctx context.Context, index string) (uint64, error)
- func (es *V5) CreateIndex(esSetting IESSettings) error
- func (es *V5) CreateTemplate(ctx context.Context, name string, body map[string]interface{}) error
- func (es *V5) DeleteIndex(index string) error
- func (es *V5) GetClusterVersion() string
- func (es *V5) GetIndexAliases(index string) (map[string]interface{}, error)
- func (es *V5) GetIndexMapping(index string) (map[string]interface{}, error)
- func (es *V5) GetIndexMappingAndSetting(index string) (IESSettings, error)
- func (es *V5) GetIndexSettings(index string) (map[string]interface{}, error)
- func (es *V5) GetIndexes() ([]string, error)
- func (es *V5) GetInfo(ctx context.Context) (map[string]interface{}, error)
- func (es *V5) IndexExisted(indexName string) (bool, error)
- func (es *V5) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
- func (es *V5) NextScroll(ctx context.Context, scrollId string, scrollTime uint) (*ScrollResult, error)
- func (es *V5) ParseRequest(c *gin.Context)
- type V5Settings
- func (v5 *V5Settings) DateFieldSupportTimestamp(properties map[string]interface{}) map[string]interface{}
- func (v5 *V5Settings) GetAliases() map[string]interface{}
- func (v5 *V5Settings) GetFieldMap() map[string]interface{}
- func (v5 *V5Settings) GetIndex() string
- func (v5 *V5Settings) GetMappings() map[string]interface{}
- func (v5 *V5Settings) GetProperties() map[string]interface{}
- func (v5 *V5Settings) GetSettings() map[string]interface{}
- func (v5 *V5Settings) ToAlias() map[string]interface{}
- func (v5 *V5Settings) ToESV5Mapping() map[string]interface{}
- func (v5 *V5Settings) ToESV5Setting() map[string]interface{}
- func (v5 *V5Settings) ToESV6Mapping() map[string]interface{}
- func (v5 *V5Settings) ToESV6Setting() map[string]interface{}
- func (v5 *V5Settings) ToESV7Mapping() map[string]interface{}
- func (v5 *V5Settings) ToESV7Setting() map[string]interface{}
- func (v5 *V5Settings) ToESV8Mapping() map[string]interface{}
- func (v5 *V5Settings) ToESV8Setting() map[string]interface{}
- func (v5 *V5Settings) ToTargetV5Settings(targetIndex string) *V5Settings
- func (v5 *V5Settings) ToTargetV6Settings(targetIndex string) *V6Settings
- func (v5 *V5Settings) ToTargetV7Settings(targetIndex string) *V7Settings
- func (v5 *V5Settings) ToTargetV8Settings(targetIndex string) *V8Settings
- func (v5 *V5Settings) ToV5TemplateSettings(patterns []string, order int) map[string]interface{}
- func (v5 *V5Settings) ToV6TemplateSettings(patterns []string, order int) map[string]interface{}
- func (v5 *V5Settings) ToV7TemplateSettings(patterns []string, order int) map[string]interface{}
- func (v5 *V5Settings) ToV8TemplateSettings(patterns []string, order int) map[string]interface{}
- type V6
- func (es *V6) Bulk(buf *bytes.Buffer) error
- func (es *V6) BulkBody(index string, buf *bytes.Buffer, doc *Doc) error
- func (es *V6) ClearScroll(scrollId string) error
- func (es *V6) ClusterHealth(ctx context.Context) (map[string]interface{}, error)
- func (es *V6) Count(ctx context.Context, index string) (uint64, error)
- func (es *V6) CreateIndex(esSetting IESSettings) error
- func (es *V6) CreateTemplate(ctx context.Context, name string, body map[string]interface{}) error
- func (es *V6) DeleteIndex(index string) error
- func (es *V6) GetAddresses() []string
- func (es *V6) GetClusterVersion() string
- func (es *V6) GetIndexAliases(index string) (map[string]interface{}, error)
- func (es *V6) GetIndexMapping(index string) (map[string]interface{}, error)
- func (es *V6) GetIndexMappingAndSetting(index string) (IESSettings, error)
- func (es *V6) GetIndexSettings(index string) (map[string]interface{}, error)
- func (es *V6) GetIndexes() ([]string, error)
- func (es *V6) GetInfo(ctx context.Context) (map[string]interface{}, error)
- func (es *V6) GetPassword() string
- func (es *V6) GetUser() string
- func (es *V6) IndexExisted(indexName string) (bool, error)
- func (es *V6) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
- func (es *V6) NextScroll(ctx context.Context, scrollId string, scrollTime uint) (*ScrollResult, error)
- type V6Settings
- type V7
- func (es *V7) Bulk(buf *bytes.Buffer) error
- func (es *V7) BulkBody(index string, buf *bytes.Buffer, doc *Doc) error
- func (es *V7) ClearScroll(scrollId string) error
- func (es *V7) ClusterHealth(ctx context.Context) (map[string]interface{}, error)
- func (es *V7) Count(ctx context.Context, index string) (uint64, error)
- func (es *V7) CreateIndex(esSetting IESSettings) error
- func (es *V7) CreateTemplate(ctx context.Context, name string, body map[string]interface{}) error
- func (es *V7) DeleteIndex(index string) error
- func (es *V7) GetAddresses() []string
- func (es *V7) GetClusterVersion() string
- func (es *V7) GetIndexAliases(index string) (map[string]interface{}, error)
- func (es *V7) GetIndexMapping(index string) (map[string]interface{}, error)
- func (es *V7) GetIndexMappingAndSetting(index string) (IESSettings, error)
- func (es *V7) GetIndexSettings(index string) (map[string]interface{}, error)
- func (es *V7) GetIndexes() ([]string, error)
- func (es *V7) GetInfo(ctx context.Context) (map[string]interface{}, error)
- func (es *V7) GetPassword() string
- func (es *V7) GetUser() string
- func (es *V7) IndexExisted(indexName string) (bool, error)
- func (es *V7) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
- func (es *V7) NextScroll(ctx context.Context, scrollId string, scrollTime uint) (*ScrollResult, error)
- type V7Settings
- type V8
- func (es *V8) Bulk(buf *bytes.Buffer) error
- func (es *V8) BulkBody(index string, buf *bytes.Buffer, doc *Doc) error
- func (es *V8) ClearScroll(scrollId string) error
- func (es *V8) ClusterHealth(ctx context.Context) (map[string]interface{}, error)
- func (es *V8) Count(ctx context.Context, index string) (uint64, error)
- func (es *V8) CreateIndex(esSetting IESSettings) error
- func (es *V8) CreateTemplate(ctx context.Context, name string, body map[string]interface{}) error
- func (es *V8) DeleteIndex(index string) error
- func (es *V8) GetAddresses() []string
- func (es *V8) GetClusterVersion() string
- func (es *V8) GetIndexAliases(index string) (map[string]interface{}, error)
- func (es *V8) GetIndexMapping(index string) (map[string]interface{}, error)
- func (es *V8) GetIndexMappingAndSetting(index string) (IESSettings, error)
- func (es *V8) GetIndexSettings(index string) (map[string]interface{}, error)
- func (es *V8) GetIndexes() ([]string, error)
- func (es *V8) GetInfo(ctx context.Context) (map[string]interface{}, error)
- func (es *V8) GetPassword() string
- func (es *V8) GetUser() string
- func (es *V8) IndexExisted(indexName string) (bool, error)
- func (es *V8) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
- func (es *V8) NextScroll(ctx context.Context, scrollId string, scrollTime uint) (*ScrollResult, error)
- type V8Settings
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AdjustBulkRequestBody ¶ added in v1.1.0
func AdjustBulkRequestBody(requestBody []byte, responseBody map[string]interface{}, reservationType DocTypeReservationType) ([]byte, error)
func AdjustBulkRequestBodyWithOnlyDocType ¶ added in v1.1.0
func AdjustBulkRequestBodyWithOnlyDocType(requestBody []byte, reservationType DocTypeReservationType) ([]byte, error)
func ClusterVersionGte7 ¶ added in v1.1.6
func ClusterVersionLte5 ¶ added in v1.1.6
Types ¶
type BaseES ¶ added in v1.1.0
type BaseES struct { ClusterVersion string Addresses []string User string Password string ActionRuleMap map[RequestActionType]*UriParserRule MethodRuleMap map[MethodType][]*MatchRule Settings IESSettings }
func (*BaseES) GetActionRuleMap ¶ added in v1.1.0
func (es *BaseES) GetActionRuleMap() map[RequestActionType]*UriParserRule
func (*BaseES) GetAddresses ¶ added in v1.1.0
func (*BaseES) GetMethodRuleMap ¶ added in v1.1.0
func (es *BaseES) GetMethodRuleMap() map[MethodType][]*MatchRule
func (*BaseES) GetPassword ¶ added in v1.1.0
func (*BaseES) GetSearchResponse ¶ added in v1.1.0
func (*BaseES) IsWrite ¶ added in v1.1.0
func (es *BaseES) IsWrite(requestActionType RequestActionType) bool
func (*BaseES) MakeUri ¶ added in v1.1.0
func (es *BaseES) MakeUri(c *gin.Context, uriPathParserResult *UriPathParserResult) (*UriPathMakeResult, error)
type BulkRequestItem ¶ added in v1.1.0
type BulkRequestItem struct { ActionType string Metadata map[string]interface{} Document map[string]interface{} }
func (*BulkRequestItem) ToStringArray ¶ added in v1.1.0
func (bulkRequestItem *BulkRequestItem) ToStringArray() []string
type BulkResponse ¶ added in v1.1.0
type BulkResponse struct {
Items []map[string]BulkResponseItem `mapstructure:"items"`
}
type BulkResponseItem ¶ added in v1.1.0
type ClusterHealthRespV5 ¶ added in v1.1.0
type ClusterHealthRespV5 struct { ActivePrimaryShards int `json:"active_primary_shards"` ActiveShards int `json:"active_shards"` ActiveShardsPercentAsNumber float64 `json:"active_shards_percent_as_number"` ClusterName string `json:"cluster_name"` DelayedUnassignedShards int `json:"delayed_unassigned_shards"` InitializingShards int `json:"initializing_shards"` NumberOfDataNodes int `json:"number_of_data_nodes"` NumberOfInFlightFetch int `json:"number_of_in_flight_fetch"` NumberOfNodes int `json:"number_of_nodes"` NumberOfPendingTasks int `json:"number_of_pending_tasks"` RelocatingShards int `json:"relocating_shards"` Status string `json:"status"` TaskMaxWaitingInQueueMillis int `json:"task_max_waiting_in_queue_millis"` TimedOut bool `json:"timed_out"` UnassignedShards int `json:"unassigned_shards"` }
type ClusterVersion ¶
type Doc ¶
type Doc struct { Type string `mapstructure:"_type" json:"_type"` ID string `mapstructure:"_id" json:"_id"` Source map[string]interface{} `mapstructure:"_source" json:"_source"` Hash uint64 `mapstructure:"_hash" json:"_hash"` Op Operation `mapstructure:"_op" json:"_op"` }
func (*Doc) DumpFileBytes ¶ added in v1.0.30
type DocTypeReservationType ¶ added in v1.1.0
type DocTypeReservationType string
const ( DocTypeReservationTypeCreate DocTypeReservationType = "add" DocTypeReservationTypeKeep DocTypeReservationType = "keep" DocTypeReservationTypeDelete DocTypeReservationType = "delete" )
type ES ¶
type ES interface { GetClusterVersion() string IndexExisted(index string) (bool, error) GetIndexes() ([]string, error) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error) NextScroll(ctx context.Context, scrollId string, scrollTime uint) (*ScrollResult, error) ClearScroll(scrollId string) error BulkBody(index string, buf *bytes.Buffer, doc *Doc) error Bulk(buf *bytes.Buffer) error GetIndexMappingAndSetting(index string) (IESSettings, error) CreateIndex(esSetting IESSettings) error DeleteIndex(index string) error Count(ctx context.Context, index string) (uint64, error) CreateTemplate(ctx context.Context, name string, body map[string]interface{}) error ClusterHealth(ctx context.Context) (map[string]interface{}, error) GetInfo(ctx context.Context) (map[string]interface{}, error) GetAddresses() []string GetUser() string GetPassword() string MatchRule(c *gin.Context) *UriPathParserResult MakeUri(c *gin.Context, uriPathParserResult *UriPathParserResult) (*UriPathMakeResult, error) GetSearchResponse(bodyMap map[string]interface{}) map[string]interface{} GetActionRuleMap() map[RequestActionType]*UriParserRule GetMethodRuleMap() map[MethodType][]*MatchRule IsWrite(requestActionType RequestActionType) bool Request(c *gin.Context, bodyBytes []byte, parserUriResult *UriPathParserResult) (map[string]interface{}, int, error) }
type FixUnit ¶ added in v1.0.30
type FixUnit struct { SourceESVersionRange *version.Constraints TargetESVersionRange *version.Constraints Actions []string Callback fixCallback }
type IESSettings ¶
type IESSettings interface { ToESV5Setting() map[string]interface{} ToESV6Setting() map[string]interface{} ToESV7Setting() map[string]interface{} ToESV8Setting() map[string]interface{} ToESV5Mapping() map[string]interface{} ToESV6Mapping() map[string]interface{} ToESV7Mapping() map[string]interface{} ToESV8Mapping() map[string]interface{} ToTargetV5Settings(targetIndex string) *V5Settings ToTargetV6Settings(targetIndex string) *V6Settings ToTargetV7Settings(targetIndex string) *V7Settings ToTargetV8Settings(targetIndex string) *V8Settings ToV5TemplateSettings(pattern []string, order int) map[string]interface{} ToV6TemplateSettings(pattern []string, order int) map[string]interface{} ToV7TemplateSettings(pattern []string, order int) map[string]interface{} ToV8TemplateSettings(pattern []string, order int) map[string]interface{} GetIndex() string GetMappings() map[string]interface{} GetSettings() map[string]interface{} GetAliases() map[string]interface{} GetProperties() map[string]interface{} GetFieldMap() map[string]interface{} }
func GetESSettings ¶ added in v1.0.30
func GetESSettings(esVersion string, settings map[string]interface{}) (IESSettings, error)
type MatchRule ¶ added in v1.1.0
type MatchRule struct { Method MethodType UriPattern string Priority int RequestActionType RequestActionType }
type MethodType ¶ added in v1.1.0
type MethodType string
const ( MethodPost MethodType = "POST" MethodPut MethodType = "PUT" MethodGet MethodType = "GET" MethodDelete MethodType = "DELETE" )
type RequestActionType ¶ added in v1.1.0
type RequestActionType string
const ( RequestActionTypeUpsertDocument RequestActionType = "upsertDocument" RequestActionTypeCreateDocument RequestActionType = "createDocument" RequestActionTypeCreateDocumentWithID RequestActionType = "createDocumentWithID" RequestActionTypeDeleteDocument RequestActionType = "deleteDocument" RequestActionTypeUpdateDocument RequestActionType = "updateDocument" RequestActionTypeDeleteByQuery RequestActionType = "deleteByQuery" RequestActionTypeUpdateByQuery RequestActionType = "updateByQuery" RequestActionTypeBulkDocument RequestActionType = "bulkDocument" RequestActionTypeGetDocument RequestActionType = "getDocument" RequestActionTypeGetDocumentOnlySource RequestActionType = "getDocumentOnlySource" RequestActionTypeMGetDocument RequestActionType = "mgetDocument" RequestActionTypeSearchDocument RequestActionType = "searchDocument" RequestActionTypeSearchDocumentWithLimit RequestActionType = "searchDocumentWithLimit" )
type ScrollOption ¶
type ScrollResult ¶
type ScrollResultV5 ¶
type ScrollResultV5 struct { Took int `json:"took,omitempty"` ScrollId string `json:"_scroll_id,omitempty"` TimedOut bool `json:"timed_out,omitempty"` Hits struct { MaxScore float32 `json:"max_score,omitempty"` Total int `json:"total,omitempty"` Docs []interface{} `json:"hits,omitempty"` } `json:"hits"` Shards struct { Total int `json:"total,omitempty"` Successful int `json:"successful,omitempty"` Skipped int `json:"skipped,omitempty"` Failed int `json:"failed,omitempty"` Failures []struct { Shard int `json:"shard,omitempty"` Index string `json:"index,omitempty"` Status int `json:"status,omitempty"` Reason interface{} `json:"reason,omitempty"` } `json:"failures,omitempty"` } `json:"_shards,omitempty"` }
type ScrollResultV7 ¶
type ScrollResultV7 struct { Took int `json:"took,omitempty"` ScrollId string `json:"_scroll_id,omitempty"` TimedOut bool `json:"timed_out,omitempty"` Hits struct { MaxScore float32 `json:"max_score,omitempty"` Total struct { Value int `json:"value,omitempty"` Relation string `json:"relation,omitempty"` } `json:"total,omitempty"` Docs []interface{} `json:"hits,omitempty"` } `json:"hits"` Shards struct { Successful int `json:"successful,omitempty"` Skipped int `json:"skipped,omitempty"` Failed int `json:"failed,omitempty"` Failures []struct { Shard int `json:"shard,omitempty"` Index string `json:"index,omitempty"` Status int `json:"status,omitempty"` Reason interface{} `json:"reason,omitempty"` } `json:"failures,omitempty"` } `json:"_shards,omitempty"` }
type ScrollResultV8 ¶
type ScrollResultV8 struct { Took int `json:"took,omitempty"` ScrollId string `json:"_scroll_id,omitempty"` TimedOut bool `json:"timed_out,omitempty"` Hits struct { MaxScore *float32 `json:"max_score,omitempty"` Total struct { Value int `json:"value,omitempty"` Relation string `json:"relation,omitempty"` } `json:"total,omitempty"` Docs []interface{} `json:"hits,omitempty"` } `json:"hits"` Shards struct { Total int `json:"total,omitempty"` Successful int `json:"successful,omitempty"` Skipped int `json:"skipped,omitempty"` Failed int `json:"failed,omitempty"` Failures []struct { Shard int `json:"shard,omitempty"` Index string `json:"index,omitempty"` Status int `json:"status,omitempty"` Reason interface{} `json:"reason,omitempty"` } `json:"failures,omitempty"` } `json:"_shards,omitempty"` }
type UriParserRule ¶ added in v1.1.0
type UriPathMakeResult ¶ added in v1.1.0
type UriPathMakeResult struct { Uri string Method MethodType Address string User string Password string }
type UriPathParserResult ¶ added in v1.1.0
type UriPathParserResult struct { RequestAction RequestActionType VariableMap map[string]string }
type V0 ¶
func (*V0) GetVersion ¶
func (es *V0) GetVersion() (*ClusterVersion, error)
type V5 ¶
type V5 struct { *elasticsearch5.Client *BaseES }
func (*V5) ClearScroll ¶
func (*V5) ClusterHealth ¶ added in v1.1.0
func (*V5) CreateIndex ¶
func (es *V5) CreateIndex(esSetting IESSettings) error
func (*V5) CreateTemplate ¶ added in v1.0.34
func (*V5) DeleteIndex ¶
func (*V5) GetClusterVersion ¶
func (*V5) GetIndexAliases ¶
func (*V5) GetIndexMapping ¶
func (*V5) GetIndexMappingAndSetting ¶
func (es *V5) GetIndexMappingAndSetting(index string) (IESSettings, error)
func (*V5) GetIndexSettings ¶
func (*V5) GetIndexes ¶
func (*V5) NewScroll ¶
func (es *V5) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
func (*V5) NextScroll ¶
func (*V5) ParseRequest ¶ added in v1.1.0
type V5Settings ¶
type V5Settings struct { Settings map[string]interface{} Mappings map[string]interface{} Aliases map[string]interface{} SourceIndex string }
func NewV5Settings ¶
func NewV5Settings(settings, mappings, aliases map[string]interface{}, sourceIndex string) *V5Settings
func (*V5Settings) DateFieldSupportTimestamp ¶
func (v5 *V5Settings) DateFieldSupportTimestamp(properties map[string]interface{}) map[string]interface{}
func (*V5Settings) GetAliases ¶
func (v5 *V5Settings) GetAliases() map[string]interface{}
func (*V5Settings) GetFieldMap ¶
func (v5 *V5Settings) GetFieldMap() map[string]interface{}
func (*V5Settings) GetIndex ¶
func (v5 *V5Settings) GetIndex() string
func (*V5Settings) GetMappings ¶
func (v5 *V5Settings) GetMappings() map[string]interface{}
func (*V5Settings) GetProperties ¶
func (v5 *V5Settings) GetProperties() map[string]interface{}
func (*V5Settings) GetSettings ¶
func (v5 *V5Settings) GetSettings() map[string]interface{}
func (*V5Settings) ToAlias ¶
func (v5 *V5Settings) ToAlias() map[string]interface{}
func (*V5Settings) ToESV5Mapping ¶
func (v5 *V5Settings) ToESV5Mapping() map[string]interface{}
func (*V5Settings) ToESV5Setting ¶
func (v5 *V5Settings) ToESV5Setting() map[string]interface{}
func (*V5Settings) ToESV6Mapping ¶
func (v5 *V5Settings) ToESV6Mapping() map[string]interface{}
func (*V5Settings) ToESV6Setting ¶
func (v5 *V5Settings) ToESV6Setting() map[string]interface{}
func (*V5Settings) ToESV7Mapping ¶
func (v5 *V5Settings) ToESV7Mapping() map[string]interface{}
func (*V5Settings) ToESV7Setting ¶
func (v5 *V5Settings) ToESV7Setting() map[string]interface{}
func (*V5Settings) ToESV8Mapping ¶
func (v5 *V5Settings) ToESV8Mapping() map[string]interface{}
func (*V5Settings) ToESV8Setting ¶
func (v5 *V5Settings) ToESV8Setting() map[string]interface{}
func (*V5Settings) ToTargetV5Settings ¶
func (v5 *V5Settings) ToTargetV5Settings(targetIndex string) *V5Settings
func (*V5Settings) ToTargetV6Settings ¶
func (v5 *V5Settings) ToTargetV6Settings(targetIndex string) *V6Settings
func (*V5Settings) ToTargetV7Settings ¶
func (v5 *V5Settings) ToTargetV7Settings(targetIndex string) *V7Settings
func (*V5Settings) ToTargetV8Settings ¶
func (v5 *V5Settings) ToTargetV8Settings(targetIndex string) *V8Settings
func (*V5Settings) ToV5TemplateSettings ¶ added in v1.0.34
func (v5 *V5Settings) ToV5TemplateSettings(patterns []string, order int) map[string]interface{}
func (*V5Settings) ToV6TemplateSettings ¶ added in v1.0.34
func (v5 *V5Settings) ToV6TemplateSettings(patterns []string, order int) map[string]interface{}
func (*V5Settings) ToV7TemplateSettings ¶ added in v1.0.34
func (v5 *V5Settings) ToV7TemplateSettings(patterns []string, order int) map[string]interface{}
func (*V5Settings) ToV8TemplateSettings ¶ added in v1.0.34
func (v5 *V5Settings) ToV8TemplateSettings(patterns []string, order int) map[string]interface{}
type V6 ¶
type V6 struct { *elasticsearch6.Client *BaseES }
func (*V6) ClearScroll ¶
func (*V6) ClusterHealth ¶ added in v1.1.0
func (*V6) CreateIndex ¶
func (es *V6) CreateIndex(esSetting IESSettings) error
func (*V6) CreateTemplate ¶ added in v1.0.34
func (*V6) DeleteIndex ¶
func (*V6) GetAddresses ¶ added in v1.1.0
func (*V6) GetClusterVersion ¶
func (*V6) GetIndexAliases ¶
func (*V6) GetIndexMapping ¶
func (*V6) GetIndexMappingAndSetting ¶
func (es *V6) GetIndexMappingAndSetting(index string) (IESSettings, error)
func (*V6) GetIndexSettings ¶
func (*V6) GetIndexes ¶
func (*V6) GetPassword ¶ added in v1.1.0
func (*V6) NewScroll ¶
func (es *V6) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
func (*V6) NextScroll ¶
type V6Settings ¶
type V6Settings struct {
*V5Settings
}
func NewV6Settings ¶
func NewV6Settings(settings, mappings, aliases map[string]interface{}, sourceIndex string) *V6Settings
type V7 ¶
type V7 struct { *elasticsearch7.Client *BaseES }
func (*V7) ClearScroll ¶
func (*V7) ClusterHealth ¶ added in v1.1.0
func (*V7) CreateIndex ¶
func (es *V7) CreateIndex(esSetting IESSettings) error
func (*V7) CreateTemplate ¶ added in v1.0.34
func (*V7) DeleteIndex ¶
func (*V7) GetAddresses ¶ added in v1.1.0
func (*V7) GetClusterVersion ¶
func (*V7) GetIndexAliases ¶
func (*V7) GetIndexMapping ¶
func (*V7) GetIndexMappingAndSetting ¶
func (es *V7) GetIndexMappingAndSetting(index string) (IESSettings, error)
func (*V7) GetIndexSettings ¶
func (*V7) GetIndexes ¶
func (*V7) GetPassword ¶ added in v1.1.0
func (*V7) NewScroll ¶
func (es *V7) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
func (*V7) NextScroll ¶
type V7Settings ¶
type V7Settings struct {
*V6Settings
}
func NewV7Settings ¶
func NewV7Settings(settings, mappings, aliases map[string]interface{}, sourceIndex string) *V7Settings
type V8 ¶
type V8 struct { *elasticsearch8.Client *BaseES }
func (*V8) ClearScroll ¶
func (*V8) ClusterHealth ¶ added in v1.1.0
func (*V8) CreateIndex ¶
func (es *V8) CreateIndex(esSetting IESSettings) error
func (*V8) CreateTemplate ¶ added in v1.0.34
func (*V8) DeleteIndex ¶
func (*V8) GetAddresses ¶ added in v1.1.0
func (*V8) GetClusterVersion ¶
func (*V8) GetIndexAliases ¶
func (*V8) GetIndexMapping ¶
func (*V8) GetIndexMappingAndSetting ¶
func (es *V8) GetIndexMappingAndSetting(index string) (IESSettings, error)
func (*V8) GetIndexSettings ¶
func (*V8) GetIndexes ¶
func (*V8) GetPassword ¶ added in v1.1.0
func (*V8) NewScroll ¶
func (es *V8) NewScroll(ctx context.Context, index string, option *ScrollOption) (*ScrollResult, error)
func (*V8) NextScroll ¶
type V8Settings ¶
type V8Settings struct {
*V7Settings
}
func NewV8Settings ¶
func NewV8Settings(settings, mappings, aliases map[string]interface{}, sourceIndex string) *V8Settings
func (*V8Settings) GetProperties ¶
func (v8 *V8Settings) GetProperties() map[string]interface{}
Click to show internal directories.
Click to hide internal directories.