aws-elasticsearch

AWS ElasticSearch - Match Query Not Working

旧街凉风 提交于 2020-05-17 07:42:52
问题 I have deployed an elastic search instance through AWS` managed ElasticSearch service (version 7.4.2) and having trouble getting "match" queries working. I am playing around with the sample flights dataset and running the following query: Data: [ { "FlightNum": "HX0WBLI", "DestCountry": "IT", "OriginWeather": "Damaging Wind", "OriginCityName": "Chitose / Tomakomai", "AvgTicketPrice": 988.8975638746068, "DistanceMiles": 5650.511340218511, "FlightDelay": false, "DestWeather": "Sunny", "Dest":

ElasticSearch Error: Invalid term-aggregator order path [_key]. Unknown aggregation [_key] while performing aggregation from Java

纵饮孤独 提交于 2020-01-16 19:37:06
问题 i'm getting the below error when performing aggregation Error: Invalid term-aggregator order path [_key]. Unknown aggregation [_key] while performing aggregation from Java code : public static void main(String[] args){ JestClient jestClient = getJestClient(); SearchSourceBuilder searchSourceBuilder = new SearchSourceBuilder(); searchSourceBuilder.size(100); searchSourceBuilder.aggregation(AggregationBuilders.terms("products").field("myField.keyword"). valueType(ValueType.STRING).size(100));

If lambda can access the elasticsearch with in same vpc?

大兔子大兔子 提交于 2020-01-07 09:02:25
问题 within same VPC, If lambda can access the elasticsearch without applying IAM role? Is this possible? 回答1: You need to provide an IAM role for a lambda function and provide the IAM role access to ES. 回答2: If your Lambda runs within a VPC, you can configure the ElasticSearch access policy to an IP-based policy. AWS does provide samples for various kinds of access policies. IP based access policy 回答3: You will want to configure two Security Groups: Configure the Lambda function to use the VPC.

Logstash conf error - amazon_es

不羁的心 提交于 2019-12-24 08:34:16
问题 I am trying to configure for the first time my logstash.conf file with an output to amazon_es. My whole logstash.conf file is here: input { jdbc { jdbc_connection_string => "jdbc:mysql://localhost:3306/testdb" # The user we wish to execute our statement as jdbc_user => "root" jdbc_password => "root" # The path to our downloaded jdbc driver jdbc_driver_library => "/mnt/c/Users/xxxxxxxx/mysql-connector-java-5.1.45/mysql-connector-java-5.1.45-bin.jar" jdbc_driver_class => "com.mysql.jdbc.Driver"

Enabling regex support on AWS Managed ElasticSearch in painless scripts

霸气de小男生 提交于 2019-12-22 04:52:01
问题 I am trying to upload templates to my AWS managed ElasticSearch. ElasticSearch responds with a 500 error complaining that I need to set script.painless.regex.enabled to true . I know that you cannot edit the elasticsearch.yml file directly, but is there anyway to allow for support of regex in painless scripts on AWS managed ES? 回答1: There is no way yet to use regex under AWS ES cluster. You can try to use StringTokenizer, as following example: example value: doc['your_str_field.keyword']

AWS elastic search error “[Errno 8] nodename nor servname provided, or not known.”

帅比萌擦擦* 提交于 2019-12-21 03:58:27
问题 I created one AWS elasticsearch instance. I want to access it using a python script. I specified my AWS configuration (access key, secret key, region). I am using below code to access the AWS ES instance: from elasticsearch import Elasticsearch, RequestsHttpConnection from requests_aws4auth import AWS4Auth AWS_ACCESS_KEY = '**************' AWS_SECRET_KEY = '*****************' region = 'us-east-1' service = 'es' awsauth = AWS4Auth(AWS_ACCESS_KEY, AWS_SECRET_KEY, region, service) host = 'https:

Filebeat not sending updated logs to AWS elastic search

回眸只為那壹抹淺笑 提交于 2019-12-13 03:04:47
问题 I have configured filebeat(version 7.1.1) on my system to send logs to AWS Elastic Search but it is not doing following two things appropriately: Updating it's own log file at /var/log/filebeat , and Sending the updated logs from /var/log/*logs to AWS ES Issue 1 : When I run sudo service filebeat restart it does not update logs files. I tried running filebeat -c /etc/filebeat/filebeat.yml to update the log files. When I run this command the terminal hangs and I have to manually close the

Update field mappings template in created index under an alias

爷,独闯天下 提交于 2019-12-11 16:00:14
问题 I have deployed a template in AWS ElasticSearch named users-version-1-order-1 , and indexed data under users-all index which is searchable via users alias. So, all documents are always indexed and updated in users-all , how do I deal with schema change moving forward with applying a new template version? e.g. PUT users-version-2-order-2 and apply it to users-all index. [UPDATE] { "index_patterns": "users*", "order": 6, "version": 6, "aliases": { "users": {} }, "settings": { "number_of_shards"

Signature4 signing for elastic search in aws

左心房为你撑大大i 提交于 2019-12-11 08:08:05
问题 I'm using the aws managed elasticsearch/ I'm using the high-level java client for elastic search. Is there a way to use aws signature4 signing for the requests made with the high level client? 回答1: All you need to do perform the signing calculations and add the appropriate headers to your request. See Examples: Signature Calculations in AWS Signature Version 4 for Java and C# examples. I took took this code and put my own interface on top: import net.craigcaulfield.awsutils.signing.auth

Route53 for AWS Elastic Search Domain gives certificate error

喜欢而已 提交于 2019-12-07 00:10:56
问题 I have create a AWS elastic search domain in Virginia and got a Endpoint url. Now I wanted to configure the Route53 behavior around it, so that a caller can use the same url, even though there is some change in elastic search or in case of a disaster recovery. So, Virginia Route 53 -- 1 Points to -- Virgina Elastic Search Domain URL Oregon Route 53 -- 2 Points to -- Oregon Elastic Search Domain URL Main Route 53 -- 3 Points to -- Route 53 1 or 2 I have already create these and also created