如何使用 KCL 使用 Kinesis Data Streams 中的记录 [英] How to consume records from Kinesis Data Streams using KCL

查看:20
本文介绍了如何使用 KCL 使用 Kinesis Data Streams 中的记录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用类似于 https:/的 Kinesis 客户端库来使用 Kinesis 数据流/github.com/aws-samples/amazon-kinesis-learning.但在这个例子中,他们安排了这个过程.我想在没有调度程序的情况下使用传入的记录.

I am trying to consume Kinesis data streams using Kinesis Client Library similar to https://github.com/aws-samples/amazon-kinesis-learning. But in this example they scheduled the process. I want to consume records afferent without scheduler.

我不想使用 DynamoDB、cloudWatch.期望一个简单的消费者在流中消费记录

I don't want to use DynamoDB, cloudWatch. Expecting a simple consumer to consume records in stream

有没有什么办法可以在没有调度程序的情况下使用java处理记录

Is there any way to process records without scheduler using java

推荐答案

KCL 使用 DynamoDB 来管理分片租约和检查点 - 此功能/依赖项对于 KCL 提供的内容至关重要.如果您不想要这些,我不确定您为什么要首先使用 KCL.您可以使用 Lambda 来使用您的流,也可以直接调用 API - 这里有一些示例代码 - https://docs.amazonaws.cn/en_us/streams/latest/dev/developing-consumers-with-sdk.html

KCL uses DynamoDB to manage shard leases and checkpoints - this functionality/dependency is critical to what KCL provides. If you do not want these, I'm not sure why you want to use KCL in the first place. You can either use Lambda to consume your stream, or invoke the APIs directly - there is some sample code here - https://docs.amazonaws.cn/en_us/streams/latest/dev/developing-consumers-with-sdk.html

这篇关于如何使用 KCL 使用 Kinesis Data Streams 中的记录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆