Skip to content

Feature Request - customise kinesis detectShardsToConsume #179

@0x006EA1E5

Description

@0x006EA1E5

I would like to customise KinesisMessageDrivenChannelAdapter#detectShardsToConsume(java.lang.String)

Currently this method returns a list of shards which will be read from, which will be all shards which are not "complete" (complete shards are closed shards with a checkpoint for the endingSequenceNumber).

However, I would like to be able to do the following two things:

  1. Exclude shards with an incomplete parent - when a stream is resharded, shards are either split or merged, and have a parent/child relationship. Records in a parent shards will be sequentially before records in their child shards. I want to be able to ensure I have completed any parent shards before starting to read their children. This would reduce throughput, but maintain some element or ordering

  2. Only read a given set of shards - I have a special case where I would like to use the adaptor to only read certain shards

I would be able to do this if KinesisMessageDrivenChannelAdapter#detectShardsToConsume(java.lang.String) was protected, or could be customised with a Function<String, List<Shard>>

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions