mirror of https://github.com/dapr/docs.git
Merge pull request #997 from dapr/mchmarny-pubsub-programm-vs-declare
Clarifies declarative vs. programmatic pub/sub approach
This commit is contained in:
commit
ea46a1fd74
|
@ -66,8 +66,13 @@ spec:
|
|||
## Step 2: Subscribe to topics
|
||||
|
||||
Dapr allows two methods by which you can subscribe to topics:
|
||||
|
||||
- **Declaratively**, where subscriptions are are defined in an external file.
|
||||
- **Programatically**, where subscriptions are defined in user code
|
||||
- **Programmatically**, where subscriptions are defined in user code
|
||||
|
||||
{{% alert title="Note" color="primary" %}}
|
||||
Both declarative and programmatic approaches support the same features. The declarative approach removes the Dapr dependancy from the user code and allows for the use of an existing application to subscribe to topics. The programmatic approach implements the subscription in user code.
|
||||
{{% /alert %}}
|
||||
|
||||
### Declarative subscriptions
|
||||
|
||||
|
|
Loading…
Reference in New Issue