Class Detector.Builder
java.lang.Object
co.elastic.clients.elasticsearch.ml.Detector.Builder
- All Implemented Interfaces:
ObjectBuilder<Detector>
- Enclosing class:
- Detector
public static class Detector.Builder extends java.lang.Object implements ObjectBuilder<Detector>
Builder for
Detector
.-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
Modifier and Type Method Description Detector.Builder
addCustomRules(DetectionRule value)
Add a value tocustomRules(List)
, creating the list if needed.Detector.Builder
addCustomRules(java.util.function.Function<DetectionRule.Builder,ObjectBuilder<DetectionRule>> fn)
Add a value tocustomRules(List)
, creating the list if needed.Detector
build()
Builds aDetector
.Detector.Builder
byFieldName(java.lang.String value)
The field used to split the data.Detector.Builder
customRules(DetectionRule... value)
Custom rules enable you to customize the way detectors operate.Detector.Builder
customRules(java.util.function.Function<DetectionRule.Builder,ObjectBuilder<DetectionRule>> fn)
SetcustomRules(List)
to a singleton list.Detector.Builder
customRules(java.util.List<DetectionRule> value)
Custom rules enable you to customize the way detectors operate.Detector.Builder
detectorDescription(java.lang.String value)
A description of the detector.Detector.Builder
detectorIndex(java.lang.Integer value)
A unique identifier for the detector.Detector.Builder
excludeFrequent(ExcludeFrequent value)
If set, frequent entities are excluded from influencing the anomaly results.Detector.Builder
fieldName(java.lang.String value)
The field that the detector uses in the function.Detector.Builder
function(java.lang.String value)
Required - The analysis function that is used.Detector.Builder
overFieldName(java.lang.String value)
The field used to split the data.Detector.Builder
partitionFieldName(java.lang.String value)
The field used to segment the analysis.Detector.Builder
useNull(java.lang.Boolean value)
Defines whether a new series is used as the null series when there is no value for the by or partition fields.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
byFieldName
The field used to split the data. In particular, this property is used for analyzing the splits with respect to their own history. It is used for finding unusual values in the context of the split.API name:
by_field_name
-
customRules
Custom rules enable you to customize the way detectors operate. For example, a rule may dictate conditions under which results should be skipped. Kibana refers to custom rules as job rules.API name:
custom_rules
-
customRules
Custom rules enable you to customize the way detectors operate. For example, a rule may dictate conditions under which results should be skipped. Kibana refers to custom rules as job rules.API name:
custom_rules
-
addCustomRules
Add a value tocustomRules(List)
, creating the list if needed. -
customRules
public Detector.Builder customRules(java.util.function.Function<DetectionRule.Builder,ObjectBuilder<DetectionRule>> fn)SetcustomRules(List)
to a singleton list. -
addCustomRules
public Detector.Builder addCustomRules(java.util.function.Function<DetectionRule.Builder,ObjectBuilder<DetectionRule>> fn)Add a value tocustomRules(List)
, creating the list if needed. -
detectorDescription
A description of the detector.API name:
detector_description
-
detectorIndex
A unique identifier for the detector. This identifier is based on the order of the detectors in theanalysis_config
, starting at zero. If you specify a value for this property, it is ignored.API name:
detector_index
-
excludeFrequent
If set, frequent entities are excluded from influencing the anomaly results. Entities can be considered frequent over time or frequent in a population. If you are working with both over and by fields, you can setexclude_frequent
toall
for both fields, or toby
orover
for those specific fields.API name:
exclude_frequent
-
fieldName
The field that the detector uses in the function. If you use an event rate function such as count or rare, do not specify this field. Thefield_name
cannot contain double quotes or backslashes.API name:
field_name
-
function
Required - The analysis function that is used. For example,count
,rare
,mean
,min
,max
, orsum
.API name:
function
-
overFieldName
The field used to split the data. In particular, this property is used for analyzing the splits with respect to the history of all splits. It is used for finding unusual values in the population of all splits.API name:
over_field_name
-
partitionFieldName
The field used to segment the analysis. When you use this property, you have completely independent baselines for each value of this field.API name:
partition_field_name
-
useNull
Defines whether a new series is used as the null series when there is no value for the by or partition fields.API name:
use_null
-
build
Builds aDetector
.- Specified by:
build
in interfaceObjectBuilder<Detector>
- Throws:
java.lang.NullPointerException
- if some of the required fields are null.
-