简体   繁体   English

如何从 Kinesis firehose 将 stream 数据传输到自托管 elasticsearch 集群?

[英]How can I stream data to self hosted elasticsearch cluster from Kinesis firehose?

I deployed a ES cluster to AWS EKS and it can be access through application load balancer.我在 AWS EKS 上部署了一个 ES 集群,它可以通过应用程序负载均衡器访问。 I have created an index in the cluster.我在集群中创建了一个索引。 I am going to deploy a Kinesis firehose to use http_endpoint as the target to stream data to ES cluster.我将部署 Kinesis firehose 以使用http_endpoint作为 stream 数据到 ES 集群的目标。

But how can I configure what http verb firehose uses to put data to ES endpoint?但是如何配置 http 动词 firehose 用于将数据放入 ES 端点的内容? For example, my ES endpoint is http://xxxx.com/myindex and I'd like the firehose to send POST request to this endpoint.例如,我的 ES 端点是http://xxxx.com/myindex ,我希望 firehose 向该端点发送POST请求。 How can I configure it to use POST rather than PUT ?如何将其配置为使用POST而不是PUT

Kinesis Firehose doesn't give you that much control over what the HTTP requests look like, unfortunately, since there are only a handful of configuration options for the HTTP Endpoint destination.不幸的是,Kinesis Firehose 无法让您对 HTTP 请求的外观进行太多控制,因为 HTTP 端点目标只有少数配置选项

Kinesis sends HTTP requests according to their own specification, and expects responses to look in a specific way. Kinesis 根据自己的规范发送 HTTP 请求,并期望响应以特定方式查看。 You can find the specification here. 您可以在此处找到规范。

This specification is not compatible with Elasticsearch's Index API as you discovered.如您所见,此规范与 Elasticsearch 的索引 API 不兼容。 On a side note, you will probably want to use the Bulk API for performance reasons, since Kinesis will buffer events and deliver multiple ones in one request.附带说明一下,出于性能原因,您可能希望使用 Bulk API,因为 Kinesis 将缓冲事件并在一个请求中传递多个事件。

So, you will most likely need something in-between Kinesis and your Elasticsearch cluster to handle the differences in regards to the HTTP requests and responses.因此,您很可能需要 Kinesis 和 Elasticsearch 集群之间的一些东西来处理 HTTP 请求和响应方面的差异。 This could be a simply nginx proxy, for instance, or it could be something like an API Gateway which invokes a Lambda function.例如,这可能是一个简单的 nginx 代理,或者它可能是类似于 API 网关,它调用 Lambda ZC1C11AB4068E68A44478。 This Lambda function then sends a request to your index' Bulk API and constructs a response for Kinesis according to the HTTP specification.然后,此 Lambda function 向您的索引的批量 API 发送请求,并根据 Z29DC986Z6265F78 规范为 Kinesis 构造响应。

I hope that helps.我希望这会有所帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 kinesis firehose stream 数据如何自我管理 elasticsearch? - How does kinesis firehose stream data to self managed elasticsearch? Kinesis Stream和Kinesis Firehose更新Elasticsearch索引 - Kinesis Stream and Kinesis Firehose Updating Elasticsearch Indexes 从数据 stream (Kinesis) 到 OpenSearch AWS 创建交付 stream (Firehose) - Create delivery stream (Firehose) from data stream (Kinesis) to OpenSearch AWS 使用Kinesis Firehose将数据从SQL Server流传输到Redshift - Stream Data from SQL Server into Redshift with Kinesis Firehose 如何在不通过 Kinesis Data 的情况下直接将 KPL(Kinesis Producer Library)集成到 Kinesis firehose Stream - How to integrate KPL (Kinesis Producer Library) to Kinesis firehose directly without going through Kinesis Data Stream AWS Kinesis Firehose到ElasticSearch Geo数据映射 - AWS Kinesis Firehose to ElasticSearch Geo data mapping 使用kinesis流和firehose对流数据进行排序 - Ordering of streaming data with kinesis stream and firehose 关于 Kinesis Firehose 数据 stream 到 AWS Lambda - Regarding KInesis Firehose data stream to AWS Lambda 从 Kinesis 数据 stream 到 Kinesis Firehose 到 S3 存储桶的 CloudFront 实时日志 - CloudFront realtime logs from Kinesis data stream to Kinesis Firehose to S3 bucket 从 kinesis 流/firehose 填充 dynamodb 表 - Populate dynamodb table from kinesis stream/firehose
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM