You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/cosmos-db/change-feed-processor.md
+10-4Lines changed: 10 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ ms.author: tisande
6
6
ms.service: cosmos-db
7
7
ms.devlang: dotnet
8
8
ms.topic: conceptual
9
-
ms.date: 05/06/2020
9
+
ms.date: 05/13/2020
10
10
ms.reviewer: sngun
11
11
---
12
12
@@ -68,15 +68,21 @@ To prevent your change feed processor from getting "stuck" continuously retrying
68
68
69
69
In addition, you can use the [change feed estimator](how-to-use-change-feed-estimator.md) to monitor the progress of your change feed processor instances as they read the change feed. In addition to monitoring if the change feed processor gets "stuck" continuously retrying the same batch of changes, you can also understand if your change feed processor is lagging behind due to available resources like CPU, memory, and network bandwidth.
70
70
71
+
## Deployment unit
72
+
73
+
A single change feed processor deployment unit consists of one or more instances with the same `processorName` and lease container configuration. You can have many deployment units where each one has a different business flow for the changes and each deployment unit consisting of one or more instances.
74
+
75
+
For example, you might have one deployment unit that triggers an external API anytime there is a change in your container. Another deployment unit might move data, in real-time, each time there is a change. When a change happens in your monitored container, all your deployment units will get notified.
76
+
71
77
## Dynamic scaling
72
78
73
-
As mentioned during the introduction, the change feed processor can distribute compute across multiple instances automatically. You can deploy multiple instances of your application using the change feed processor and take advantage of it, the only key requirements are:
79
+
As mentioned before, within a deployment unit you can have one or more instances. To take advantage of the compute distribution within the deployment unit, the only key requirements are:
74
80
75
81
1. All instances should have the same lease container configuration.
76
-
1. All instances should have the same workflow name.
82
+
1. All instances should have the same `processorName`.
77
83
1. Each instance needs to have a different instance name (`WithInstanceName`).
78
84
79
-
If these three conditions apply, then the change feed processor will, using an equal distribution algorithm, distribute all the leases in the lease container across all running instances and parallelize compute. One lease can only be owned by one instance at a given time, so the maximum number of instances equals to the number of leases.
85
+
If these three conditions apply, then the change feed processor will, using an equal distribution algorithm, distribute all the leases in the lease container across all running instances of that deployment unit and parallelize compute. One lease can only be owned by one instance at a given time, so the maximum number of instances equals to the number of leases.
80
86
81
87
The number of instances can grow and shrink, and the change feed processor will dynamically adjust the load by redistributing accordingly.
0 commit comments