This library provides a host for distributing change feed events in partitioned collection across multiple observers. Instances of the host can scale up (by adding) or down (by removing) dynamically, and the load will be automatically distributed among active instances in about-equal way.
Other
51
stars
22
forks
source link
Propagate DocumentClientException from ProcessChangesAsync #127
Currently, if the ProcessChangesAsync in the Observer throws a DCE (because the user is using a DocumentClient for example) with RetryAfter specified, the PartitionProcessor will treat it as an exception happening on the FeedResponse and assume the continuation token was not updated, wait the assignated time, and do another Feed read.
The problem is that this behavior will inherently lose the batch of documents, since it will not close the Observer (as any other exception happening in ProcessChangesAsync would), and do another Feed Read with the next continuation token.
Currently, if the
ProcessChangesAsync
in the Observer throws a DCE (because the user is using a DocumentClient for example) withRetryAfter
specified, thePartitionProcessor
will treat it as an exception happening on theFeedResponse
and assume the continuation token was not updated, wait the assignated time, and do another Feed read.The problem is that this behavior will inherently lose the batch of documents, since it will not close the Observer (as any other exception happening in ProcessChangesAsync would), and do another Feed Read with the next continuation token.