Compare commits
43 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 9022db56eb | |||
| 0d78441e76 | |||
| 375eb2cefe | |||
| 62d037ae63 | |||
| 50bc532349 | |||
| 6a1cc2c276 | |||
| e39f18da89 | |||
| 029a369bcc | |||
| 19ddf35e40 | |||
| 37d28ed22b | |||
| 8d066f218c | |||
| d991dd48c5 | |||
| efd492c8be | |||
| 39ed675426 | |||
| f856815737 | |||
| be895309a4 | |||
| 833e88704c | |||
| 211da242d6 | |||
| f6cede1ff5 | |||
| 24dcb0ab5c | |||
| 611dd62151 | |||
| e0823b4209 | |||
| 97476bda60 | |||
| d05a252b94 | |||
| caa8ba67a9 | |||
| 0d6010716a | |||
| 72730e9d36 | |||
| b031f07f1f | |||
| 6a27363b71 | |||
| c7dc5e2e8d | |||
| 48ed4ecaac | |||
| cc6f01b92c | |||
| 57471d916c | |||
| 86cce61ca6 | |||
| a8a6d5b0c5 | |||
| 866ab1a039 | |||
| e821f4dd1f | |||
| de90dec19a | |||
| ffc1237805 | |||
| ecb3acda35 | |||
| a0590a400c | |||
| 9861e07d7c | |||
| 9738b5c54b |
@@ -1,28 +1,29 @@
|
|||||||
---
|
---
|
||||||
layout: default
|
layout: default
|
||||||
title: Elasticsearch OSS Java high-level REST client
|
title: OpenSearch Java high-level REST client
|
||||||
nav_order: 60
|
nav_order: 60
|
||||||
---
|
---
|
||||||
|
|
||||||
# Elasticsearch OSS Java high-level REST client
|
# OpenSearch Java high-level REST client
|
||||||
|
|
||||||
The Elasticsearch OSS Java high-level REST client allows you to interact with your OpenSearch clusters and indices through Java methods and data structures rather than HTTP methods and JSON.
|
Although the OpenSearch Java high-level REST client is still usable, we recommend that you use the [OpenSearch Java client]({{site.url}}{{site.baseurl}}/clients/java/), which replaces the existing Java high-level REST client.
|
||||||
|
{: .note}
|
||||||
|
|
||||||
You submit requests to your cluster using request objects, which allows you to create indices, add data to documents, or complete other operations with your cluster. In return, you get back response objects that have all of the available information, such as the associated index or ID, from your cluster.
|
The OpenSearch Java high-level REST client lets you interact with your OpenSearch clusters and indices through Java methods and data structures rather than HTTP methods and JSON.
|
||||||
|
|
||||||
## Setup
|
## Setup
|
||||||
|
|
||||||
To start using the Elasticsearch OSS Java high-level REST client, ensure that you have the following dependency in your project's `pom.xml` file:
|
To start using the OpenSearch Java high-level REST client, ensure that you have the following dependency in your project's `pom.xml` file:
|
||||||
|
|
||||||
```
|
```
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.elasticsearch.client</groupId>
|
<groupId>org.opensearch.client</groupId>
|
||||||
<artifactId>elasticsearch-rest-high-level-client</artifactId>
|
<artifactId>opensearch-rest-high-level-client</artifactId>
|
||||||
<version>7.10.2</version>
|
<version>{{site.opensearch_version}}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
```
|
```
|
||||||
|
|
||||||
You can now start your OpenSearch cluster. The 7.10.2 Elasticsearch OSS high-level REST client works with the 1.x versions of OpenSearch.
|
You can now start your OpenSearch cluster. The OpenSearch 1.x high-level REST client works with the 1.x versions of OpenSearch.
|
||||||
|
|
||||||
## Sample code
|
## Sample code
|
||||||
|
|
||||||
@@ -33,22 +34,21 @@ import org.apache.http.auth.UsernamePasswordCredentials;
|
|||||||
import org.apache.http.client.CredentialsProvider;
|
import org.apache.http.client.CredentialsProvider;
|
||||||
import org.apache.http.impl.client.BasicCredentialsProvider;
|
import org.apache.http.impl.client.BasicCredentialsProvider;
|
||||||
import org.apache.http.impl.nio.client.HttpAsyncClientBuilder;
|
import org.apache.http.impl.nio.client.HttpAsyncClientBuilder;
|
||||||
import org.elasticsearch.action.admin.indices.delete.DeleteIndexRequest;
|
import org.opensearch.action.admin.indices.delete.DeleteIndexRequest;
|
||||||
import org.elasticsearch.action.delete.DeleteRequest;
|
import org.opensearch.action.delete.DeleteRequest;
|
||||||
import org.elasticsearch.action.delete.DeleteResponse;
|
import org.opensearch.action.delete.DeleteResponse;
|
||||||
import org.elasticsearch.action.get.GetRequest;
|
import org.opensearch.action.get.GetRequest;
|
||||||
import org.elasticsearch.action.get.GetResponse;
|
import org.opensearch.action.get.GetResponse;
|
||||||
import org.elasticsearch.action.index.IndexRequest;
|
import org.opensearch.action.index.IndexRequest;
|
||||||
import org.elasticsearch.action.index.IndexResponse;
|
import org.opensearch.action.index.IndexResponse;
|
||||||
import org.elasticsearch.action.support.master.AcknowledgedResponse;
|
import org.opensearch.action.support.master.AcknowledgedResponse;
|
||||||
import org.elasticsearch.client.RequestOptions;
|
import org.opensearch.client.RequestOptions;
|
||||||
import org.elasticsearch.client.RestClient;
|
import org.opensearch.client.RestClient;
|
||||||
import org.elasticsearch.client.RestClientBuilder;
|
import org.opensearch.client.RestClientBuilder;
|
||||||
import org.elasticsearch.client.RestHighLevelClient;
|
import org.opensearch.client.RestHighLevelClient;
|
||||||
import org.elasticsearch.client.indices.CreateIndexRequest;
|
import org.opensearch.client.indices.CreateIndexRequest;
|
||||||
import org.elasticsearch.client.indices.CreateIndexResponse;
|
import org.opensearch.client.indices.CreateIndexResponse;
|
||||||
import org.elasticsearch.common.settings.Settings;
|
import org.opensearch.common.settings.Settings;
|
||||||
import org.elasticsearch.common.xcontent.XContentType;
|
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
@@ -59,7 +59,7 @@ public class RESTClientSample {
|
|||||||
|
|
||||||
//Point to keystore with appropriate certificates for security.
|
//Point to keystore with appropriate certificates for security.
|
||||||
System.setProperty("javax.net.ssl.trustStore", "/full/path/to/keystore");
|
System.setProperty("javax.net.ssl.trustStore", "/full/path/to/keystore");
|
||||||
System.setProperty("javax.net.ssl.trustStorePassword", password-to-keystore);
|
System.setProperty("javax.net.ssl.trustStorePassword", "password-to-keystore");
|
||||||
|
|
||||||
//Establish credentials to use basic authentication.
|
//Establish credentials to use basic authentication.
|
||||||
//Only for demo purposes. Do not specify your credentials in code.
|
//Only for demo purposes. Do not specify your credentials in code.
|
||||||
@@ -122,3 +122,13 @@ public class RESTClientSample {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Elasticsearch OSS Java high-level REST client
|
||||||
|
|
||||||
|
We recommend using the OpenSearch client to connect to OpenSearch clusters, but if you must use the Elasticsearch OSS Java high-level REST client, version 7.10.2 of the Elasticsearch OSS client also works with the 1.x versions of OpenSearch.
|
||||||
|
|
||||||
|
### Migrating to the OpenSearch Java high-level REST client
|
||||||
|
|
||||||
|
Migrating from the Elasticsearch OSS client to the OpenSearch high-level REST client is as simple as changing your Maven dependency to one that references [OpenSearch's dependency](#setup).
|
||||||
|
|
||||||
|
Afterward, change all references of `org.elasticsearch` to `org.opensearch`, and you're ready to start submitting requests to your OpenSearch cluster.
|
||||||
|
|||||||
@@ -0,0 +1,165 @@
|
|||||||
|
---
|
||||||
|
layout: default
|
||||||
|
title: OpenSearch Java client
|
||||||
|
nav_order: 65
|
||||||
|
---
|
||||||
|
|
||||||
|
# Java client
|
||||||
|
|
||||||
|
The OpenSearch Java client allows you to interact with your OpenSearch clusters through Java methods and data structures rather than HTTP methods and raw JSON.
|
||||||
|
|
||||||
|
For example, you can submit requests to your cluster using objects to create indices, add data to documents, or complete some other operation using the client's built-in methods.
|
||||||
|
|
||||||
|
## Setup
|
||||||
|
|
||||||
|
To start using the OpenSearch Java client, ensure that you have the following dependency in your project's `pom.xml` file:
|
||||||
|
|
||||||
|
```
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.opensearch.client</groupId>
|
||||||
|
<artifactId>opensearch-java</artifactId>
|
||||||
|
<version>0.1.0</version>
|
||||||
|
</dependency>
|
||||||
|
```
|
||||||
|
|
||||||
|
If you're using Gradle, add the following dependencies to your project.
|
||||||
|
|
||||||
|
```
|
||||||
|
dependencies {
|
||||||
|
implementation 'org.opensearch.client:opensearch-rest-client: {{site.opensearch_version}}'
|
||||||
|
implementation 'org.opensearch.client:opensearch-java:0.1.0'
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
You can now start your OpenSearch cluster.
|
||||||
|
|
||||||
|
The following example uses credentials that come with the default OpenSearch configuration. If you're using the OpenSearch Java client with your own OpenSearch cluster, be sure to change the code to use your own credentials.
|
||||||
|
|
||||||
|
## Sample code
|
||||||
|
|
||||||
|
This section uses a class called `IndexData`, which is a simple Java class that stores basic data and methods. For your own OpenSearch cluster, you might find that you need a more robust class to store your data.
|
||||||
|
|
||||||
|
### IndexData class
|
||||||
|
|
||||||
|
```java
|
||||||
|
static class IndexData {
|
||||||
|
private String firstName;
|
||||||
|
private String lastName;
|
||||||
|
|
||||||
|
public IndexData(String firstName, String lastName) {
|
||||||
|
this.firstName = firstName;
|
||||||
|
this.lastName = lastName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getFirstName() {
|
||||||
|
return firstName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setFirstName(String firstName) {
|
||||||
|
this.firstName = firstName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLastName() {
|
||||||
|
return lastName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLastName(String lastName) {
|
||||||
|
this.lastName = lastName;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return String.format("IndexData{first name='%s', last name='%s'}", firstName, lastName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### OpenSearch client example
|
||||||
|
|
||||||
|
```java
|
||||||
|
import org.apache.http.HttpHost;
|
||||||
|
import org.apache.http.auth.AuthScope;
|
||||||
|
import org.apache.http.auth.UsernamePasswordCredentials;
|
||||||
|
import org.apache.http.client.CredentialsProvider;
|
||||||
|
import org.apache.http.impl.client.BasicCredentialsProvider;
|
||||||
|
import org.apache.http.impl.nio.client.HttpAsyncClientBuilder;
|
||||||
|
import org.opensearch.client.RestClient;
|
||||||
|
import org.opensearch.client.RestClientBuilder;
|
||||||
|
import org.opensearch.clients.base.RestClientTransport;
|
||||||
|
import org.opensearch.clients.base.Transport;
|
||||||
|
import org.opensearch.clients.json.jackson.JacksonJsonpMapper;
|
||||||
|
import org.opensearch.clients.opensearch.OpenSearchClient;
|
||||||
|
import org.opensearch.clients.opensearch._global.IndexRequest;
|
||||||
|
import org.opensearch.clients.opensearch._global.IndexResponse;
|
||||||
|
import org.opensearch.clients.opensearch._global.SearchResponse;
|
||||||
|
import org.opensearch.clients.opensearch.indices.*;
|
||||||
|
import org.opensearch.clients.opensearch.indices.put_settings.IndexSettingsBody;
|
||||||
|
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
public class OpenSearchClientExample {
|
||||||
|
public static void main(String[] args) {
|
||||||
|
try{
|
||||||
|
System.setProperty("javax.net.ssl.trustStore", "/full/path/to/keystore");
|
||||||
|
System.setProperty("javax.net.ssl.trustStorePassword", "password-to-keystore");
|
||||||
|
|
||||||
|
//Only for demo purposes. Don't specify your credentials in code.
|
||||||
|
final CredentialsProvider credentialsProvider = new BasicCredentialsProvider();
|
||||||
|
credentialsProvider.setCredentials(AuthScope.ANY,
|
||||||
|
new UsernamePasswordCredentials("admin", "admin"));
|
||||||
|
|
||||||
|
//Initialize the client with SSL and TLS enabled
|
||||||
|
RestClient restClient = RestClient.builder(new HttpHost("localhost", 9200, "https")).
|
||||||
|
setHttpClientConfigCallback(new RestClientBuilder.HttpClientConfigCallback() {
|
||||||
|
@Override
|
||||||
|
public HttpAsyncClientBuilder customizeHttpClient(HttpAsyncClientBuilder httpClientBuilder) {
|
||||||
|
return httpClientBuilder.setDefaultCredentialsProvider(credentialsProvider);
|
||||||
|
}
|
||||||
|
}).build();
|
||||||
|
Transport transport = new RestClientTransport(restClient, new JacksonJsonpMapper());
|
||||||
|
OpenSearchClient client = new OpenSearchClient(transport);
|
||||||
|
|
||||||
|
//Create the index
|
||||||
|
String index = "sample-index";
|
||||||
|
CreateRequest createIndexRequest = new CreateRequest.Builder().index(index).build();
|
||||||
|
client.indices().create(createIndexRequest);
|
||||||
|
|
||||||
|
//Add some settings to the index
|
||||||
|
IndexSettings indexSettings = new IndexSettings.Builder().autoExpandReplicas("0-all").build();
|
||||||
|
IndexSettingsBody settingsBody = new IndexSettingsBody.Builder().settings(indexSettings).build();
|
||||||
|
PutSettingsRequest putSettingsRequest = new PutSettingsRequest.Builder().index(index).value(settingsBody).build();
|
||||||
|
client.indices().putSettings(putSettingsRequest);
|
||||||
|
|
||||||
|
//Index some data
|
||||||
|
IndexData indexData = new IndexData("first_name", "Bruce");
|
||||||
|
IndexRequest<IndexData> indexRequest = new IndexRequest.Builder<IndexData>().index(index).id("1").value(indexData).build();
|
||||||
|
client.index(indexRequest);
|
||||||
|
|
||||||
|
//Search for the document
|
||||||
|
SearchResponse<IndexData> searchResponse = client.search(s -> s.index(index), IndexData.class);
|
||||||
|
for (int i = 0; i< searchResponse.hits().hits().size(); i++) {
|
||||||
|
System.out.println(searchResponse.hits().hits().get(i).source());
|
||||||
|
}
|
||||||
|
|
||||||
|
//Delete the document
|
||||||
|
client.delete(b -> b.index(index).id("1"));
|
||||||
|
|
||||||
|
// Delete the index
|
||||||
|
DeleteRequest deleteRequest = new DeleteRequest.Builder().index(index).build();
|
||||||
|
DeleteResponse deleteResponse = client.indices().delete(deleteRequest);
|
||||||
|
|
||||||
|
restClient.close();
|
||||||
|
} catch (IOException e){
|
||||||
|
System.out.println(e.toString());
|
||||||
|
} finally {
|
||||||
|
try {
|
||||||
|
if (client != null) {
|
||||||
|
client.close();
|
||||||
|
}
|
||||||
|
} catch (IOException e) {
|
||||||
|
System.out.println(e.toString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
@@ -57,6 +57,9 @@ The OpenSearch Logstash plugin has two installation options at this time: Linux
|
|||||||
|
|
||||||
Make sure you have [Java Development Kit (JDK)](https://www.oracle.com/java/technologies/javase-downloads.html) version 8 or 11 installed.
|
Make sure you have [Java Development Kit (JDK)](https://www.oracle.com/java/technologies/javase-downloads.html) version 8 or 11 installed.
|
||||||
|
|
||||||
|
If you're migrating from an existing Logstash installation, you can install the [OpenSearch output plugin](https://rubygems.org/gems/logstash-output-opensearch/) manually and [update pipeline.conf](https://opensearch.org/docs/latest/clients/logstash/ship-to-opensearch/). We include this plugin by default in our tarball and Docker downloads.
|
||||||
|
{: .note }
|
||||||
|
|
||||||
### Tarball
|
### Tarball
|
||||||
|
|
||||||
1. Download the Logstash tarball from [OpenSearch downloads](https://opensearch.org/downloads.html).
|
1. Download the Logstash tarball from [OpenSearch downloads](https://opensearch.org/downloads.html).
|
||||||
|
|||||||
@@ -0,0 +1,142 @@
|
|||||||
|
---
|
||||||
|
layout: default
|
||||||
|
title: Dashboards query language
|
||||||
|
nav_order: 99
|
||||||
|
---
|
||||||
|
|
||||||
|
# Dashboards Query Language
|
||||||
|
|
||||||
|
Similar to the [Query DSL]({{site.url}}{{site.baseurl}}/opensearch/query-dsl/index) that lets you use the HTTP request body to search for data, you can use the Dashbaords Query Language (DQL) in OpenSearch Dashboards to search for data and visualizations.
|
||||||
|
|
||||||
|
For example, if you want to see all visualizations of visits to a host based in the US, enter `geo.dest:US` into the search field, and Dashboards refreshes to display all related data.
|
||||||
|
|
||||||
|
Just like the query DSL, DQL has a handful of query types, so use whichever best fits your use case.
|
||||||
|
|
||||||
|
This section uses the OpenSearch Dashboards sample web log data. To add sample data in Dashboards, log in to OpenSearch Dashboards, choose **Home**, **Add sample data**, and then **Add data**.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
#### Table of contents
|
||||||
|
1. TOC
|
||||||
|
{:toc}
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Terms query
|
||||||
|
|
||||||
|
The most basic query is to just specify the term you're searching for.
|
||||||
|
|
||||||
|
```
|
||||||
|
host:www.example.com
|
||||||
|
```
|
||||||
|
|
||||||
|
To access an object's nested field, list the complete path to the field separated by periods. For example, to retrieve the `lat` field in the `coordinates` object:
|
||||||
|
|
||||||
|
```
|
||||||
|
coordinates.lat:43.7102
|
||||||
|
```
|
||||||
|
|
||||||
|
DQL also supports leading and trailing wildcards, so you can search for any terms that match your pattern.
|
||||||
|
|
||||||
|
```
|
||||||
|
host.keyword:*.example.com/*
|
||||||
|
```
|
||||||
|
|
||||||
|
To check if a field exists or has any data, use a wildcard to see if Dashboards returns any results.
|
||||||
|
|
||||||
|
```
|
||||||
|
host.keyword:*
|
||||||
|
```
|
||||||
|
|
||||||
|
## Boolean query
|
||||||
|
|
||||||
|
To mix and match, or even combine, multiple queries for more refined results, you can use the boolean operators `and`, `or`, and `not`. DQL is not case sensitive, so `AND` and `and` are the same.
|
||||||
|
|
||||||
|
```
|
||||||
|
host.keyword:www.example.com and response.keyword:200
|
||||||
|
```
|
||||||
|
|
||||||
|
The following example demonstrates how to use multiple operators in one query.
|
||||||
|
|
||||||
|
```
|
||||||
|
geo.dest:US or response.keyword:200 and host.keyword:www.example.com
|
||||||
|
```
|
||||||
|
|
||||||
|
Remember that boolean operators follow the logical precedence order of `not`, `and`, and `or`, so if you have an expression like the previous example, `response.keyword:200 and host.keyword:www.example.com` gets evaluated first, and then Dashboards uses that result to compare with `geo.dest:US`.
|
||||||
|
|
||||||
|
To avoid confusion, we recommend using parentheses to dictate the order you want to evaluate in. If you want to evaluate `geo.dest:US or response.keyword:200` first, your expression becomes:
|
||||||
|
|
||||||
|
```
|
||||||
|
(geo.dest:US or response.keyword:200) and host.keyword:www.example.com
|
||||||
|
```
|
||||||
|
|
||||||
|
## Date and range queries
|
||||||
|
|
||||||
|
DQL also supports inequalities if you're using numeric inequalities.
|
||||||
|
|
||||||
|
```
|
||||||
|
bytes >= 15 and memory < 15
|
||||||
|
```
|
||||||
|
|
||||||
|
Similarly, you can use the same method to find a date before or after your query. `>` indicates a search for a date after your specified date, and `<` returns dates before.
|
||||||
|
|
||||||
|
```
|
||||||
|
@timestamp > "2020-12-14T09:35:33"
|
||||||
|
```
|
||||||
|
|
||||||
|
## Nested field query
|
||||||
|
|
||||||
|
If you have a document with nested fields, you have to specify which parts of the document you want to retrieve.
|
||||||
|
|
||||||
|
Suppose that you have the following document:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"superheroes":[
|
||||||
|
{
|
||||||
|
"hero-name": "Superman",
|
||||||
|
"real-identity": "Clark Kent",
|
||||||
|
"age": 28
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"hero-name": "Batman",
|
||||||
|
"real-identity": "Bruce Wayne",
|
||||||
|
"age": 26
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"hero-name": "Flash",
|
||||||
|
"real-identity": "Barry Allen",
|
||||||
|
"age": 28
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"hero-name": "Robin",
|
||||||
|
"real-identity": "Dick Grayson",
|
||||||
|
"age": 15
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The following example demonstrates how to use DQL to retrieve a specific field.
|
||||||
|
|
||||||
|
```
|
||||||
|
superheroes: {hero-name: Superman}
|
||||||
|
```
|
||||||
|
|
||||||
|
If you want to retrieve multiple objects from your document, just specify all of the fields you want to retrieve.
|
||||||
|
|
||||||
|
```
|
||||||
|
superheroes: {hero-name: Superman} and superheroes: {hero-name: Batman}
|
||||||
|
```
|
||||||
|
|
||||||
|
The previous boolean and range queries still work, so you can submit a more refined query.
|
||||||
|
|
||||||
|
```
|
||||||
|
superheroes: {hero-name: Superman and age < 50}
|
||||||
|
```
|
||||||
|
|
||||||
|
If your document has an object nested within another object, you can still retrieve data by specifying all of the levels.
|
||||||
|
|
||||||
|
```
|
||||||
|
justice-league.superheroes: {hero-name:Superman}
|
||||||
|
```
|
||||||
@@ -24,24 +24,24 @@ PUT _cluster/settings
|
|||||||
|
|
||||||
Setting | Default | Description
|
Setting | Default | Description
|
||||||
:--- | :--- | :---
|
:--- | :--- | :---
|
||||||
`plugins.anomaly_detection.enabled` | True | Whether the anomaly detection plugin is enabled or not. If disabled, all detectors immediately stop running.
|
plugins.anomaly_detection.enabled | True | Whether the anomaly detection plugin is enabled or not. If disabled, all detectors immediately stop running.
|
||||||
`plugins.anomaly_detection.max_anomaly_detectors` | 1,000 | The maximum number of non-high cardinality detectors (no category field) users can create.
|
plugins.anomaly_detection.max_anomaly_detectors | 1,000 | The maximum number of non-high cardinality detectors (no category field) users can create.
|
||||||
`plugins.anomaly_detection.max_multi_entity_anomaly_detectors` | 10 | The maximum number of high cardinality detectors (with category field) in a cluster.
|
plugins.anomaly_detection.max_multi_entity_anomaly_detectors | 10 | The maximum number of high cardinality detectors (with category field) in a cluster.
|
||||||
`plugins.anomaly_detection.max_anomaly_features` | 5 | The maximum number of features for a detector.
|
plugins.anomaly_detection.max_anomaly_features | 5 | The maximum number of features for a detector.
|
||||||
`plugins.anomaly_detection.ad_result_history_rollover_period` | 12h | How often the rollover condition is checked. If `true`, the anomaly detection plugin rolls over the result index to a new index.
|
plugins.anomaly_detection.ad_result_history_rollover_period | 12h | How often the rollover condition is checked. If `true`, the anomaly detection plugin rolls over the result index to a new index.
|
||||||
`plugins.anomaly_detection.ad_result_history_max_docs_per_shard` | 1,350,000,000 | The maximum number of documents in a single shard of the result index. The anomaly detection plugin only counts the refreshed documents in the primary shards.
|
plugins.anomaly_detection.ad_result_history_max_docs_per_shard | 1,350,000,000 | The maximum number of documents in a single shard of the result index. The anomaly detection plugin only counts the refreshed documents in the primary shards.
|
||||||
`plugins.anomaly_detection.max_entities_per_query` | 1,000,000 | The maximum unique values per detection interval for high cardinality detectors. By default, if the category field(s) have more than the configured unique values in a detector interval, the anomaly detection plugin orders them by the natural ordering of categorical values (for example, entity `ab` comes before `bc`) and then selects the top values.
|
plugins.anomaly_detection.max_entities_per_query | 1,000,000 | The maximum unique values per detection interval for high cardinality detectors. By default, if the category field(s) have more than the configured unique values in a detector interval, the anomaly detection plugin orders them by the natural ordering of categorical values (for example, entity `ab` comes before `bc`) and then selects the top values.
|
||||||
`plugins.anomaly_detection.max_entities_for_preview` | 5 | The maximum unique category field values displayed with the preview operation for high cardinality detectors. By default, if the category field(s) have more than the configured unique values in a detector interval, the anomaly detection plugin orders them by the natural ordering of categorical values (for example, entity `ab` comes before `bc`) and then selects the top values.
|
plugins.anomaly_detection.max_entities_for_preview | 5 | The maximum unique category field values displayed with the preview operation for high cardinality detectors. By default, if the category field(s) have more than the configured unique values in a detector interval, the anomaly detection plugin orders them by the natural ordering of categorical values (for example, entity `ab` comes before `bc`) and then selects the top values.
|
||||||
`plugins.anomaly_detection.max_primary_shards` | 10 | The maximum number of primary shards an anomaly detection index can have.
|
plugins.anomaly_detection.max_primary_shards | 10 | The maximum number of primary shards an anomaly detection index can have.
|
||||||
`plugins.anomaly_detection.filter_by_backend_roles` | False | When you enable the security plugin and set this to `true`, the anomaly detection plugin filters results based on the user's backend role(s).
|
plugins.anomaly_detection.filter_by_backend_roles | False | When you enable the security plugin and set this to `true`, the anomaly detection plugin filters results based on the user's backend role(s).
|
||||||
`plugins.anomaly_detection.max_batch_task_per_node` | 10 | Starting a historical analysis triggers a batch task. This setting is the number of batch tasks that you can run per data node. You can tune this setting from 1 to 1,000. If the data nodes can’t support all batch tasks and you’re not sure if the data nodes are capable of running more historical analysis, add more data nodes instead of changing this setting to a higher value. Increasing this value might bring more load on each data node.
|
plugins.anomaly_detection.max_batch_task_per_node | 10 | Starting a historical analysis triggers a batch task. This setting is the number of batch tasks that you can run per data node. You can tune this setting from 1 to 1,000. If the data nodes can’t support all batch tasks and you’re not sure if the data nodes are capable of running more historical analysis, add more data nodes instead of changing this setting to a higher value. Increasing this value might bring more load on each data node.
|
||||||
`plugins.anomaly_detection.max_old_ad_task_docs_per_detector` | 1 | You can run historical analysis for the same detector many times. For each run, the anomaly detection plugin creates a new task. This setting is the number of previous tasks the plugin keeps. Set this value to at least 1 to track its last run. You can keep a maximum of 1,000 old tasks to avoid overwhelming the cluster.
|
plugins.anomaly_detection.max_old_ad_task_docs_per_detector | 1 | You can run historical analysis for the same detector many times. For each run, the anomaly detection plugin creates a new task. This setting is the number of previous tasks the plugin keeps. Set this value to at least 1 to track its last run. You can keep a maximum of 1,000 old tasks to avoid overwhelming the cluster.
|
||||||
`plugins.anomaly_detection.batch_task_piece_size` | 1,000 | The date range for a historical task is split into smaller pieces and the anomaly detection plugin runs the task piece by piece. Each piece contains 1,000 detection intervals by default. For example, if detector interval is 1 minute and one piece is 1,000 minutes, the feature data is queried every 1,000 minutes. You can change this setting from 1 to 10,000.
|
plugins.anomaly_detection.batch_task_piece_size | 1,000 | The date range for a historical task is split into smaller pieces and the anomaly detection plugin runs the task piece by piece. Each piece contains 1,000 detection intervals by default. For example, if detector interval is 1 minute and one piece is 1,000 minutes, the feature data is queried every 1,000 minutes. You can change this setting from 1 to 10,000.
|
||||||
`plugins.anomaly_detection.batch_task_piece_interval_seconds` | 5 | Add a time interval between two pieces of the same historical analysis task. This interval prevents the task from consuming too much of the available resources and starving other operations like search and bulk index. You can change this setting from 1 to 600 seconds.
|
plugins.anomaly_detection.batch_task_piece_interval_seconds | 5 | Add a time interval between two pieces of the same historical analysis task. This interval prevents the task from consuming too much of the available resources and starving other operations like search and bulk index. You can change this setting from 1 to 600 seconds.
|
||||||
`plugins.anomaly_detection.max_top_entities_for_historical_analysis` | 1,000 | The maximum number of top entities that you run for a high cardinality detector historical analysis. The range is from 1 to 10,000.
|
plugins.anomaly_detection.max_top_entities_for_historical_analysis | 1,000 | The maximum number of top entities that you run for a high cardinality detector historical analysis. The range is from 1 to 10,000.
|
||||||
`plugins.anomaly_detection.max_running_entities_per_detector_for_historical_analysis` | 10 | The number of entity tasks that you can run in parallel for a high cardinality detector analysis. The task slots available on your cluster also impact how many entities run in parallel. If a cluster has 3 data nodes, each data node has 10 task slots by default. Say you already have two high cardinality detectors and each of them run 10 entities. If you start a single-entity detector that takes 1 task slot, the number of task slots available is 10 * 3 - 10 * 2 - 1 = 9. If you now start a new high cardinality detector, the detector can only run 9 entities in parallel and not 10. You can tune this value from 1 to 1,000 based on your cluster's capability. If you set a higher value, the anomaly detection plugin runs historical analysis faster but also consumes more resources.
|
plugins.anomaly_detection.max_running_entities_per_detector_for_historical_analysis | 10 | The number of entity tasks that you can run in parallel for a high cardinality detector analysis. The task slots available on your cluster also impact how many entities run in parallel. If a cluster has 3 data nodes, each data node has 10 task slots by default. Say you already have two high cardinality detectors and each of them run 10 entities. If you start a single-entity detector that takes 1 task slot, the number of task slots available is 10 * 3 - 10 * 2 - 1 = 9. If you now start a new high cardinality detector, the detector can only run 9 entities in parallel and not 10. You can tune this value from 1 to 1,000 based on your cluster's capability. If you set a higher value, the anomaly detection plugin runs historical analysis faster but also consumes more resources.
|
||||||
`plugins.anomaly_detection.max_cached_deleted_tasks` | 1,000 | You can rerun historical analysis for a single detector as many times as you like. The anomaly detection plugin only keeps a limited number of old tasks, by default 1 old task. If you run historical analysis three times for a detector, the oldest task is deleted. Because historical analysis generates a number of anomaly results in a short span of time, it's necessary to clean up anomaly results for a deleted task. With this field, you can configure how many deleted tasks you can cache at most. The plugin cleans up a task's results when it's deleted. If the plugin fails to do this cleanup, it adds the task's results into a cache and an hourly cron job performs the cleanup. You can use this setting to limit how many old tasks are put into cache to avoid a DDoS attack. After an hour, if still you find an old task result in the cache, use the [delete detector results API]({{site.url}}{{site.baseurl}}/monitoring-plugins/ad/api/#delete-detector-results) to delete the task result manually. You can tune this setting from 1 to 10,000.
|
plugins.anomaly_detection.max_cached_deleted_tasks | 1,000 | You can rerun historical analysis for a single detector as many times as you like. The anomaly detection plugin only keeps a limited number of old tasks, by default 1 old task. If you run historical analysis three times for a detector, the oldest task is deleted. Because historical analysis generates a number of anomaly results in a short span of time, it's necessary to clean up anomaly results for a deleted task. With this field, you can configure how many deleted tasks you can cache at most. The plugin cleans up a task's results when it's deleted. If the plugin fails to do this cleanup, it adds the task's results into a cache and an hourly cron job performs the cleanup. You can use this setting to limit how many old tasks are put into cache to avoid a DDoS attack. After an hour, if still you find an old task result in the cache, use the [delete detector results API]({{site.url}}{{site.baseurl}}/monitoring-plugins/ad/api/#delete-detector-results) to delete the task result manually. You can tune this setting from 1 to 10,000.
|
||||||
`plugins.anomaly_detection.delete_anomaly_result_when_delete_detector` | False | Whether the anomaly detection plugin deletes the anomaly result when you delete a detector. If you want to save some disk space, especially if you've high cardinality detectors generating a lot of results, set this field to true. Alternatively, you can use the [delete detector results API]({{site.url}}{{site.baseurl}}/monitoring-plugins/ad/api/#delete-detector-results) to manually delete the results.
|
plugins.anomaly_detection.delete_anomaly_result_when_delete_detector | False | Whether the anomaly detection plugin deletes the anomaly result when you delete a detector. If you want to save some disk space, especially if you've high cardinality detectors generating a lot of results, set this field to true. Alternatively, you can use the [delete detector results API]({{site.url}}{{site.baseurl}}/monitoring-plugins/ad/api/#delete-detector-results) to manually delete the results.
|
||||||
`plugins.anomaly_detection.dedicated_cache_size` | 10 | If the real-time analysis of a high cardinality detector starts successfully, the anomaly detection plugin guarantees keeping 10 (dynamically adjustable via this setting) entities' models in memory per node. If the number of entities exceeds this limit, the plugin puts the extra entities' models in a memory space shared by all detectors. The actual number of entities varies based on the memory that you've available and the frequencies of the entities. If you'd like the plugin to guarantee keeping more entities' models in memory and if you're cluster has sufficient memory, you can increase this setting value.
|
plugins.anomaly_detection.dedicated_cache_size | 10 | If the real-time analysis of a high cardinality detector starts successfully, the anomaly detection plugin guarantees keeping 10 (dynamically adjustable via this setting) entities' models in memory per node. If the number of entities exceeds this limit, the plugin puts the extra entities' models in a memory space shared by all detectors. The actual number of entities varies based on the memory that you've available and the frequencies of the entities. If you'd like the plugin to guarantee keeping more entities' models in memory and if you're cluster has sufficient memory, you can increase this setting value.
|
||||||
`plugins.anomaly_detection.max_concurrent_preview` | 2 | The maximum number of concurrent previews. You can use this setting to limit resource usage.
|
plugins.anomaly_detection.max_concurrent_preview | 2 | The maximum number of concurrent previews. You can use this setting to limit resource usage.
|
||||||
`plugins.anomaly_detection.model_max_size_percent` | 0.1 | The upper bound of the memory percentage for a model.
|
plugins.anomaly_detection.model_max_size_percent | 0.1 | The upper bound of the memory percentage for a model.
|
||||||
|
|||||||
@@ -40,9 +40,19 @@ Source for the OpenTelemetry Collector.
|
|||||||
|
|
||||||
Option | Required | Description
|
Option | Required | Description
|
||||||
:--- | :--- | :---
|
:--- | :--- | :---
|
||||||
ssl | No | Boolean, whether to connect to the OpenTelemetry Collector over SSL.
|
port | No | Integer, the port OTel trace source is running on. Default is `21890`.
|
||||||
sslKeyCertChainFile | No | String, path to the security certificate (e.g. `"config/demo-data-prepper.crt"`.
|
request_timeout | No | Integer, the request timeout in millis. Default is `10_000`.
|
||||||
sslKeyFile | No | String, path to the security certificate key (e.g. `"config/demo-data-prepper.key"`).
|
health_check_service | No | Boolean, enables a gRPC health check service under `grpc.health.v1/Health/Check`. Default is `false`.
|
||||||
|
proto_reflection_service | No | Boolean, enables a reflection service for Protobuf services (see [gRPC reflection](https://github.com/grpc/grpc/blob/master/doc/server-reflection.md) and [gRPC Server Reflection Tutorial](https://github.com/grpc/grpc-java/blob/master/documentation/server-reflection-tutorial.md) docs). Default is `false`.
|
||||||
|
unframed_requests | No | Boolean, enable requests not framed using the gRPC wire protocol.
|
||||||
|
thread_count | No | Integer, the number of threads to keep in the ScheduledThreadPool. Default is `200`.
|
||||||
|
max_connection_count | No | Integer, the maximum allowed number of open connections. Default is `500`.
|
||||||
|
ssl | No | Boolean, enables connections to the OTel source port over TLS/SSL. Defaults to `true`.
|
||||||
|
sslKeyCertChainFile | Conditionally | String, file-system path or AWS S3 path to the security certificate (e.g. `"config/demo-data-prepper.crt"` or `"s3://my-secrets-bucket/demo-data-prepper.crt"`). Required if ssl is set to `true`.
|
||||||
|
sslKeyFile | Conditionally | String, file-system path or AWS S3 path to the security key (e.g. `"config/demo-data-prepper.key"` or `"s3://my-secrets-bucket/demo-data-prepper.key"`). Required if ssl is set to `true`.
|
||||||
|
useAcmCertForSSL | No | Boolean, enables TLS/SSL using certificate and private key from AWS Certificate Manager (ACM). Default is `false`.
|
||||||
|
acmCertificateArn | Conditionally | String, represents the ACM certificate ARN. ACM certificate take preference over S3 or local file system certificate. Required if `useAcmCertForSSL` is set to `true`.
|
||||||
|
awsRegion | Conditionally | String, represents the AWS region to use ACM or S3. Required if `useAcmCertForSSL` is set to `true` or `sslKeyCertChainFile` and `sslKeyFile` are AWS S3 paths.
|
||||||
|
|
||||||
|
|
||||||
### file
|
### file
|
||||||
@@ -114,11 +124,17 @@ Option | Required | Description
|
|||||||
:--- | :--- | :---
|
:--- | :--- | :---
|
||||||
time_out | No | Integer, forwarded request timeout in seconds. Defaults to 3 seconds.
|
time_out | No | Integer, forwarded request timeout in seconds. Defaults to 3 seconds.
|
||||||
span_agg_count | No | Integer, batch size for number of spans per request. Defaults to 48.
|
span_agg_count | No | Integer, batch size for number of spans per request. Defaults to 48.
|
||||||
discovery_mode | No | String, peer discovery mode to be used. Allowable values are `static` and `dns`. Defaults to `static`.
|
target_port | No | Integer, the destination port to forward requests to. Defaults to `21890`.
|
||||||
|
discovery_mode | No | String, peer discovery mode to be used. Allowable values are `static`, `dns`, and `aws_cloud_map`. Defaults to `static`.
|
||||||
static_endpoints | No | List, containing string endpoints of all Data Prepper instances.
|
static_endpoints | No | List, containing string endpoints of all Data Prepper instances.
|
||||||
domain_name | No | String, single domain name to query DNS against. Typically used by creating multiple DNS A Records for the same domain.
|
domain_name | No | String, single domain name to query DNS against. Typically used by creating multiple DNS A Records for the same domain.
|
||||||
ssl | No | Boolean, indicating whether TLS should be used. Default is true.
|
ssl | No | Boolean, indicating whether TLS should be used. Default is true.
|
||||||
sslKeyCertChainFile | No | String, path to the security certificate
|
awsCloudMapNamespaceName | Conditionally | String, name of your CloudMap Namespace. Required if `discovery_mode` is set to `aws_cloud_map`.
|
||||||
|
awsCloudMapServiceName | Conditionally | String, service name within your CloudMap Namespace. Required if `discovery_mode` is set to `aws_cloud_map`.
|
||||||
|
sslKeyCertChainFile | Conditionally | String, represents the SSL certificate chain file path or AWS S3 path. S3 path example `s3://<bucketName>/<path>`. Required if `ssl` is set to `true`.
|
||||||
|
useAcmCertForSSL | No | Boolean, enables TLS/SSL using certificate and private key from AWS Certificate Manager (ACM). Default is `false`.
|
||||||
|
awsRegion | Conditionally | String, represents the AWS region to use ACM, S3, or CloudMap. Required if `useAcmCertForSSL` is set to `true` or `sslKeyCertChainFile` and `sslKeyFile` are AWS S3 paths.
|
||||||
|
acmCertificateArn | Conditionally | String represents the ACM certificate ARN. ACM certificate take preference over S3 or local file system certificate. Required if `useAcmCertForSSL` is set to `true`.
|
||||||
|
|
||||||
### string_converter
|
### string_converter
|
||||||
|
|
||||||
@@ -144,8 +160,9 @@ hosts | Yes | List of OpenSearch hosts to write to (e.g. `["https://localhost:92
|
|||||||
cert | No | String, path to the security certificate (e.g. `"config/root-ca.pem"`) if the cluster uses the OpenSearch security plugin.
|
cert | No | String, path to the security certificate (e.g. `"config/root-ca.pem"`) if the cluster uses the OpenSearch security plugin.
|
||||||
username | No | String, username for HTTP basic authentication.
|
username | No | String, username for HTTP basic authentication.
|
||||||
password | No | String, password for HTTP basic authentication.
|
password | No | String, password for HTTP basic authentication.
|
||||||
aws_sigv4 | No | Boolean, whether to use IAM signing to connect to an Amazon ES cluster. For your access key, secret key, and optional session token, Data Prepper uses the default credential chain (environment variables, Java system properties, `~/.aws/credential`, etc.).
|
aws_sigv4 | No | Boolean, whether to use IAM signing to connect to an Amazon OpenSearch Service domain. For your access key, secret key, and optional session token, Data Prepper uses the default credential chain (environment variables, Java system properties, `~/.aws/credential`, etc.).
|
||||||
aws_region | No | String, AWS region for the cluster (e.g. `"us-east-1"`) if you are connecting to Amazon ES.
|
aws_region | No | String, AWS region (e.g. `"us-east-1"`) for the domain if you are connecting to Amazon OpenSearch Service.
|
||||||
|
aws_sts_role | No | String, IAM role which the sink plugin will assume to sign request to Amazon OpenSearch Service. If not provided the plugin will use the default credentials.
|
||||||
trace_analytics_raw | No | Boolean, default false. Whether to export as trace data to the `otel-v1-apm-span-*` index pattern (alias `otel-v1-apm-span`) for use with the Trace Analytics OpenSearch Dashboards plugin.
|
trace_analytics_raw | No | Boolean, default false. Whether to export as trace data to the `otel-v1-apm-span-*` index pattern (alias `otel-v1-apm-span`) for use with the Trace Analytics OpenSearch Dashboards plugin.
|
||||||
trace_analytics_service_map | No | Boolean, default false. Whether to export as trace data to the `otel-v1-apm-service-map` index for use with the service map component of the Trace Analytics OpenSearch Dashboards plugin.
|
trace_analytics_service_map | No | Boolean, default false. Whether to export as trace data to the `otel-v1-apm-service-map` index for use with the service map component of the Trace Analytics OpenSearch Dashboards plugin.
|
||||||
index | No | String, name of the index to export to. Only required if you don't use the `trace_analytics_raw` or `trace_analytics_service_map` presets.
|
index | No | String, name of the index to export to. Only required if you don't use the `trace_analytics_raw` or `trace_analytics_service_map` presets.
|
||||||
|
|||||||
@@ -31,12 +31,38 @@ The default Helm chart deploys a three-node cluster. We recommend that you have
|
|||||||
|
|
||||||
## Install OpenSearch using Helm
|
## Install OpenSearch using Helm
|
||||||
|
|
||||||
1. Clone the [helm-charts](https://github.com/opensearch-project/helm-charts) repository:
|
1. Add `opensearch` [helm-charts](https://github.com/opensearch-project/helm-charts) repository to Helm:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://github.com/opensearch-project/helm-charts
|
helm repo add opensearch https://opensearch-project.github.io/helm-charts/
|
||||||
```
|
```
|
||||||
|
|
||||||
|
1. Update the available charts locally from charts repositories:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm repo update
|
||||||
|
```
|
||||||
|
|
||||||
|
1. To search for the OpenSearch-related Helm charts:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm search repo opensearch
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash
|
||||||
|
NAME CHART VERSION APP VERSION DESCRIPTION
|
||||||
|
opensearch/opensearch 1.0.7 1.0.0 A Helm chart for OpenSearch
|
||||||
|
opensearch/opensearch-dashboards 1.0.4 1.0.0 A Helm chart for OpenSearch Dashboards
|
||||||
|
```
|
||||||
|
|
||||||
|
1. Deploy OpenSearch:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm install my-deployment opensearch/opensearch
|
||||||
|
```
|
||||||
|
|
||||||
|
You can also build the `opensearch-1.0.0.tgz` file manually:
|
||||||
|
|
||||||
1. Change to the `opensearch` directory:
|
1. Change to the `opensearch` directory:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|||||||
@@ -24,12 +24,14 @@ The tarball supports most Linux distributions, including CentOS 7, Amazon Linux
|
|||||||
cd opensearch-{{site.opensearch_version}}
|
cd opensearch-{{site.opensearch_version}}
|
||||||
```
|
```
|
||||||
|
|
||||||
1. Run OpenSearch:
|
1. Run OpenSearch with the demo security configuration:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
./opensearch-tar-install.sh
|
./opensearch-tar-install.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you configure the security plugin for production use (or disable it), you can run OpenSearch using `./bin/opensearch`.
|
||||||
|
|
||||||
1. Open a second terminal session, and send requests to the server to verify that OpenSearch is up and running:
|
1. Open a second terminal session, and send requests to the server to verify that OpenSearch is up and running:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ PUT my-knn-index-1
|
|||||||
"properties": {
|
"properties": {
|
||||||
"my_vector1": {
|
"my_vector1": {
|
||||||
"type": "knn_vector",
|
"type": "knn_vector",
|
||||||
"dimension": 4,
|
"dimension": 2,
|
||||||
"method": {
|
"method": {
|
||||||
"name": "hnsw",
|
"name": "hnsw",
|
||||||
"space_type": "l2",
|
"space_type": "l2",
|
||||||
|
|||||||
@@ -201,7 +201,7 @@ opensearch.requestHeadersWhitelist: ["securitytenant","Authorization","x-forward
|
|||||||
You must also enable the authentication type in `opensearch_dashboards.yml`:
|
You must also enable the authentication type in `opensearch_dashboards.yml`:
|
||||||
|
|
||||||
```yml
|
```yml
|
||||||
plugins.security.auth.type: "proxy"
|
opensearch_security.auth.type: "proxy"
|
||||||
plugins.security.proxycache.user_header: "x-proxy-user"
|
opensearch_security.proxycache.user_header: "x-proxy-user"
|
||||||
plugins.security.proxycache.roles_header: "x-proxy-roles"
|
opensearch_security.proxycache.roles_header: "x-proxy-roles"
|
||||||
```
|
```
|
||||||
|
|||||||
@@ -47,6 +47,21 @@ If you use the `-f` argument rather than `-cd`, you can load a single YAML file
|
|||||||
-key ../../../config/kirk-key.pem
|
-key ../../../config/kirk-key.pem
|
||||||
```
|
```
|
||||||
|
|
||||||
|
To resolve all environment variables before applying the security configurations, use the `-rev` parameter.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
./securityadmin.sh -cd ../securityconfig/ \
|
||||||
|
-rev \
|
||||||
|
-cacert ../../../root-ca.pem \
|
||||||
|
-cert ../../../kirk.pem \
|
||||||
|
-key ../../../kirk.key.pem
|
||||||
|
```
|
||||||
|
|
||||||
|
Here’s an example of an environment variable in the `config.yml` file:
|
||||||
|
|
||||||
|
```yml
|
||||||
|
password: ${env.LDAP_PASSWORD}
|
||||||
|
```
|
||||||
|
|
||||||
## Configure the admin certificate
|
## Configure the admin certificate
|
||||||
|
|
||||||
|
|||||||
@@ -34,8 +34,9 @@ Component | Purpose
|
|||||||
[Index State Management]({{site.url}}{{site.baseurl}}/im-plugin/) | Automate index operations
|
[Index State Management]({{site.url}}{{site.baseurl}}/im-plugin/) | Automate index operations
|
||||||
[KNN]({{site.url}}{{site.baseurl}}/search-plugins/knn/) | Find “nearest neighbors” in your vector data
|
[KNN]({{site.url}}{{site.baseurl}}/search-plugins/knn/) | Find “nearest neighbors” in your vector data
|
||||||
[Performance Analyzer]({{site.url}}{{site.baseurl}}/monitoring-plugins/pa/) | Monitor and optimize your cluster
|
[Performance Analyzer]({{site.url}}{{site.baseurl}}/monitoring-plugins/pa/) | Monitor and optimize your cluster
|
||||||
[Anomaly Detection]({{site.url}}{{site.baseurl}}/monitoring-plugins/ad/) | Identify atypical data and receive automatic notifications
|
[Anomaly detection]({{site.url}}{{site.baseurl}}/monitoring-plugins/ad/) | Identify atypical data and receive automatic notifications
|
||||||
[Asynchronous Search]({{site.url}}{{site.baseurl}}/search-plugins/async/) | Run search requests in the background
|
[Asynchronous search]({{site.url}}{{site.baseurl}}/search-plugins/async/) | Run search requests in the background
|
||||||
|
[Cross-cluster replication]({{site.url}}{{site.baseurl}}/replication-plugin/index/) | Replicate your data across multiple OpenSearch clusters
|
||||||
|
|
||||||
Most OpenSearch plugins have corresponding OpenSearch Dashboards plugins that provide a convenient, unified user interface.
|
Most OpenSearch plugins have corresponding OpenSearch Dashboards plugins that provide a convenient, unified user interface.
|
||||||
|
|
||||||
@@ -59,10 +60,20 @@ Docker
|
|||||||
1. In a new terminal session, run:
|
1. In a new terminal session, run:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
curl -XGET --insecure https://localhost:9200 -u admin:admin
|
curl -XGET --insecure -u 'admin:admin' 'https://localhost:9200'
|
||||||
```
|
```
|
||||||
|
|
||||||
To learn more, see [Install and configure OpenSearch]({{site.url}}{{site.baseurl}}/opensearch/install/) and [Install and configure OpenSearch Dashboards]({{site.url}}{{site.baseurl}}/dashboards/install/).
|
To learn more, see [Docker image]({{site.url}}{{site.baseurl}}/opensearch/install/docker/) and [Docker security configuration]({{site.url}}{{site.baseurl}}/opensearch/install/docker-security/).
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
For more comprehensive installation instructions for other download types, such as tarballs, see these pages:
|
||||||
|
|
||||||
|
- [Install and configure OpenSearch]({{site.url}}{{site.baseurl}}/opensearch/install/)
|
||||||
|
- [Install and configure OpenSearch Dashboards]({{site.url}}{{site.baseurl}}/dashboards/install/)
|
||||||
|
|
||||||
|
|
||||||
## The secure path forward
|
## The secure path forward
|
||||||
|
|||||||
Reference in New Issue
Block a user