Class GeoIpProcessor.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<BuilderT>
co.elastic.clients.elasticsearch.ingest.ProcessorBase.AbstractBuilder<GeoIpProcessor.Builder>
co.elastic.clients.elasticsearch.ingest.GeoIpProcessor.Builder
- All Implemented Interfaces:
WithJson<GeoIpProcessor.Builder>,ObjectBuilder<GeoIpProcessor>
- Enclosing class:
- GeoIpProcessor
public static class GeoIpProcessor.Builder
extends ProcessorBase.AbstractBuilder<GeoIpProcessor.Builder>
implements ObjectBuilder<GeoIpProcessor>
Builder for
GeoIpProcessor.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aGeoIpProcessor.final GeoIpProcessor.BuilderdatabaseFile(String value) The database filename referring to a database the module ships with (GeoLite2-City.mmdb, GeoLite2-Country.mmdb, or GeoLite2-ASN.mmdb) or a custom database in the ingest-geoip config directory.final GeoIpProcessor.BuilderIftrue(and ifingest.geoip.downloader.eager.downloadisfalse), the missing database is downloaded when the pipeline is created.final GeoIpProcessor.BuilderRequired - The field to get the ip address from for the geographical lookup.final GeoIpProcessor.BuilderIftrue, only the first found geoip data will be returned, even if the field contains an array.final GeoIpProcessor.BuilderignoreMissing(Boolean value) Iftrueandfielddoes not exist, the processor quietly exits without modifying the document.final GeoIpProcessor.Builderproperties(String value, String... values) Controls what properties are added to thetarget_fieldbased on the geoip lookup.final GeoIpProcessor.Builderproperties(List<String> list) Controls what properties are added to thetarget_fieldbased on the geoip lookup.protected GeoIpProcessor.Builderself()final GeoIpProcessor.BuildertargetField(String value) The field that will hold the geographical information looked up from the MaxMind database.Methods inherited from class co.elastic.clients.elasticsearch.ingest.ProcessorBase.AbstractBuilder
description, if_, if_, ignoreFailure, onFailure, onFailure, onFailure, onFailure, tagMethods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJsonMethods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
databaseFile
The database filename referring to a database the module ships with (GeoLite2-City.mmdb, GeoLite2-Country.mmdb, or GeoLite2-ASN.mmdb) or a custom database in the ingest-geoip config directory.API name:
database_file -
field
Required - The field to get the ip address from for the geographical lookup.API name:
field -
firstOnly
Iftrue, only the first found geoip data will be returned, even if the field contains an array.API name:
first_only -
ignoreMissing
Iftrueandfielddoes not exist, the processor quietly exits without modifying the document.API name:
ignore_missing -
properties
Controls what properties are added to thetarget_fieldbased on the geoip lookup.API name:
propertiesAdds all elements of
listtoproperties. -
properties
Controls what properties are added to thetarget_fieldbased on the geoip lookup.API name:
propertiesAdds one or more values to
properties. -
targetField
The field that will hold the geographical information looked up from the MaxMind database.API name:
target_field -
downloadDatabaseOnPipelineCreation
Iftrue(and ifingest.geoip.downloader.eager.downloadisfalse), the missing database is downloaded when the pipeline is created. Else, the download is triggered by when the pipeline is used as thedefault_pipelineorfinal_pipelinein an index.API name:
download_database_on_pipeline_creation -
self
- Specified by:
selfin classProcessorBase.AbstractBuilder<GeoIpProcessor.Builder>
-
build
Builds aGeoIpProcessor.- Specified by:
buildin interfaceObjectBuilder<GeoIpProcessor>- Throws:
NullPointerException- if some of the required fields are null.
-