Пример #1
0
        public PartitionProcessor(IChangeFeedObserver observer, IChangeFeedDocumentClient documentClient, ProcessorSettings settings, IPartitionCheckpointer checkpointer)
        {
            this.observer     = observer;
            this.settings     = settings;
            this.checkpointer = checkpointer;
            this.options      = new ChangeFeedOptions
            {
                MaxItemCount        = settings.MaxItemCount,
                PartitionKeyRangeId = settings.PartitionKeyRangeId,
                SessionToken        = settings.SessionToken,
                StartFromBeginning  = settings.StartFromBeginning,
                RequestContinuation = settings.RequestContinuation,
                StartTime           = settings.StartTime,
            };

            this.query = documentClient.CreateDocumentChangeFeedQuery(settings.CollectionSelfLink, this.options);
        }
 public IChangeFeedDocumentQuery <Document> CreateDocumentChangeFeedQuery(string collectionLink, ChangeFeedOptions feedOptions)
 {
     return(new QoSMeteringChangeFeedDocumentQuery(_inner.CreateDocumentChangeFeedQuery(collectionLink, feedOptions), feedOptions.PartitionKeyRangeId, _meter));
 }