dynamodb-replicator icon indicating copy to clipboard operation
dynamodb-replicator copied to clipboard

Replicate to a table with a different key schema

Open willwhite opened this issue 9 years ago • 1 comments

A bit of an unusual use case but in trying to replicate to destination table with an different key schema than the source table, this line is problematic. We are assuming both tables have identical key schema.

We could workaround this by allowing the user to define the destination key schema explicitly or by looking up the key schema for the destination table.

willwhite avatar Sep 09 '15 14:09 willwhite

We could workaround this by allowing the user to define the destination key schema explicitly or by looking up the key schema for the destination table.

The tricky part is that these functions are designed to run on lambda instances, where every bit of configuration that doesn't come bundled in the event is a chore. We could run one describeTable request per function invocation to determine the key schema, otherwise we'd need that information to be passed in via environment variable somehow.

rclark avatar Sep 10 '15 16:09 rclark