结合 Amazon Kinesis Data Firehose 使用 Amazon Lambda - Amazon Lambda
Amazon Web Services 文档中描述的 Amazon Web Services 服务或功能可能因区域而异。要查看适用于中国区域的差异,请参阅中国的 Amazon Web Services 服务入门

结合 Amazon Kinesis Data Firehose 使用 Amazon Lambda

Amazon Kinesis Data Firehose 捕获、转换流数据并将其加载到下游服务,如 Kinesis Data Analytics Firehose 或 Amazon S3。您可以编写 Lambda 函数来请求附加的自定义数据处理,然后它会在下游发送。

例 Amazon Kinesis Data Firehose 消息事件

{ "invocationId": "invoked123", "deliveryStreamArn": "aws:lambda:events", "region": "us-west-2", "records": [ { "data": "SGVsbG8gV29ybGQ=", "recordId": "record1", "approximateArrivalTimestamp": 1510772160000, "kinesisRecordMetadata": { "shardId": "shardId-000000000000", "partitionKey": "4d1ad2b9-24f8-4b9d-a088-76e9947c317a", "approximateArrivalTimestamp": "2012-04-23T18:25:43.511Z", "sequenceNumber": "49546986683135544286507457936321625675700192471156785154", "subsequenceNumber": "" } }, { "data": "SGVsbG8gV29ybGQ=", "recordId": "record2", "approximateArrivalTimestamp": 151077216000, "kinesisRecordMetadata": { "shardId": "shardId-000000000001", "partitionKey": "4d1ad2b9-24f8-4b9d-a088-76e9947c318a", "approximateArrivalTimestamp": "2012-04-23T19:25:43.511Z", "sequenceNumber": "49546986683135544286507457936321625675700192471156785155", "subsequenceNumber": "" } } ] }

有关更多信息,请参阅 Amazon Kinesis Data Firehose 开发人员指南中的 Kinesis Data Firehose 数据转换