【发布时间】:2019-11-22 15:43:55
【问题描述】:
我想使用 cloudformation 将 Kinesis Stream 直接连接到 DynamoDB 表。看起来这样做的方法是使用 StreamConsumer。下面的 cloudformation 脚本给了我这个错误:
Value 'kinesisstreamtodynamodb' at 'streamARN' failed to satisfy constraint: Member must satisfy regular expression pattern: arn:aws.*:kinesis:.*:\d{12}:stream/.+ (Service: AmazonKinesis
它不喜欢 StreamARN: !Ref KinesisSTream 属性。
我可能会更改此配置以在 kinesis 流和 dynamodb 表之间使用 lambda,但现在我想让此配置正常工作。
在将运动流连接到 dynamodb 表时我做错了什么?
KinesisStream:
Type: AWS::Kinesis::Stream
Properties:
Name: kinesisstreamtodynamodb
ShardCount: 1
DynamoTable:
Type: AWS::DynamoDB::Table
Description: streaming data from kinesis
Properties:
TableName: Kinesis-DynamoTable
AttributeDefinitions:
- AttributeName: "timestamp"
AttributeType: "S"
- AttributeName: "logmessage"
AttributeType: "S"
KeySchema:
- AttributeName: "timestamp"
KeyType: "HASH"
- AttributeName: "logmessage"
KeyType: "RANGE"
ProvisionedThroughput:
ReadCapacityUnits: 5
WriteCapacityUnits: 5
StreamConsumer:
Type: "AWS::Kinesis::StreamConsumer"
Properties:
StreamARN: !Ref 'KinesisStream'
ConsumerName: !Ref 'DynamoTable'
【问题讨论】:
标签: amazon-web-services amazon-dynamodb amazon-cloudformation amazon-kinesis