Search code examples
amazon-kinesisamazon-kinesis-firehose

Forward Kinesis data --> (different AWS account) Kinesis?


Is there a simple way to forward data from one account's kinesis stream to another account's kinesis?

data --> (AWS Account A) Kinesis ---> (AWS Account B) Kinesis --> consumer this part ---> ^^^^

I've seen some options with Lambda and sts:AssumeRole. Are there other options?


Solution

  • You are right, Lambda is one way to do it. In short, there is no way to push data from one Kinesis Stream to another directly. Even on the same account. You will need to build an app (Lambda can do the job), consuming from one Kinesis and then pushing to another Kinesis stream. It is also possible to create an application using the Kinesis Client Library (KCL) and a Kinesis Producer Library (KPL) and build what you want. In case, your environment needs cross-account interaction, it is possible to create an IAM Role with a cross-account policy definition. At the reference [1], there are information about IAM roles. References:

    1. https://docs.aws.amazon.com/streams/latest/dev/controlling-access.html
    2. https://github.com/awslabs/amazon-kinesis-client-python
    3. https://docs.aws.amazon.com/streams/latest/dev/kinesis-kpl-integration.html