How to parallel process different partition ranges with Cosmos change feed (push)?

Author: Frank Q.

Originally Sourced from:

Looking at below document it explains that within a deployment unit, different instances can process different partition range values.

"change feed processor is assigning different ranges to each instance"


However, there is no such API where you can specify the partition range when creating an instance.

ChangeFeedProcessor changeFeedProcessor = cosmosClient.GetContainer(databaseName, sourceContainerName)
        .GetChangeFeedProcessorBuilder<ToDoItem>(processorName: "changeFeedSample", onChangesDelegate: HandleChangesAsync)

Is this supported in Push model ? I do see in pull model there is a way.

I tried using emulator and creating items with different partition key values. Had 2 consumers (instances of same processor) running.

Expected: Different consumers get notified for different partition key values.

Actual: Only one consumer keeps receiving for all. This is not going to scale.