Class DatafeedConfig
java.lang.Object
org.elasticsearch.client.ml.datafeed.DatafeedConfig
- All Implemented Interfaces:
ToXContent,ToXContentObject
public class DatafeedConfig extends java.lang.Object implements ToXContentObject
The datafeed configuration object. It specifies which indices
to get the data from and offers parameters for customizing different
aspects of the process.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDatafeedConfig.BuilderNested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params -
Field Summary
Fields Modifier and Type Field Description static ParseFieldAGGREGATIONSstatic ParseFieldCHUNKING_CONFIGstatic ParseFieldDELAYED_DATA_CHECK_CONFIGstatic ParseFieldFREQUENCYstatic ParseFieldIDstatic ParseFieldINDEXESstatic ParseFieldINDICESstatic ParseFieldINDICES_OPTIONSstatic ParseFieldMAX_EMPTY_SEARCHESstatic ConstructingObjectParser<DatafeedConfig.Builder,java.lang.Void>PARSERstatic ParseFieldQUERYstatic ParseFieldQUERY_DELAYstatic ParseFieldSCRIPT_FIELDSstatic ParseFieldSCROLL_SIZE -
Method Summary
Modifier and Type Method Description static DatafeedConfig.Builderbuilder(java.lang.String id, java.lang.String jobId)booleanequals(java.lang.Object other)The lists of indices and types are compared for equality but they are not sorted first so this test could fail simply because the indices and types lists are in different orders.BytesReferencegetAggregations()ChunkingConfiggetChunkingConfig()DelayedDataCheckConfiggetDelayedDataCheckConfig()TimeValuegetFrequency()java.lang.StringgetId()java.util.List<java.lang.String>getIndices()IndicesOptionsgetIndicesOptions()java.lang.StringgetJobId()java.lang.IntegergetMaxEmptySearches()BytesReferencegetQuery()TimeValuegetQueryDelay()java.util.List<SearchSourceBuilder.ScriptField>getScriptFields()java.lang.IntegergetScrollSize()inthashCode()Note this could be a heavy operation when a query or aggregations are set as we need to convert the bytes references into maps to compute a stable hash code.XContentBuildertoXContent(XContentBuilder builder, ToXContent.Params params)
-
Field Details
-
Method Details
-
getId
public java.lang.String getId() -
getJobId
public java.lang.String getJobId() -
getQueryDelay
-
getFrequency
-
getIndices
public java.util.List<java.lang.String> getIndices() -
getScrollSize
public java.lang.Integer getScrollSize() -
getQuery
-
getAggregations
-
getScriptFields
-
getChunkingConfig
-
getDelayedDataCheckConfig
-
getMaxEmptySearches
public java.lang.Integer getMaxEmptySearches() -
getIndicesOptions
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException- Specified by:
toXContentin interfaceToXContent- Throws:
java.io.IOException
-
equals
public boolean equals(java.lang.Object other)The lists of indices and types are compared for equality but they are not sorted first so this test could fail simply because the indices and types lists are in different orders. Also note this could be a heavy operation when a query or aggregations are set as we need to convert the bytes references into maps to correctly compare them.- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()Note this could be a heavy operation when a query or aggregations are set as we need to convert the bytes references into maps to compute a stable hash code.- Overrides:
hashCodein classjava.lang.Object
-
builder
-