elasticstack.ElasticsearchEnrichPolicy
Explore with Pulumi AI
Creates or updates enrich policies, see: https://www.elastic.co/guide/en/elasticsearch/reference/current/enrich-apis.html
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as elasticstack from "@pulumi/elasticstack";
const myIndex = new elasticstack.ElasticsearchIndex("myIndex", {
mappings: JSON.stringify({
properties: {
email: {
type: "text",
},
first_name: {
type: "text",
},
last_name: {
type: "text",
},
},
}),
deletionProtection: false,
});
const policy1 = new elasticstack.ElasticsearchEnrichPolicy("policy1", {
policyType: "match",
indices: [myIndex.name],
matchField: "email",
enrichFields: [
"first_name",
"last_name",
],
query: JSON.stringify({
bool: {
must: [{
term: {
b: "A",
},
}],
must_not: [{
term: {
a: "B",
},
}],
},
}),
});
import pulumi
import json
import pulumi_elasticstack as elasticstack
my_index = elasticstack.ElasticsearchIndex("myIndex",
mappings=json.dumps({
"properties": {
"email": {
"type": "text",
},
"first_name": {
"type": "text",
},
"last_name": {
"type": "text",
},
},
}),
deletion_protection=False)
policy1 = elasticstack.ElasticsearchEnrichPolicy("policy1",
policy_type="match",
indices=[my_index.name],
match_field="email",
enrich_fields=[
"first_name",
"last_name",
],
query=json.dumps({
"bool": {
"must": [{
"term": {
"b": "A",
},
}],
"must_not": [{
"term": {
"a": "B",
},
}],
},
}))
package main
import (
"encoding/json"
"github.com/pulumi/pulumi-terraform-provider/sdks/go/elasticstack/elasticstack"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
tmpJSON0, err := json.Marshal(map[string]interface{}{
"properties": map[string]interface{}{
"email": map[string]interface{}{
"type": "text",
},
"first_name": map[string]interface{}{
"type": "text",
},
"last_name": map[string]interface{}{
"type": "text",
},
},
})
if err != nil {
return err
}
json0 := string(tmpJSON0)
myIndex, err := elasticstack.NewElasticsearchIndex(ctx, "myIndex", &elasticstack.ElasticsearchIndexArgs{
Mappings: pulumi.String(json0),
DeletionProtection: pulumi.Bool(false),
})
if err != nil {
return err
}
tmpJSON1, err := json.Marshal(map[string]interface{}{
"bool": map[string]interface{}{
"must": []map[string]interface{}{
map[string]interface{}{
"term": map[string]interface{}{
"b": "A",
},
},
},
"must_not": []map[string]interface{}{
map[string]interface{}{
"term": map[string]interface{}{
"a": "B",
},
},
},
},
})
if err != nil {
return err
}
json1 := string(tmpJSON1)
_, err = elasticstack.NewElasticsearchEnrichPolicy(ctx, "policy1", &elasticstack.ElasticsearchEnrichPolicyArgs{
PolicyType: pulumi.String("match"),
Indices: pulumi.StringArray{
myIndex.Name,
},
MatchField: pulumi.String("email"),
EnrichFields: pulumi.StringArray{
pulumi.String("first_name"),
pulumi.String("last_name"),
},
Query: pulumi.String(json1),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using System.Text.Json;
using Pulumi;
using Elasticstack = Pulumi.Elasticstack;
return await Deployment.RunAsync(() =>
{
var myIndex = new Elasticstack.ElasticsearchIndex("myIndex", new()
{
Mappings = JsonSerializer.Serialize(new Dictionary<string, object?>
{
["properties"] = new Dictionary<string, object?>
{
["email"] = new Dictionary<string, object?>
{
["type"] = "text",
},
["first_name"] = new Dictionary<string, object?>
{
["type"] = "text",
},
["last_name"] = new Dictionary<string, object?>
{
["type"] = "text",
},
},
}),
DeletionProtection = false,
});
var policy1 = new Elasticstack.ElasticsearchEnrichPolicy("policy1", new()
{
PolicyType = "match",
Indices = new[]
{
myIndex.Name,
},
MatchField = "email",
EnrichFields = new[]
{
"first_name",
"last_name",
},
Query = JsonSerializer.Serialize(new Dictionary<string, object?>
{
["bool"] = new Dictionary<string, object?>
{
["must"] = new[]
{
new Dictionary<string, object?>
{
["term"] = new Dictionary<string, object?>
{
["b"] = "A",
},
},
},
["must_not"] = new[]
{
new Dictionary<string, object?>
{
["term"] = new Dictionary<string, object?>
{
["a"] = "B",
},
},
},
},
}),
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.elasticstack.ElasticsearchIndex;
import com.pulumi.elasticstack.ElasticsearchIndexArgs;
import com.pulumi.elasticstack.ElasticsearchEnrichPolicy;
import com.pulumi.elasticstack.ElasticsearchEnrichPolicyArgs;
import static com.pulumi.codegen.internal.Serialization.*;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var myIndex = new ElasticsearchIndex("myIndex", ElasticsearchIndexArgs.builder()
.mappings(serializeJson(
jsonObject(
jsonProperty("properties", jsonObject(
jsonProperty("email", jsonObject(
jsonProperty("type", "text")
)),
jsonProperty("first_name", jsonObject(
jsonProperty("type", "text")
)),
jsonProperty("last_name", jsonObject(
jsonProperty("type", "text")
))
))
)))
.deletionProtection(false)
.build());
var policy1 = new ElasticsearchEnrichPolicy("policy1", ElasticsearchEnrichPolicyArgs.builder()
.policyType("match")
.indices(myIndex.name())
.matchField("email")
.enrichFields(
"first_name",
"last_name")
.query(serializeJson(
jsonObject(
jsonProperty("bool", jsonObject(
jsonProperty("must", jsonArray(jsonObject(
jsonProperty("term", jsonObject(
jsonProperty("b", "A")
))
))),
jsonProperty("must_not", jsonArray(jsonObject(
jsonProperty("term", jsonObject(
jsonProperty("a", "B")
))
)))
))
)))
.build());
}
}
resources:
myIndex:
type: elasticstack:ElasticsearchIndex
properties:
mappings:
fn::toJSON:
properties:
email:
type: text
first_name:
type: text
last_name:
type: text
deletionProtection: false
policy1:
type: elasticstack:ElasticsearchEnrichPolicy
properties:
policyType: match
indices:
- ${myIndex.name}
matchField: email
enrichFields:
- first_name
- last_name
query:
fn::toJSON:
bool:
must:
- term:
b: A
must_not:
- term:
a: B
Create ElasticsearchEnrichPolicy Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ElasticsearchEnrichPolicy(name: string, args: ElasticsearchEnrichPolicyArgs, opts?: CustomResourceOptions);
@overload
def ElasticsearchEnrichPolicy(resource_name: str,
args: ElasticsearchEnrichPolicyArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ElasticsearchEnrichPolicy(resource_name: str,
opts: Optional[ResourceOptions] = None,
enrich_fields: Optional[Sequence[str]] = None,
indices: Optional[Sequence[str]] = None,
match_field: Optional[str] = None,
policy_type: Optional[str] = None,
elasticsearch_connection: Optional[ElasticsearchEnrichPolicyElasticsearchConnectionArgs] = None,
elasticsearch_enrich_policy_id: Optional[str] = None,
execute: Optional[bool] = None,
name: Optional[str] = None,
query: Optional[str] = None)
func NewElasticsearchEnrichPolicy(ctx *Context, name string, args ElasticsearchEnrichPolicyArgs, opts ...ResourceOption) (*ElasticsearchEnrichPolicy, error)
public ElasticsearchEnrichPolicy(string name, ElasticsearchEnrichPolicyArgs args, CustomResourceOptions? opts = null)
public ElasticsearchEnrichPolicy(String name, ElasticsearchEnrichPolicyArgs args)
public ElasticsearchEnrichPolicy(String name, ElasticsearchEnrichPolicyArgs args, CustomResourceOptions options)
type: elasticstack:ElasticsearchEnrichPolicy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ElasticsearchEnrichPolicyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ElasticsearchEnrichPolicyArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ElasticsearchEnrichPolicyArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ElasticsearchEnrichPolicyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ElasticsearchEnrichPolicyArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var elasticsearchEnrichPolicyResource = new Elasticstack.ElasticsearchEnrichPolicy("elasticsearchEnrichPolicyResource", new()
{
EnrichFields = new[]
{
"string",
},
Indices = new[]
{
"string",
},
MatchField = "string",
PolicyType = "string",
ElasticsearchEnrichPolicyId = "string",
Execute = false,
Name = "string",
Query = "string",
});
example, err := elasticstack.NewElasticsearchEnrichPolicy(ctx, "elasticsearchEnrichPolicyResource", &elasticstack.ElasticsearchEnrichPolicyArgs{
EnrichFields: pulumi.StringArray{
pulumi.String("string"),
},
Indices: pulumi.StringArray{
pulumi.String("string"),
},
MatchField: pulumi.String("string"),
PolicyType: pulumi.String("string"),
ElasticsearchEnrichPolicyId: pulumi.String("string"),
Execute: pulumi.Bool(false),
Name: pulumi.String("string"),
Query: pulumi.String("string"),
})
var elasticsearchEnrichPolicyResource = new ElasticsearchEnrichPolicy("elasticsearchEnrichPolicyResource", ElasticsearchEnrichPolicyArgs.builder()
.enrichFields("string")
.indices("string")
.matchField("string")
.policyType("string")
.elasticsearchEnrichPolicyId("string")
.execute(false)
.name("string")
.query("string")
.build());
elasticsearch_enrich_policy_resource = elasticstack.ElasticsearchEnrichPolicy("elasticsearchEnrichPolicyResource",
enrich_fields=["string"],
indices=["string"],
match_field="string",
policy_type="string",
elasticsearch_enrich_policy_id="string",
execute=False,
name="string",
query="string")
const elasticsearchEnrichPolicyResource = new elasticstack.ElasticsearchEnrichPolicy("elasticsearchEnrichPolicyResource", {
enrichFields: ["string"],
indices: ["string"],
matchField: "string",
policyType: "string",
elasticsearchEnrichPolicyId: "string",
execute: false,
name: "string",
query: "string",
});
type: elasticstack:ElasticsearchEnrichPolicy
properties:
elasticsearchEnrichPolicyId: string
enrichFields:
- string
execute: false
indices:
- string
matchField: string
name: string
policyType: string
query: string
ElasticsearchEnrichPolicy Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The ElasticsearchEnrichPolicy resource accepts the following input properties:
- Enrich
Fields List<string> - Fields to add to matching incoming documents. These fields must be present in the source indices.
- Indices List<string>
- Array of one or more source indices used to create the enrich index.
- Match
Field string - Field in source indices used to match incoming documents.
- Policy
Type string - The type of enrich policy, can be one of geo_match, match, range.
- Elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- Elasticsearch
Enrich stringPolicy Id - The ID of this resource.
- Execute bool
- Whether to call the execute API function in order to create the enrich index.
- Name string
- Name of the enrich policy to manage.
- Query string
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- Enrich
Fields []string - Fields to add to matching incoming documents. These fields must be present in the source indices.
- Indices []string
- Array of one or more source indices used to create the enrich index.
- Match
Field string - Field in source indices used to match incoming documents.
- Policy
Type string - The type of enrich policy, can be one of geo_match, match, range.
- Elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection Args - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- Elasticsearch
Enrich stringPolicy Id - The ID of this resource.
- Execute bool
- Whether to call the execute API function in order to create the enrich index.
- Name string
- Name of the enrich policy to manage.
- Query string
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- enrich
Fields List<String> - Fields to add to matching incoming documents. These fields must be present in the source indices.
- indices List<String>
- Array of one or more source indices used to create the enrich index.
- match
Field String - Field in source indices used to match incoming documents.
- policy
Type String - The type of enrich policy, can be one of geo_match, match, range.
- elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch
Enrich StringPolicy Id - The ID of this resource.
- execute Boolean
- Whether to call the execute API function in order to create the enrich index.
- name String
- Name of the enrich policy to manage.
- query String
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- enrich
Fields string[] - Fields to add to matching incoming documents. These fields must be present in the source indices.
- indices string[]
- Array of one or more source indices used to create the enrich index.
- match
Field string - Field in source indices used to match incoming documents.
- policy
Type string - The type of enrich policy, can be one of geo_match, match, range.
- elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch
Enrich stringPolicy Id - The ID of this resource.
- execute boolean
- Whether to call the execute API function in order to create the enrich index.
- name string
- Name of the enrich policy to manage.
- query string
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- enrich_
fields Sequence[str] - Fields to add to matching incoming documents. These fields must be present in the source indices.
- indices Sequence[str]
- Array of one or more source indices used to create the enrich index.
- match_
field str - Field in source indices used to match incoming documents.
- policy_
type str - The type of enrich policy, can be one of geo_match, match, range.
- elasticsearch_
connection ElasticsearchEnrich Policy Elasticsearch Connection Args - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch_
enrich_ strpolicy_ id - The ID of this resource.
- execute bool
- Whether to call the execute API function in order to create the enrich index.
- name str
- Name of the enrich policy to manage.
- query str
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- enrich
Fields List<String> - Fields to add to matching incoming documents. These fields must be present in the source indices.
- indices List<String>
- Array of one or more source indices used to create the enrich index.
- match
Field String - Field in source indices used to match incoming documents.
- policy
Type String - The type of enrich policy, can be one of geo_match, match, range.
- elasticsearch
Connection Property Map - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch
Enrich StringPolicy Id - The ID of this resource.
- execute Boolean
- Whether to call the execute API function in order to create the enrich index.
- name String
- Name of the enrich policy to manage.
- query String
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
Outputs
All input properties are implicitly available as output properties. Additionally, the ElasticsearchEnrichPolicy resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing ElasticsearchEnrichPolicy Resource
Get an existing ElasticsearchEnrichPolicy resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: ElasticsearchEnrichPolicyState, opts?: CustomResourceOptions): ElasticsearchEnrichPolicy
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
elasticsearch_connection: Optional[ElasticsearchEnrichPolicyElasticsearchConnectionArgs] = None,
elasticsearch_enrich_policy_id: Optional[str] = None,
enrich_fields: Optional[Sequence[str]] = None,
execute: Optional[bool] = None,
indices: Optional[Sequence[str]] = None,
match_field: Optional[str] = None,
name: Optional[str] = None,
policy_type: Optional[str] = None,
query: Optional[str] = None) -> ElasticsearchEnrichPolicy
func GetElasticsearchEnrichPolicy(ctx *Context, name string, id IDInput, state *ElasticsearchEnrichPolicyState, opts ...ResourceOption) (*ElasticsearchEnrichPolicy, error)
public static ElasticsearchEnrichPolicy Get(string name, Input<string> id, ElasticsearchEnrichPolicyState? state, CustomResourceOptions? opts = null)
public static ElasticsearchEnrichPolicy get(String name, Output<String> id, ElasticsearchEnrichPolicyState state, CustomResourceOptions options)
resources: _: type: elasticstack:ElasticsearchEnrichPolicy get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- Elasticsearch
Enrich stringPolicy Id - The ID of this resource.
- Enrich
Fields List<string> - Fields to add to matching incoming documents. These fields must be present in the source indices.
- Execute bool
- Whether to call the execute API function in order to create the enrich index.
- Indices List<string>
- Array of one or more source indices used to create the enrich index.
- Match
Field string - Field in source indices used to match incoming documents.
- Name string
- Name of the enrich policy to manage.
- Policy
Type string - The type of enrich policy, can be one of geo_match, match, range.
- Query string
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- Elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection Args - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- Elasticsearch
Enrich stringPolicy Id - The ID of this resource.
- Enrich
Fields []string - Fields to add to matching incoming documents. These fields must be present in the source indices.
- Execute bool
- Whether to call the execute API function in order to create the enrich index.
- Indices []string
- Array of one or more source indices used to create the enrich index.
- Match
Field string - Field in source indices used to match incoming documents.
- Name string
- Name of the enrich policy to manage.
- Policy
Type string - The type of enrich policy, can be one of geo_match, match, range.
- Query string
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch
Enrich StringPolicy Id - The ID of this resource.
- enrich
Fields List<String> - Fields to add to matching incoming documents. These fields must be present in the source indices.
- execute Boolean
- Whether to call the execute API function in order to create the enrich index.
- indices List<String>
- Array of one or more source indices used to create the enrich index.
- match
Field String - Field in source indices used to match incoming documents.
- name String
- Name of the enrich policy to manage.
- policy
Type String - The type of enrich policy, can be one of geo_match, match, range.
- query String
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- elasticsearch
Connection ElasticsearchEnrich Policy Elasticsearch Connection - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch
Enrich stringPolicy Id - The ID of this resource.
- enrich
Fields string[] - Fields to add to matching incoming documents. These fields must be present in the source indices.
- execute boolean
- Whether to call the execute API function in order to create the enrich index.
- indices string[]
- Array of one or more source indices used to create the enrich index.
- match
Field string - Field in source indices used to match incoming documents.
- name string
- Name of the enrich policy to manage.
- policy
Type string - The type of enrich policy, can be one of geo_match, match, range.
- query string
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- elasticsearch_
connection ElasticsearchEnrich Policy Elasticsearch Connection Args - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch_
enrich_ strpolicy_ id - The ID of this resource.
- enrich_
fields Sequence[str] - Fields to add to matching incoming documents. These fields must be present in the source indices.
- execute bool
- Whether to call the execute API function in order to create the enrich index.
- indices Sequence[str]
- Array of one or more source indices used to create the enrich index.
- match_
field str - Field in source indices used to match incoming documents.
- name str
- Name of the enrich policy to manage.
- policy_
type str - The type of enrich policy, can be one of geo_match, match, range.
- query str
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
- elasticsearch
Connection Property Map - Elasticsearch connection configuration block. This property will be removed in a future provider version. Configure the Elasticsearch connection via the provider configuration instead.
- elasticsearch
Enrich StringPolicy Id - The ID of this resource.
- enrich
Fields List<String> - Fields to add to matching incoming documents. These fields must be present in the source indices.
- execute Boolean
- Whether to call the execute API function in order to create the enrich index.
- indices List<String>
- Array of one or more source indices used to create the enrich index.
- match
Field String - Field in source indices used to match incoming documents.
- name String
- Name of the enrich policy to manage.
- policy
Type String - The type of enrich policy, can be one of geo_match, match, range.
- query String
- Query used to filter documents in the enrich index. The policy only uses documents matching this query to enrich incoming documents. Defaults to a match_all query.
Supporting Types
ElasticsearchEnrichPolicyElasticsearchConnection, ElasticsearchEnrichPolicyElasticsearchConnectionArgs
- Api
Key string - API Key to use for authentication to Elasticsearch
- Bearer
Token string - Bearer Token to use for authentication to Elasticsearch
- Ca
Data string - PEM-encoded custom Certificate Authority certificate
- Ca
File string - Path to a custom Certificate Authority certificate
- Cert
Data string - PEM encoded certificate for client auth
- Cert
File string - Path to a file containing the PEM encoded certificate for client auth
- Endpoints List<string>
- Es
Client stringAuthentication - ES Client Authentication field to be used with the JWT token
- Insecure bool
- Disable TLS certificate validation
- Key
Data string - PEM encoded private key for client auth
- Key
File string - Path to a file containing the PEM encoded private key for client auth
- Password string
- Password to use for API authentication to Elasticsearch.
- Username string
- Username to use for API authentication to Elasticsearch.
- Api
Key string - API Key to use for authentication to Elasticsearch
- Bearer
Token string - Bearer Token to use for authentication to Elasticsearch
- Ca
Data string - PEM-encoded custom Certificate Authority certificate
- Ca
File string - Path to a custom Certificate Authority certificate
- Cert
Data string - PEM encoded certificate for client auth
- Cert
File string - Path to a file containing the PEM encoded certificate for client auth
- Endpoints []string
- Es
Client stringAuthentication - ES Client Authentication field to be used with the JWT token
- Insecure bool
- Disable TLS certificate validation
- Key
Data string - PEM encoded private key for client auth
- Key
File string - Path to a file containing the PEM encoded private key for client auth
- Password string
- Password to use for API authentication to Elasticsearch.
- Username string
- Username to use for API authentication to Elasticsearch.
- api
Key String - API Key to use for authentication to Elasticsearch
- bearer
Token String - Bearer Token to use for authentication to Elasticsearch
- ca
Data String - PEM-encoded custom Certificate Authority certificate
- ca
File String - Path to a custom Certificate Authority certificate
- cert
Data String - PEM encoded certificate for client auth
- cert
File String - Path to a file containing the PEM encoded certificate for client auth
- endpoints List<String>
- es
Client StringAuthentication - ES Client Authentication field to be used with the JWT token
- insecure Boolean
- Disable TLS certificate validation
- key
Data String - PEM encoded private key for client auth
- key
File String - Path to a file containing the PEM encoded private key for client auth
- password String
- Password to use for API authentication to Elasticsearch.
- username String
- Username to use for API authentication to Elasticsearch.
- api
Key string - API Key to use for authentication to Elasticsearch
- bearer
Token string - Bearer Token to use for authentication to Elasticsearch
- ca
Data string - PEM-encoded custom Certificate Authority certificate
- ca
File string - Path to a custom Certificate Authority certificate
- cert
Data string - PEM encoded certificate for client auth
- cert
File string - Path to a file containing the PEM encoded certificate for client auth
- endpoints string[]
- es
Client stringAuthentication - ES Client Authentication field to be used with the JWT token
- insecure boolean
- Disable TLS certificate validation
- key
Data string - PEM encoded private key for client auth
- key
File string - Path to a file containing the PEM encoded private key for client auth
- password string
- Password to use for API authentication to Elasticsearch.
- username string
- Username to use for API authentication to Elasticsearch.
- api_
key str - API Key to use for authentication to Elasticsearch
- bearer_
token str - Bearer Token to use for authentication to Elasticsearch
- ca_
data str - PEM-encoded custom Certificate Authority certificate
- ca_
file str - Path to a custom Certificate Authority certificate
- cert_
data str - PEM encoded certificate for client auth
- cert_
file str - Path to a file containing the PEM encoded certificate for client auth
- endpoints Sequence[str]
- es_
client_ strauthentication - ES Client Authentication field to be used with the JWT token
- insecure bool
- Disable TLS certificate validation
- key_
data str - PEM encoded private key for client auth
- key_
file str - Path to a file containing the PEM encoded private key for client auth
- password str
- Password to use for API authentication to Elasticsearch.
- username str
- Username to use for API authentication to Elasticsearch.
- api
Key String - API Key to use for authentication to Elasticsearch
- bearer
Token String - Bearer Token to use for authentication to Elasticsearch
- ca
Data String - PEM-encoded custom Certificate Authority certificate
- ca
File String - Path to a custom Certificate Authority certificate
- cert
Data String - PEM encoded certificate for client auth
- cert
File String - Path to a file containing the PEM encoded certificate for client auth
- endpoints List<String>
- es
Client StringAuthentication - ES Client Authentication field to be used with the JWT token
- insecure Boolean
- Disable TLS certificate validation
- key
Data String - PEM encoded private key for client auth
- key
File String - Path to a file containing the PEM encoded private key for client auth
- password String
- Password to use for API authentication to Elasticsearch.
- username String
- Username to use for API authentication to Elasticsearch.
Import
NOTE: while importing index resource, keep in mind, that some of the default index settings will be imported into the TF state too
You can later adjust the index configuration to account for those imported settings
$ pulumi import elasticstack:index/elasticsearchEnrichPolicy:ElasticsearchEnrichPolicy policy1 <cluster_uuid>/<policy_name>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- elasticstack elastic/terraform-provider-elasticstack
- License
- Notes
- This Pulumi package is based on the
elasticstack
Terraform Provider.