From 12bbac91d47c5753e34e9dd84bda9dabeae02e66 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Wed, 14 Dec 2022 11:48:56 +0530 Subject: [PATCH 01/25] WIP publish docs Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 11 ++++ .../building-blocks/pubsub/pubsub-overview.md | 4 ++ .../content/en/reference/api/pubsub_api.md | 66 +++++++++++++++++++ 3 files changed, 81 insertions(+) create mode 100644 daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md new file mode 100644 index 000000000..3375dfc8c --- /dev/null +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -0,0 +1,11 @@ +--- +type: docs +title: "Publishing & subscribing messages in bulk" +linkTitle: "Bulk messages" +weight: 2100 +description: "Learn how to send and receive multiple messages at once" +--- + +insert-introduction + +## Publishing messages in bulk \ No newline at end of file diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md index 2b90adda6..7dae7663d 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md @@ -119,6 +119,10 @@ By default, all topic messages associated with an instance of a pub/sub componen Dapr can set a timeout message on a per-message basis, meaning that if the message is not read from the pub/sub component, then the message is discarded. This timeout message prevents a build up of unread messages. If a message has been in the queue longer than the configured TTL, it is marked as dead. For more information, read [pub/sub message TTL]({{< ref pubsub-message-ttl.md >}}). +### Bulk messages + +Dapr supports sending and receiving multiple messages in a single request. This is useful for applications that need to send or receive a large number of messages at once. For more information, read [pub/sub bulk messages]({{< ref pubsub-bulk.md >}}). + ## Try out pub/sub ### Quickstarts and tutorials diff --git a/daprdocs/content/en/reference/api/pubsub_api.md b/daprdocs/content/en/reference/api/pubsub_api.md index f4d8e47fa..69d7c813b 100644 --- a/daprdocs/content/en/reference/api/pubsub_api.md +++ b/daprdocs/content/en/reference/api/pubsub_api.md @@ -64,6 +64,72 @@ Parameter | Description > Additional metadata parameters are available based on each pubsub component. +## Publish multiple messages to a given topic + +This endpoint lets you publish multiple messages to consumers who are listening on a `topic`. + +### HTTP Request + +``` +POST http://localhost:/v1.0-alpha1/publish/bulk//[?] +``` + +The request body should contain a JSON array of entries with unique entry IDs. Example: + +```json +[ + { + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "event": "first", + "contentType": "text/plain" + }, + { + "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", + "event": { + "message": "second" + }, + "contentType": "application/json" + }, +] +``` + +Just like the publish endpoint, the events are auto-wrapped as CloudEvents if `rawPayload` metadata is not set to true. The `contentType` field is optional and defaults to `text/plain`. + +### Headers + +The `Content-Type` header should be set to `application/json`. + +### Metadata + +Metadata can be sent via query parameters in the request's URL. If must be prefixed with `metadata.` as shown below. + +|**Parameter**|**Description**| +|--|--| +|`metadata.rawPayload`|Boolean to determine if Dapr should publish the messages without wrapping them as CloudEvent.| +|`metadata.maxBulkPubBytes`|Maximum bytes to publish in a bulk publish request.| + + +#### HTTP Response + +|**Code**|**Description**| +|--|--| +|204|All messages delivered| +|400|Pubsub does not exist| +|403|Forbidden by access controls| +|500|At least one message failed to be delivered| + +The response body is a JSON containing a list of failed messages. Example: + +```json +[ + { + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "error": "error message", + "status": "FAIL", + } +] +``` + ## Optional Application (User Code) Routes ### Provide a route for Dapr to discover topic subscriptions From e89864e2ad047a02e8ecdef65f55ce474d301b75 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Wed, 14 Dec 2022 11:53:48 +0530 Subject: [PATCH 02/25] Remove a statement Signed-off-by: Shubham Sharma --- daprdocs/content/en/reference/api/pubsub_api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/daprdocs/content/en/reference/api/pubsub_api.md b/daprdocs/content/en/reference/api/pubsub_api.md index 69d7c813b..7b253198b 100644 --- a/daprdocs/content/en/reference/api/pubsub_api.md +++ b/daprdocs/content/en/reference/api/pubsub_api.md @@ -93,7 +93,7 @@ The request body should contain a JSON array of entries with unique entry IDs. E ] ``` -Just like the publish endpoint, the events are auto-wrapped as CloudEvents if `rawPayload` metadata is not set to true. The `contentType` field is optional and defaults to `text/plain`. +Just like the publish endpoint, the events are auto-wrapped as CloudEvents if `rawPayload` metadata is not set to true. ### Headers From 58eb6d6003ccafb13a18c1601373eb79c28d0f77 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Wed, 4 Jan 2023 16:34:01 +0530 Subject: [PATCH 03/25] Update API reference' Signed-off-by: Shubham Sharma --- .../content/en/reference/api/pubsub_api.md | 65 +++++++++++-------- 1 file changed, 39 insertions(+), 26 deletions(-) diff --git a/daprdocs/content/en/reference/api/pubsub_api.md b/daprdocs/content/en/reference/api/pubsub_api.md index 7b253198b..a7ca07ae0 100644 --- a/daprdocs/content/en/reference/api/pubsub_api.md +++ b/daprdocs/content/en/reference/api/pubsub_api.md @@ -74,30 +74,41 @@ This endpoint lets you publish multiple messages to consumers who are listening POST http://localhost:/v1.0-alpha1/publish/bulk//[?] ``` -The request body should contain a JSON array of entries with unique entry IDs. Example: +The request body should contain a JSON array of entries with unique entry IDs, the event to publish, and the content type of the event. If the content type for an event is not `application/cloudevents+json`, it is auto-wrapped as a CloudEvent (unless `metadata.rawPayload` is set to `true`, see below). -```json -[ - { - "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", - "event": "first", - "contentType": "text/plain" - }, - { - "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", - "event": { - "message": "second" +Example: + +```bash +curl -X POST http://localhost:3500/v1.0-alpha1/publish/bulk/pubsubName/deathStarStatus \ + -H 'Content-Type: application/json' \ + -d '[ + { + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "event": "first", + "contentType": "text/plain" }, - "contentType": "application/json" - }, -] + { + "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", + "event": { + "message": "second" + }, + "contentType": "application/json" + }, + ]' ``` -Just like the publish endpoint, the events are auto-wrapped as CloudEvents if `rawPayload` metadata is not set to true. - ### Headers -The `Content-Type` header should be set to `application/json`. +The `Content-Type` header should always be set to `application/json`. + +### URL Parameters + +|**Parameter**|**Description**| +|--|--| +|`daprPort`|The Dapr port| +|`pubsubname`|The name of pubsub component| +|`topic`|The name of the topic| +|`metadata`|Query parameters for metadata as described below| ### Metadata @@ -111,23 +122,25 @@ Metadata can be sent via query parameters in the request's URL. If must be prefi #### HTTP Response -|**Code**|**Description**| +|**HTTP Status**|**Description**| |--|--| |204|All messages delivered| |400|Pubsub does not exist| |403|Forbidden by access controls| |500|At least one message failed to be delivered| -The response body is a JSON containing a list of failed messages. Example: +The response body is a JSON containing a list of failed entries. Example: ```json -[ +{ + "failedEntries": [ { - "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", - "error": "error message", - "status": "FAIL", - } -] + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "error": "error message" + }, + ], + "errorCode": "ERR_PUBSUB_PUBLISH_MESSAGE" +} ``` ## Optional Application (User Code) Routes From 6671a6e6bab6e61a00f1ef4e50087ab72241178f Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Thu, 5 Jan 2023 11:22:02 +0530 Subject: [PATCH 04/25] Add more docs Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 138 +++++++++++++++++- .../building-blocks/pubsub/pubsub-overview.md | 4 +- daprdocs/data/components/pubsub/azure.yaml | 6 + daprdocs/data/components/pubsub/generic.yaml | 3 + .../layouts/partials/components/pubsub.html | 4 + 5 files changed, 147 insertions(+), 8 deletions(-) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md index 3375dfc8c..eddf845f6 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -1,11 +1,137 @@ --- type: docs -title: "Publishing & subscribing messages in bulk" -linkTitle: "Bulk messages" -weight: 2100 -description: "Learn how to send and receive multiple messages at once" +title: "Send and receive messages in bulk" +linkTitle: "Send and receive messages in bulk" +weight: 7100 +description: "Learn how to use the bulk publish and subscribe APIs in Dapr." --- -insert-introduction +{{% alert title="alpha" color="warning" %}} +The bulk publish and subscribe APIs are in **alpha** stage. +{{% /alert %}} -## Publishing messages in bulk \ No newline at end of file +With the bulk publish and subscribe APIs, you can send and receive multiple messages in a single request. + +## Native bulk publish and subscribe support + +When a pub/sub component supports the bulk publish API natively, Dapr also publishes messages to the underlying pub/sub component in bulk. + +Otherwise, Dapr falls back to sending messages one by one to the underlying pub/sub component. This is still more efficient than using the regular publish API, because applications can still send multiple messages in a single request to Dapr. + +## Supported components + +Refer [component reference]({{< ref supported-pubsub >}}) to see which components support the bulk publish API natively. + +## Publishing messages in bulk + +### Example + +{{< tabs Javascript "HTTP API (Bash)" "HTTP API (PowerShell)" >}} + +{{% codetab %}} + +```typescript + +import { DaprClient } from "@dapr/dapr"; + +const pubSubName = "my-pubsub-name"; +const topic = "topic-a"; + +async function start() { + const client = new DaprClient(); + + // Publish multiple messages to a topic. + await client.pubsub.publishBulk(pubSubName, topic, ["message 1", "message 2", "message 3"]); + + // Publish multiple messages to a topic with explicit bulk publish messages. + const bulkPublishMessages = [ + { + entryID: "entry-1", + contentType: "application/json", + event: { hello: "foo message 1" }, + }, + { + entryID: "entry-2", + contentType: "application/cloudevents+json", + event: { + specversion: "1.0", + source: "/some/source", + type: "example", + id: "1234", + data: "foo message 2", + datacontenttype: "text/plain" + }, + }, + { + entryID: "entry-3", + contentType: "text/plain", + event: "foo message 3", + }, + ]; + await client.pubsub.publishBulk(pubSubName, topic, bulkPublishMessages); +} + +start().catch((e) => { + console.error(e); + process.exit(1); +}); +``` + +{{% /codetab %}} + +{{% codetab %}} + +```bash +curl -X POST http://localhost:3500/v1.0-alpha1/publish/bulk/my-pubsub-name/topic-a \ + -H 'Content-Type: application/json' \ + -d '[ + { + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "event": "first", + "contentType": "text/plain" + }, + { + "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", + "event": { + "message": "second" + }, + "contentType": "application/json" + }, + ]' +``` + +{{% /codetab %}} + +{{% codetab %}} + +```powershell +Invoke-RestMethod -Method Post -ContentType 'application/json' -Uri 'http://localhost:3500/v1.0-alpha1/publish/bulk/my-pubsub-name/topic-a' ` +-Body '[ + { + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "event": "first", + "contentType": "text/plain" + }, + { + "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", + "event": { + "message": "second" + }, + "contentType": "application/json" + }, + ]' +``` + +{{% /codetab %}} + +{{< /tabs >}} +``` + +{{% /codetab %}} + +{{< /tabs >}} + +## Related links + +- List of [supported pub/sub components]({{< ref supported-pubsub >}}) +- Read the [API reference]({{< ref pubsub_api.md >}}) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md index 7dae7663d..93bc84314 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md @@ -119,9 +119,9 @@ By default, all topic messages associated with an instance of a pub/sub componen Dapr can set a timeout message on a per-message basis, meaning that if the message is not read from the pub/sub component, then the message is discarded. This timeout message prevents a build up of unread messages. If a message has been in the queue longer than the configured TTL, it is marked as dead. For more information, read [pub/sub message TTL]({{< ref pubsub-message-ttl.md >}}). -### Bulk messages +### Send and receive messages in bulk -Dapr supports sending and receiving multiple messages in a single request. This is useful for applications that need to send or receive a large number of messages at once. For more information, read [pub/sub bulk messages]({{< ref pubsub-bulk.md >}}). +Dapr supports sending and receiving multiple messages in a single request. This is useful for applications that require a high throughput. For more information, read [pub/sub bulk messages]({{< ref pubsub-bulk.md >}}). ## Try out pub/sub diff --git a/daprdocs/data/components/pubsub/azure.yaml b/daprdocs/data/components/pubsub/azure.yaml index 3bb3c279a..e278829af 100644 --- a/daprdocs/data/components/pubsub/azure.yaml +++ b/daprdocs/data/components/pubsub/azure.yaml @@ -3,8 +3,14 @@ state: Stable version: v1 since: "1.8" + features: + bulkPublish: true + bulkSubscribe: false - component: Azure Service Bus link: setup-azure-servicebus state: Stable version: v1 since: "1.0" + features: + bulkPublish: true + bulkSubscribe: true diff --git a/daprdocs/data/components/pubsub/generic.yaml b/daprdocs/data/components/pubsub/generic.yaml index ef757e4b3..ab1bf5d01 100644 --- a/daprdocs/data/components/pubsub/generic.yaml +++ b/daprdocs/data/components/pubsub/generic.yaml @@ -13,6 +13,9 @@ state: Stable version: v1 since: "1.5" + features: + bulkPublish: true + bulkSubscribe: true - component: Redis Streams link: setup-redis-pubsub state: Stable diff --git a/daprdocs/layouts/partials/components/pubsub.html b/daprdocs/layouts/partials/components/pubsub.html index 244a6f623..b2ee91a1f 100644 --- a/daprdocs/layouts/partials/components/pubsub.html +++ b/daprdocs/layouts/partials/components/pubsub.html @@ -10,6 +10,8 @@ + + @@ -19,6 +21,8 @@ + + From 13d06288f438f7ba93d070d59cba25517a6c1f43 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Thu, 5 Jan 2023 11:23:09 +0530 Subject: [PATCH 05/25] Fix tag Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 5 ----- 1 file changed, 5 deletions(-) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md index eddf845f6..f49ed8a27 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -124,11 +124,6 @@ Invoke-RestMethod -Method Post -ContentType 'application/json' -Uri 'http://loca {{% /codetab %}} -{{< /tabs >}} -``` - -{{% /codetab %}} - {{< /tabs >}} ## Related links From 48b7ebce27453d51ceadd8d98a67c44c8c4d73b2 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Mon, 9 Jan 2023 16:44:39 +0530 Subject: [PATCH 06/25] Add Java example Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 31 ++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md index f49ed8a27..86788fe33 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -26,7 +26,36 @@ Refer [component reference]({{< ref supported-pubsub >}}) to see which component ### Example -{{< tabs Javascript "HTTP API (Bash)" "HTTP API (PowerShell)" >}} +{{< tabs Java Javascript "HTTP API (Bash)" "HTTP API (PowerShell)" >}} + +{{% codetab %}} + +```java +import io.dapr.client.DaprClientBuilder; +import io.dapr.client.DaprPreviewClient; +import io.dapr.client.domain.BulkPublishResponse; +import io.dapr.client.domain.BulkPublishResponseFailedEntry; +import java.util.ArrayList; +import java.util.List; + +class BulkPublisher { + public void publishMessages() { + try (DaprPreviewClient client = (new DaprClientBuilder()).buildPreviewClient()) { + // Create a list of messages to publish + List messages = new ArrayList<>(); + for (int i = 0; i < 10; i++) { + String message = String.format("This is message #%d", i); + messages.add(message); + } + + // Publish list of messages using the bulk publish API + BulkPublishResponse res = client.publishEvents(PUBSUB_NAME, TOPIC_NAME, "text/plain", messages).block(); + } + } +} +``` + +{{% /codetab %}} {{% codetab %}} From b53f417dbdd1f99a0dca01a51cf8ce27dfe0838b Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Wed, 18 Jan 2023 11:19:18 +0530 Subject: [PATCH 07/25] Apply suggestions from code review Co-authored-by: Hannah Hunter <94493363+hhunter-ms@users.noreply.github.com> Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 2 +- daprdocs/content/en/reference/api/pubsub_api.md | 15 ++++++++++----- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md index 86788fe33..fd281015d 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -20,7 +20,7 @@ Otherwise, Dapr falls back to sending messages one by one to the underlying pub/ ## Supported components -Refer [component reference]({{< ref supported-pubsub >}}) to see which components support the bulk publish API natively. +Refer to the [component reference]({{< ref supported-pubsub >}}) to see which components support the bulk publish API natively. ## Publishing messages in bulk diff --git a/daprdocs/content/en/reference/api/pubsub_api.md b/daprdocs/content/en/reference/api/pubsub_api.md index a7ca07ae0..3bdbe09aa 100644 --- a/daprdocs/content/en/reference/api/pubsub_api.md +++ b/daprdocs/content/en/reference/api/pubsub_api.md @@ -74,7 +74,12 @@ This endpoint lets you publish multiple messages to consumers who are listening POST http://localhost:/v1.0-alpha1/publish/bulk//[?] ``` -The request body should contain a JSON array of entries with unique entry IDs, the event to publish, and the content type of the event. If the content type for an event is not `application/cloudevents+json`, it is auto-wrapped as a CloudEvent (unless `metadata.rawPayload` is set to `true`, see below). +The request body should contain a JSON array of entries with: +- Unique entry IDs +- The event to publish +- The content type of the event + +If the content type for an event is not `application/cloudevents+json`, it is auto-wrapped as a CloudEvent (unless `metadata.rawPayload` is set to `true`). Example: @@ -106,13 +111,13 @@ The `Content-Type` header should always be set to `application/json`. |**Parameter**|**Description**| |--|--| |`daprPort`|The Dapr port| -|`pubsubname`|The name of pubsub component| +|`pubsubname`|The name of pub/sub component| |`topic`|The name of the topic| -|`metadata`|Query parameters for metadata as described below| +|`metadata`|Query parameters for [metadata]({{< ref "pubsub_api.md#metadata" >}})| ### Metadata -Metadata can be sent via query parameters in the request's URL. If must be prefixed with `metadata.` as shown below. +Metadata can be sent via query parameters in the request's URL. It must be prefixed with `metadata.`, as shown in the table below. |**Parameter**|**Description**| |--|--| @@ -125,7 +130,7 @@ Metadata can be sent via query parameters in the request's URL. If must be prefi |**HTTP Status**|**Description**| |--|--| |204|All messages delivered| -|400|Pubsub does not exist| +|400|Pub/sub does not exist| |403|Forbidden by access controls| |500|At least one message failed to be delivered| From 51e8797170e6e99e2b532109f92dd3f6a78a3481 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Wed, 18 Jan 2023 12:16:25 +0530 Subject: [PATCH 08/25] Note about ordering Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md index fd281015d..e7ebc89ef 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -24,6 +24,8 @@ Refer to the [component reference]({{< ref supported-pubsub >}}) to see which co ## Publishing messages in bulk +The bulk publish API allows you to publish multiple messages to a topic in a single request. If any of the messages fail to publish, the bulk publish operation returns a list of failed messages. Note, the bulk publish operation does not guarantee the order of messages. + ### Example {{< tabs Java Javascript "HTTP API (Bash)" "HTTP API (PowerShell)" >}} From 1f805e5b9978193ad91cde615fc466faadfdc59a Mon Sep 17 00:00:00 2001 From: Hannah Hunter Date: Tue, 24 Jan 2023 16:04:21 -0600 Subject: [PATCH 09/25] update resiliency docs Signed-off-by: Hannah Hunter --- daprdocs/content/en/concepts/resiliency-concept.md | 5 +++++ .../resiliency/resiliency-serviceinvo-quickstart.md | 4 ---- .../resiliency/resiliency-state-quickstart.md | 4 ---- daprdocs/content/en/operations/resiliency/policies.md | 10 +++++++--- .../en/operations/resiliency/resiliency-overview.md | 9 +++++---- daprdocs/content/en/operations/resiliency/targets.md | 7 ++++++- .../en/operations/support/support-preview-features.md | 1 - 7 files changed, 23 insertions(+), 17 deletions(-) diff --git a/daprdocs/content/en/concepts/resiliency-concept.md b/daprdocs/content/en/concepts/resiliency-concept.md index 7b8cbe675..b1b662bc5 100644 --- a/daprdocs/content/en/concepts/resiliency-concept.md +++ b/daprdocs/content/en/concepts/resiliency-concept.md @@ -37,3 +37,8 @@ Dapr provides a way to determine its health using an [HTTP `/healthz` endpoint]( - Determined for readiness and liveness Read more on about how to apply [dapr health checks]({{< ref sidecar-health >}}) to your application. + +## Next steps + +- [Learn more about resiliency]({{< ref resiliency-overview.md >}}) +- [Try out one of the Resiliency quickstarts]({{< ref quickstarts/resiliency >}}) \ No newline at end of file diff --git a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md index f338bde8a..24eac44ac 100644 --- a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md +++ b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md @@ -6,10 +6,6 @@ weight: 120 description: "Get started with Dapr's resiliency capabilities via the service invocation API" --- -{{% alert title="Note" color="primary" %}} - Resiliency is currently a preview feature. -{{% /alert %}} - Observe Dapr resiliency capabilities by simulating a system failure. In this Quickstart, you will: - Run two microservice applications: `checkout` and `order-processor`. `checkout` will continuously make Dapr service invocation requests to `order-processor`. diff --git a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md index ef34f4a69..13756b748 100644 --- a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md +++ b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md @@ -6,10 +6,6 @@ weight: 110 description: "Get started with Dapr's resiliency capabilities via the state management API" --- -{{% alert title="Note" color="primary" %}} - Resiliency is currently a preview feature. -{{% /alert %}} - Observe Dapr resiliency capabilities by simulating a system failure. In this Quickstart, you will: - Execute a microservice application with resiliency enabled that continuously persists and retrieves state via Dapr's state management API. diff --git a/daprdocs/content/en/operations/resiliency/policies.md b/daprdocs/content/en/operations/resiliency/policies.md index eb7e13895..5dba5eb06 100644 --- a/daprdocs/content/en/operations/resiliency/policies.md +++ b/daprdocs/content/en/operations/resiliency/policies.md @@ -3,10 +3,10 @@ type: docs title: "Policies" linkTitle: "Policies" weight: 4500 -description: "Configure resiliency policies for timeouts, retries and circuit breakers" +description: "Configure resiliency policies for timeouts, retries, and circuit breakers" --- -You define timeouts, retries and circuit breaker policies under `policies`. Each policy is given a name so you can refer to them from the `targets` section in the resiliency spec. +Define timeouts, retries, and circuit breaker policies under `policies`. Each policy is given a name so you can refer to them from the `targets` section in the resiliency spec. > Note: Dapr offers default retries for specific APIs. [See here]({{< ref "#override-default-retries" >}}) to learn how you can overwrite default retry logic with user defined retry policies. @@ -285,4 +285,8 @@ The table below is a break down of which policies are applied when attempting to | statestore | DefaultStatestoreComponentOutboundRetryPolicy | | actorstore | fastRetries | | EventActor | retryForever | -| SummaryActor | DefaultActorRetryPolicy | \ No newline at end of file +| SummaryActor | DefaultActorRetryPolicy | + +## Next steps + +- [Try out one of the Resiliency quickstarts]({{< ref resiliency >}}) \ No newline at end of file diff --git a/daprdocs/content/en/operations/resiliency/resiliency-overview.md b/daprdocs/content/en/operations/resiliency/resiliency-overview.md index fea52eca2..db9b02875 100644 --- a/daprdocs/content/en/operations/resiliency/resiliency-overview.md +++ b/daprdocs/content/en/operations/resiliency/resiliency-overview.md @@ -5,11 +5,8 @@ linkTitle: "Overview" weight: 4500 description: "Configure Dapr retries, timeouts, and circuit breakers" --- -{{% alert title="Note" color="primary" %}} - Resiliency is currently a preview feature. Before you can utilize a resiliency spec, you must first [enable the resiliency preview feature]({{< ref support-preview-features >}}). -{{% /alert %}} -Dapr provides a capability for defining and applying fault tolerance resiliency policies via a [resiliency spec]({{< ref "resiliency-overview.md#complete-example-policy" >}}). Resiliency specs are saved in the same location as components specs and are applied when the Dapr sidecar starts. The sidecar determines how to apply resiliency policies to your Dapr API calls. In self-hosted mode, the resiliency spec must be named `resiliency.yaml`. In Kubernetes Dapr finds the named resiliency specs used by your application. Within the resiliency spec, you can define policies for popular resiliency patterns, such as: +Dapr provides a capability for defining and applying fault tolerance resiliency policies via a [resiliency spec]({{< ref "resiliency-overview.md#complete-example-policy" >}}). Resiliency specs are saved in the same location as components specs and are applied when the Dapr sidecar starts. The sidecar determines how to apply resiliency policies to your Dapr API calls. In self-hosted mode, the resiliency spec must be named `resiliency.yaml`. In Kubernetes Dapr finds the named resiliency specs used by your application. Within the resiliency spec, you can define policies for popular resiliency patterns, such as: - [Timeouts]({{< ref "policies.md#timeouts" >}}) - [Retries/back-offs]({{< ref "policies.md#retries" >}}) @@ -171,3 +168,7 @@ Watch this video for how to use [resiliency](https://www.youtube.com/watch?t=184 - [Policies]({{< ref "policies.md" >}}) - [Targets]({{< ref "targets.md" >}}) + +## Next steps + +- [Try out one of the Resiliency quickstarts]({{< ref resiliency >}}) \ No newline at end of file diff --git a/daprdocs/content/en/operations/resiliency/targets.md b/daprdocs/content/en/operations/resiliency/targets.md index 6935f7d39..486785df9 100644 --- a/daprdocs/content/en/operations/resiliency/targets.md +++ b/daprdocs/content/en/operations/resiliency/targets.md @@ -7,6 +7,7 @@ description: "Apply resiliency policies to apps, components and actors" --- ### Targets + Named policies are applied to targets. Dapr supports three target types that apply all Dapr building block APIs: - `apps` - `components` @@ -129,4 +130,8 @@ spec: circuitBreaker: general circuitBreakerScope: both circuitBreakerCacheSize: 5000 -``` \ No newline at end of file +``` + +## Next steps + +- [Try out one of the Resiliency quickstarts]({{< ref resiliency >}}) \ No newline at end of file diff --git a/daprdocs/content/en/operations/support/support-preview-features.md b/daprdocs/content/en/operations/support/support-preview-features.md index 224d2e065..31bbf68d0 100644 --- a/daprdocs/content/en/operations/support/support-preview-features.md +++ b/daprdocs/content/en/operations/support/support-preview-features.md @@ -16,7 +16,6 @@ For CLI there is no explicit opt-in, just the version that this was first made a | Feature | Description | Setting | Documentation | Version introduced | | ---------- |-------------|---------|---------------|-----------------| | **`--image-registry`** flag in Dapr CLI| In self hosted mode you can set this flag to specify any private registry to pull the container images required to install Dapr| N/A | [CLI init command reference]({{}}) | v1.7 | -| **Resiliency** | Allows configuring of fine-grained policies for retries, timeouts and circuitbreaking. | `Resiliency` | [Configure Resiliency Policies]({{}}) | v1.7| | **App Middleware** | Allow middleware components to be executed when making service-to-service calls | N/A | [App Middleware]({{}}) | v1.9 | | **App health checks** | Allows configuring app health checks | `AppHealthCheck` | [App health checks]({{}}) | v1.9 | | **Pluggable components** | Allows creating self-hosted gRPC-based components written in any language that supports gRPC. The following component APIs are supported: State stores, Pub/sub, Bindings | N/A | [Pluggable components concept]({{}})| v1.9 | From aa685e68b79abda488a2645ff054283ce2140288 Mon Sep 17 00:00:00 2001 From: Hannah Hunter Date: Tue, 24 Jan 2023 16:09:09 -0600 Subject: [PATCH 10/25] fix build Signed-off-by: Hannah Hunter --- daprdocs/content/en/concepts/resiliency-concept.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/daprdocs/content/en/concepts/resiliency-concept.md b/daprdocs/content/en/concepts/resiliency-concept.md index b1b662bc5..f66dbdca5 100644 --- a/daprdocs/content/en/concepts/resiliency-concept.md +++ b/daprdocs/content/en/concepts/resiliency-concept.md @@ -41,4 +41,4 @@ Read more on about how to apply [dapr health checks]({{< ref sidecar-health >}}) ## Next steps - [Learn more about resiliency]({{< ref resiliency-overview.md >}}) -- [Try out one of the Resiliency quickstarts]({{< ref quickstarts/resiliency >}}) \ No newline at end of file +- [Try out one of the Resiliency quickstarts]({{< ref "quickstarts/resiliency" >}}) \ No newline at end of file From 851c3d5971c7d202d9e1214279cf44dce9c39188 Mon Sep 17 00:00:00 2001 From: Hannah Hunter Date: Wed, 25 Jan 2023 11:11:01 -0600 Subject: [PATCH 11/25] fix build Signed-off-by: Hannah Hunter --- daprdocs/content/en/concepts/resiliency-concept.md | 4 +++- daprdocs/content/en/operations/resiliency/policies.md | 4 +++- .../content/en/operations/resiliency/resiliency-overview.md | 4 +++- daprdocs/content/en/operations/resiliency/targets.md | 4 +++- 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/daprdocs/content/en/concepts/resiliency-concept.md b/daprdocs/content/en/concepts/resiliency-concept.md index f66dbdca5..32656434d 100644 --- a/daprdocs/content/en/concepts/resiliency-concept.md +++ b/daprdocs/content/en/concepts/resiliency-concept.md @@ -41,4 +41,6 @@ Read more on about how to apply [dapr health checks]({{< ref sidecar-health >}}) ## Next steps - [Learn more about resiliency]({{< ref resiliency-overview.md >}}) -- [Try out one of the Resiliency quickstarts]({{< ref "quickstarts/resiliency" >}}) \ No newline at end of file +- Try out one of the Resiliency quickstarts: + - [Resiliency: Service-to-service]({{< ref resiliency-serviceinvo-quickstart.md >}}) + - [Resiliency: State Management]({{< ref resiliency-state-quickstart.md >}}) \ No newline at end of file diff --git a/daprdocs/content/en/operations/resiliency/policies.md b/daprdocs/content/en/operations/resiliency/policies.md index 5dba5eb06..935e80492 100644 --- a/daprdocs/content/en/operations/resiliency/policies.md +++ b/daprdocs/content/en/operations/resiliency/policies.md @@ -289,4 +289,6 @@ The table below is a break down of which policies are applied when attempting to ## Next steps -- [Try out one of the Resiliency quickstarts]({{< ref resiliency >}}) \ No newline at end of file +Try out one of the Resiliency quickstarts: +- [Resiliency: Service-to-service]({{< ref resiliency-serviceinvo-quickstart.md >}}) +- [Resiliency: State Management]({{< ref resiliency-state-quickstart.md >}}) \ No newline at end of file diff --git a/daprdocs/content/en/operations/resiliency/resiliency-overview.md b/daprdocs/content/en/operations/resiliency/resiliency-overview.md index db9b02875..ba63fe137 100644 --- a/daprdocs/content/en/operations/resiliency/resiliency-overview.md +++ b/daprdocs/content/en/operations/resiliency/resiliency-overview.md @@ -171,4 +171,6 @@ Watch this video for how to use [resiliency](https://www.youtube.com/watch?t=184 ## Next steps -- [Try out one of the Resiliency quickstarts]({{< ref resiliency >}}) \ No newline at end of file +Try out one of the Resiliency quickstarts: +- [Resiliency: Service-to-service]({{< ref resiliency-serviceinvo-quickstart.md >}}) +- [Resiliency: State Management]({{< ref resiliency-state-quickstart.md >}}) \ No newline at end of file diff --git a/daprdocs/content/en/operations/resiliency/targets.md b/daprdocs/content/en/operations/resiliency/targets.md index 486785df9..49dee7880 100644 --- a/daprdocs/content/en/operations/resiliency/targets.md +++ b/daprdocs/content/en/operations/resiliency/targets.md @@ -134,4 +134,6 @@ spec: ## Next steps -- [Try out one of the Resiliency quickstarts]({{< ref resiliency >}}) \ No newline at end of file +Try out one of the Resiliency quickstarts: +- [Resiliency: Service-to-service]({{< ref resiliency-serviceinvo-quickstart.md >}}) +- [Resiliency: State Management]({{< ref resiliency-state-quickstart.md >}}) \ No newline at end of file From 848bd86d7ccb12743cc3712740ed2bca334456b3 Mon Sep 17 00:00:00 2001 From: Hannah Hunter Date: Wed, 25 Jan 2023 11:29:41 -0600 Subject: [PATCH 12/25] update link Signed-off-by: Hannah Hunter --- .../components-reference/supported-pubsub/setup-apache-kafka.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-apache-kafka.md b/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-apache-kafka.md index 86d4a350c..a18b8c261 100644 --- a/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-apache-kafka.md +++ b/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-apache-kafka.md @@ -337,7 +337,7 @@ To run without Docker, see the getting started guide [here](https://kafka.apache {{% /codetab %}} {{% codetab %}} -To run Kafka on Kubernetes, you can use any Kafka operator, such as [Strimzi](https://strimzi.io/docs/operators/latest/quickstart.html#ref-install-prerequisites-str). +To run Kafka on Kubernetes, you can use any Kafka operator, such as [Strimzi](https://strimzi.io/quickstarts/). {{% /codetab %}} {{< /tabs >}} From 87b4fa4bc5ec3d473ffb607d42b0758e6cc3b124 Mon Sep 17 00:00:00 2001 From: Hannah Hunter Date: Wed, 25 Jan 2023 14:21:06 -0600 Subject: [PATCH 13/25] update dapr run commands Signed-off-by: Hannah Hunter --- .../resiliency-serviceinvo-quickstart.md | 59 ++++++++++--------- .../resiliency/resiliency-state-quickstart.md | 44 +++++++------- .../pluggable-components-registration.md | 2 +- 3 files changed, 55 insertions(+), 50 deletions(-) diff --git a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md index 24eac44ac..a1c7722a2 100644 --- a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md +++ b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-serviceinvo-quickstart.md @@ -55,10 +55,10 @@ pip3 install -r requirements.txt Run the `order-processor` service alongside a Dapr sidecar. ```bash -dapr run --app-port 8001 --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3501 -- python3 app.py +dapr run --app-port 8001 --app-id order-processor --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3501 -- python3 app.py ``` -### Step 3: Run the `checkout` service application with resiliency enabled +### Step 3: Run the `checkout` service application In a new terminal window, from the root of the Quickstart directory, navigate to the `checkout` directory. @@ -72,13 +72,13 @@ Install dependencies: pip3 install -r requirements.txt ``` -Run the `checkout` service alongside a Dapr sidecar. The `--config` parameter applies a Dapr configuration that enables the resiliency feature. +Run the `checkout` service alongside a Dapr sidecar. ```bash -dapr run --app-id checkout --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3500 -- python3 app.py +dapr run --app-id checkout --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3500 -- python3 app.py ``` -By enabling resiliency, the resiliency spec located in the components directory is detected and loaded by the Dapr sidecar: +The Dapr sidecar then loads the resiliency spec located in the resources directory: ```yaml apiVersion: dapr.io/v1alpha1 @@ -283,10 +283,10 @@ npm install Run the `order-processor` service alongside a Dapr sidecar. ```bash -dapr run --app-port 5001 --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3501 -- npm start +dapr run --app-port 5001 --app-id order-processor --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3501 -- npm start ``` -### Step 3: Run the `checkout` service application with resiliency enabled +### Step 3: Run the `checkout` service application In a new terminal window, from the root of the Quickstart directory, navigate to the `checkout` directory. @@ -301,13 +301,14 @@ Install dependencies: npm install ``` -Run the `checkout` service alongside a Dapr sidecar. The `--config` parameter applies a Dapr configuration that enables the resiliency feature. +Run the `checkout` service alongside a Dapr sidecar. ```bash -dapr run --app-id checkout --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3500 -- npm start +dapr run --app-id checkout --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3500 -- npm start ``` -By enabling resiliency, the resiliency spec located in the components directory is detected and loaded by the Dapr sidecar: +The Dapr sidecar then loads the resiliency spec located in the resources directory: + ```yaml apiVersion: dapr.io/v1alpha1 @@ -446,7 +447,7 @@ Once you restart the `order-processor` service, the application will recover sea In the `order-processor` service terminal, restart the application: ```bash -dapr run --app-port 5001 --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3501 -- npm start +dapr run --app-port 5001 --app-id order-processor --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3501 -- npm start ``` `checkout` service output: @@ -514,10 +515,10 @@ dotnet build Run the `order-processor` service alongside a Dapr sidecar. ```bash -dapr run --app-port 7001 --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3501 -- dotnet run +dapr run --app-port 7001 --app-id order-processor --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3501 -- dotnet run ``` -### Step 3: Run the `checkout` service application with resiliency enabled +### Step 3: Run the `checkout` service application In a new terminal window, from the root of the Quickstart directory, navigate to the `checkout` directory. @@ -533,13 +534,13 @@ dotnet restore dotnet build ``` -Run the `checkout` service alongside a Dapr sidecar. The `--config` parameter applies a Dapr configuration that enables the resiliency feature. +Run the `checkout` service alongside a Dapr sidecar. ```bash -dapr run --app-id checkout --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3500 -- dotnet run +dapr run --app-id checkout --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3500 -- dotnet run ``` -By enabling resiliency, the resiliency spec located in the components directory is detected and loaded by the Dapr sidecar: +The Dapr sidecar then loads the resiliency spec located in the resources directory: ```yaml apiVersion: dapr.io/v1alpha1 @@ -747,10 +748,10 @@ mvn clean install Run the `order-processor` service alongside a Dapr sidecar. ```bash -dapr run --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-port 9001 --app-protocol http --dapr-http-port 3501 -- java -jar target/OrderProcessingService-0.0.1-SNAPSHOT.jar +dapr run --app-id order-processor --resources-path ../../../resources/ --app-port 9001 --app-protocol http --dapr-http-port 3501 -- java -jar target/OrderProcessingService-0.0.1-SNAPSHOT.jar ``` -### Step 3: Run the `checkout` service application with resiliency enabled +### Step 3: Run the `checkout` service application In a new terminal window, from the root of the Quickstart directory, navigate to the `checkout` directory. @@ -765,13 +766,14 @@ Install dependencies: mvn clean install ``` -Run the `checkout` service alongside a Dapr sidecar. The `--config` parameter applies a Dapr configuration that enables the resiliency feature. +Run the `checkout` service alongside a Dapr sidecar. ```bash -dapr run --app-id checkout --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3500 -- java -jar target/CheckoutService-0.0.1-SNAPSHOT.jar +dapr run --app-id checkout --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3500 -- java -jar target/CheckoutService-0.0.1-SNAPSHOT.jar ``` -By enabling resiliency, the resiliency spec located in the components directory is detected and loaded by the Dapr sidecar: +The Dapr sidecar then loads the resiliency spec located in the resources directory: + ```yaml apiVersion: dapr.io/v1alpha1 @@ -910,7 +912,7 @@ Once you restart the `order-processor` service, the application will recover sea In the `order-processor` service terminal, restart the application: ```bash -dapr run --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-port 9001 --app-protocol http --dapr-http-port 3501 -- java -jar target/OrderProcessingService-0.0.1-SNAPSHOT.jar +dapr run --app-id order-processor --resources-path ../../../resources/ --app-port 9001 --app-protocol http --dapr-http-port 3501 -- java -jar target/OrderProcessingService-0.0.1-SNAPSHOT.jar ``` `checkout` service output: @@ -976,10 +978,10 @@ go build . Run the `order-processor` service alongside a Dapr sidecar. ```bash -dapr run --app-port 6001 --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3501 -- go run . +dapr run --app-port 6001 --app-id order-processor --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3501 -- go run . ``` -### Step 3: Run the `checkout` service application with resiliency enabled +### Step 3: Run the `checkout` service application In a new terminal window, from the root of the Quickstart directory, navigate to the `checkout` directory. @@ -994,13 +996,14 @@ Install dependencies: go build . ``` -Run the `checkout` service alongside a Dapr sidecar. The `--config` parameter applies a Dapr configuration that enables the resiliency feature. +Run the `checkout` service alongside a Dapr sidecar. ```bash -dapr run --app-id checkout --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3500 -- go run . +dapr run --app-id checkout --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3500 -- go run . ``` -By enabling resiliency, the resiliency spec located in the components directory is detected and loaded by the Dapr sidecar: +The Dapr sidecar then loads the resiliency spec located in the resources directory: + ```yaml apiVersion: dapr.io/v1alpha1 @@ -1139,7 +1142,7 @@ Once you restart the `order-processor` service, the application will recover sea In the `order-processor` service terminal, restart the application: ```bash -dapr run --app-port 6001 --app-id order-processor --config ../config.yaml --components-path ../../../components/ --app-protocol http --dapr-http-port 3501 -- go run . +dapr run --app-port 6001 --app-id order-processor --resources-path ../../../resources/ --app-protocol http --dapr-http-port 3501 -- go run . ``` `checkout` service output: diff --git a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md index 13756b748..b572cb8b1 100644 --- a/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md +++ b/daprdocs/content/en/getting-started/quickstarts/resiliency/resiliency-state-quickstart.md @@ -8,7 +8,7 @@ description: "Get started with Dapr's resiliency capabilities via the state mana Observe Dapr resiliency capabilities by simulating a system failure. In this Quickstart, you will: -- Execute a microservice application with resiliency enabled that continuously persists and retrieves state via Dapr's state management API. +- Execute a microservice application that continuously persists and retrieves state via Dapr's state management API. - Trigger resiliency policies by simulating a system failure. - Resolve the failure and the microservice application will resume. @@ -50,9 +50,10 @@ Install dependencies pip3 install -r requirements.txt ``` -### Step 2: Run the application with resiliency enabled +### Step 2: Run the application + +Run the `order-processor` service alongside a Dapr sidecar. The Dapr sidecar then loads the resiliency spec located in the resources directory: -Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` command below, the `--config` parameter applies a Dapr configuration that enables the resiliency feature. By enabling resiliency, the resiliency spec located in the components directory is loaded by the `order-processor` sidecar. The resilency spec is: ```yaml apiVersion: dapr.io/v1alpha1 @@ -85,7 +86,7 @@ Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` co ```bash -dapr run --app-id order-processor --config ../config.yaml --components-path ../../../components/ -- python3 +dapr run --app-id order-processor --resources-path ../../../resources/ -- python3 ``` Once the application has started, the `order-processor`service writes and reads `orderId` key/value pairs to the `statestore` Redis instance [defined in the `statestore.yaml` component]({{< ref "statemanagement-quickstart.md#statestoreyaml-component-file" >}}). @@ -128,7 +129,7 @@ Once Redis is stopped, the requests begin to fail and the retry policy titled `r INFO[0006] Error processing operation component[statestore] output. Retrying... ``` -As per the `retryFroever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. +As per the `retryForever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. ```yaml retryForever: @@ -219,9 +220,10 @@ Install dependencies npm install ``` -### Step 2: Run the application with resiliency enabled +### Step 2: Run the application + +Run the `order-processor` service alongside a Dapr sidecar. The Dapr sidecar then loads the resiliency spec located in the resources directory: -Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` command below, the `--config` parameter applies a Dapr configuration that enables the resiliency feature. By enabling resiliency, the resiliency spec located in the components directory is loaded by the `order-processor` sidecar. The resilency spec is: ```yaml apiVersion: dapr.io/v1alpha1 @@ -253,7 +255,7 @@ Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` co ``` ```bash -dapr run --app-id order-processor --config ../config.yaml --components-path ../../../components/ -- npm start +dapr run --app-id order-processor --resources-path ../../../resources/ -- npm start ``` Once the application has started, the `order-processor`service writes and reads `orderId` key/value pairs to the `statestore` Redis instance [defined in the `statestore.yaml` component]({{< ref "statemanagement-quickstart.md#statestoreyaml-component-file" >}}). @@ -296,7 +298,7 @@ Once Redis is stopped, the requests begin to fail and the retry policy titled `r INFO[0006] Error processing operation component[statestore] output. Retrying... ``` -As per the `retryFroever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. +As per the `retryForever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. ```yaml retryForever: @@ -388,9 +390,9 @@ dotnet restore dotnet build ``` -### Step 2: Run the application with resiliency enabled +### Step 2: Run the application -Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` command below, the `--config` parameter applies a Dapr configuration that enables the resiliency feature. By enabling resiliency, the resiliency spec located in the components directory is loaded by the `order-processor` sidecar. The resilency spec is: +Run the `order-processor` service alongside a Dapr sidecar. The Dapr sidecar then loads the resiliency spec located in the resources directory: ```yaml apiVersion: dapr.io/v1alpha1 @@ -422,7 +424,7 @@ Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` co ``` ```bash -dapr run --app-id order-processor --config ../config.yaml --components-path ../../../components/ -- dotnet run +dapr run --app-id order-processor --resources-path ../../../resources/ -- dotnet run ``` Once the application has started, the `order-processor`service writes and reads `orderId` key/value pairs to the `statestore` Redis instance [defined in the `statestore.yaml` component]({{< ref "statemanagement-quickstart.md#statestoreyaml-component-file" >}}). @@ -465,7 +467,7 @@ Once Redis is stopped, the requests begin to fail and the retry policy titled `r INFO[0006] Error processing operation component[statestore] output. Retrying... ``` -As per the `retryFroever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. +As per the `retryForever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. ```yaml retryForever: @@ -559,9 +561,9 @@ Install dependencies mvn clean install ``` -### Step 2: Run the application with resiliency enabled +### Step 2: Run the application -Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` command below, the `--config` parameter applies a Dapr configuration that enables the resiliency feature. By enabling resiliency, the resiliency spec located in the components directory is loaded by the `order-processor` sidecar. The resilency spec is: +Run the `order-processor` service alongside a Dapr sidecar. The Dapr sidecar then loads the resiliency spec located in the resources directory: ```yaml apiVersion: dapr.io/v1alpha1 @@ -593,7 +595,7 @@ Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` co ``` ```bash -dapr run --app-id order-processor --config ../config.yaml --components-path ../../../components/ -- java -jar target/OrderProcessingService-0.0.1-SNAPSHOT.jar +dapr run --app-id order-processor --resources-path ../../../resources/ -- java -jar target/OrderProcessingService-0.0.1-SNAPSHOT.jar ``` Once the application has started, the `order-processor`service writes and reads `orderId` key/value pairs to the `statestore` Redis instance [defined in the `statestore.yaml` component]({{< ref "statemanagement-quickstart.md#statestoreyaml-component-file" >}}). @@ -636,7 +638,7 @@ Once Redis is stopped, the requests begin to fail and the retry policy titled `r INFO[0006] Error processing operation component[statestore] output. Retrying... ``` -As per the `retryFroever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. +As per the `retryForever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. ```yaml retryForever: @@ -727,9 +729,9 @@ Install dependencies go build . ``` -### Step 2: Run the application with resiliency enabled +### Step 2: Run the application -Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` command below, the `--config` parameter applies a Dapr configuration that enables the resiliency feature. By enabling resiliency, the resiliency spec located in the components directory is loaded by the `order-processor` sidecar. The resilency spec is: +Run the `order-processor` service alongside a Dapr sidecar. The Dapr sidecar then loads the resiliency spec located in the resources directory: ```yaml apiVersion: dapr.io/v1alpha1 @@ -761,7 +763,7 @@ Run the `order-processor` service alongside a Dapr sidecar. In the `dapr run` co ``` ```bash -dapr run --app-id order-processor --config ../config.yaml --components-path ../../../components -- go run . +dapr run --app-id order-processor --resources-path ../../../resources -- go run . ``` Once the application has started, the `order-processor`service writes and reads `orderId` key/value pairs to the `statestore` Redis instance [defined in the `statestore.yaml` component]({{< ref "statemanagement-quickstart.md#statestoreyaml-component-file" >}}). @@ -804,7 +806,7 @@ Once Redis is stopped, the requests begin to fail and the retry policy titled `r INFO[0006] Error processing operation component[statestore] output. Retrying... ``` -As per the `retryFroever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. +As per the `retryForever` policy, retries will continue for each failed request indefinitely, in 5 second intervals. ```yaml retryForever: diff --git a/daprdocs/content/en/operations/components/pluggable-components-registration.md b/daprdocs/content/en/operations/components/pluggable-components-registration.md index d7e91e347..06a4b6a2e 100644 --- a/daprdocs/content/en/operations/components/pluggable-components-registration.md +++ b/daprdocs/content/en/operations/components/pluggable-components-registration.md @@ -57,7 +57,7 @@ Since you are running Dapr in the same host as the component, verify this folder Define your component using a [component spec]({{< ref component-schema.md >}}). Your component's `type` is derived from the socket name, without the file extension. -Save the component YAML file in the components-path, replacing: +Save the component YAML file in the resources-path, replacing: - `your_socket_goes_here` with your component socket name (no extension) - `your_component_type` with your component type From 3fa9fabee0263bbfa5b752652a72a09cf1805648 Mon Sep 17 00:00:00 2001 From: Hannah Hunter <94493363+hhunter-ms@users.noreply.github.com> Date: Fri, 27 Jan 2023 00:27:13 -0600 Subject: [PATCH 14/25] fix typo (#3082) Signed-off-by: Hannah Hunter Signed-off-by: Hannah Hunter --- .../supported-pubsub/setup-jetstream.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-jetstream.md b/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-jetstream.md index 815430fd7..d62a73fe3 100644 --- a/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-jetstream.md +++ b/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-jetstream.md @@ -62,7 +62,7 @@ spec: value: false - name: rateLimit value: 1024 - - name: hearbeat + - name: heartbeat value: 15s - name: ackPolicy value: explicit @@ -98,7 +98,7 @@ spec: | replicas | N | [Replicas] | `3` | | memoryStorage | N | [Memory Storage] | `false` | | rateLimit | N | [Rate Limit] | `1024` | -| hearbeat | N | [Hearbeat] | `10s` | +| heartbeat | N | [Heartbeat] | `10s` | | ackPolicy | N | [Ack Policy] | `explicit` | | deliverPolicy | N | One of: all, last, new, sequence, time | `all` | | domain | N | [JetStream Leafondes] | `HUB` | @@ -166,7 +166,7 @@ nats -s localhost:4222 stream add myStream --subjects mySubject [Replicas]: https://docs.nats.io/jetstream/concepts/consumers#replicas [Memory Storage]: https://docs.nats.io/jetstream/concepts/consumers#memorystorage [Rate Limit]: https://docs.nats.io/jetstream/concepts/consumers#ratelimit -[Hearbeat]: https://docs.nats.io/jetstream/concepts/consumers#hearbeat +[Heartbeat]: https://docs.nats.io/jetstream/concepts/consumers#heartbeat [Ack Policy]: https://docs.nats.io/nats-concepts/jetstream/consumers#ackpolicy [JetStream Leafonodes]: https://docs.nats.io/running-a-nats-service/configuration/leafnodes/jetstream_leafnodes [Decentralized JWT Authentication/Authorization]: https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/jwt From 07ab3ebda9440f1ca9a9470eb3411cac2fd930e0 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Mon, 30 Jan 2023 10:59:37 +0530 Subject: [PATCH 15/25] Add explicit feature to comp data Signed-off-by: Shubham Sharma --- daprdocs/data/components/pubsub/aws.yaml | 3 +++ daprdocs/data/components/pubsub/gcp.yaml | 3 +++ daprdocs/data/components/pubsub/generic.yaml | 24 ++++++++++++++++++++ 3 files changed, 30 insertions(+) diff --git a/daprdocs/data/components/pubsub/aws.yaml b/daprdocs/data/components/pubsub/aws.yaml index fa5328ab9..07db7e27d 100644 --- a/daprdocs/data/components/pubsub/aws.yaml +++ b/daprdocs/data/components/pubsub/aws.yaml @@ -3,3 +3,6 @@ state: Beta version: v1 since: "1.6" + features: + bulkPublish: false + bulkSubscribe: false diff --git a/daprdocs/data/components/pubsub/gcp.yaml b/daprdocs/data/components/pubsub/gcp.yaml index 8fd547af9..815ced19b 100644 --- a/daprdocs/data/components/pubsub/gcp.yaml +++ b/daprdocs/data/components/pubsub/gcp.yaml @@ -3,3 +3,6 @@ state: Alpha version: v1 since: "1.0" + features: + bulkPublish: false + bulkSubscribe: false diff --git a/daprdocs/data/components/pubsub/generic.yaml b/daprdocs/data/components/pubsub/generic.yaml index ab1bf5d01..02035a7ec 100644 --- a/daprdocs/data/components/pubsub/generic.yaml +++ b/daprdocs/data/components/pubsub/generic.yaml @@ -3,11 +3,17 @@ state: Beta version: v1 since: "1.7" + features: + bulkPublish: false + bulkSubscribe: false - component: In Memory link: setup-inmemory state: Beta version: v1 since: "1.7" + features: + bulkPublish: false + bulkSubscribe: false - component: Apache Kafka link: setup-apache-kafka state: Stable @@ -21,28 +27,46 @@ state: Stable version: v1 since: "1.0" + features: + bulkPublish: false + bulkSubscribe: false - component: JetStream link: setup-jetstream state: Alpha version: v1 since: "1.4" + features: + bulkPublish: false + bulkSubscribe: false - component: Pulsar link: setup-pulsar state: Beta version: v1 since: "1.7" + features: + bulkPublish: false + bulkSubscribe: false - component: MQTT link: setup-mqtt state: Stable version: v1 since: "1.7" + features: + bulkPublish: false + bulkSubscribe: false - component: NATS Streaming link: setup-nats-streaming state: Beta version: v1 since: "1.0" + features: + bulkPublish: false + bulkSubscribe: false - component: RabbitMQ link: setup-rabbitmq state: Stable version: v1 since: "1.7" + features: + bulkPublish: false + bulkSubscribe: false From 73ebc9ac40f0842e30f350da98c4071da4ea9956 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Mon, 30 Jan 2023 12:14:01 +0530 Subject: [PATCH 16/25] Add more examples Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 135 ++++++++++++++++-- .../building-blocks/pubsub/pubsub-overview.md | 2 +- .../content/en/reference/api/pubsub_api.md | 10 +- 3 files changed, 133 insertions(+), 14 deletions(-) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md index e7ebc89ef..afaff5430 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -1,7 +1,7 @@ --- type: docs -title: "Send and receive messages in bulk" -linkTitle: "Send and receive messages in bulk" +title: "Publish and subscribe to bulk messages" +linkTitle: "Publish and subscribe to bulk messages" weight: 7100 description: "Learn how to use the bulk publish and subscribe APIs in Dapr." --- @@ -10,7 +10,8 @@ description: "Learn how to use the bulk publish and subscribe APIs in Dapr." The bulk publish and subscribe APIs are in **alpha** stage. {{% /alert %}} -With the bulk publish and subscribe APIs, you can send and receive multiple messages in a single request. +With the bulk publish and subscribe APIs, you can publish and subscribe to multiple messages in a single request. + ## Native bulk publish and subscribe support @@ -28,7 +29,7 @@ The bulk publish API allows you to publish multiple messages to a topic in a sin ### Example -{{< tabs Java Javascript "HTTP API (Bash)" "HTTP API (PowerShell)" >}} +{{< tabs Java Javascript Dotnet Python Go "HTTP API (Bash)" "HTTP API (PowerShell)" >}} {{% codetab %}} @@ -41,6 +42,9 @@ import java.util.ArrayList; import java.util.List; class BulkPublisher { + private static final String PUBSUB_NAME = "my-pubsub-name"; + private static final String TOPIC_NAME = "topic-a"; + public void publishMessages() { try (DaprPreviewClient client = (new DaprClientBuilder()).buildPreviewClient()) { // Create a list of messages to publish @@ -112,19 +116,134 @@ start().catch((e) => { {{% codetab %}} +```csharp +using System; +using System.Collections.Generic; +using Dapr.Client; + +const string PubsubName = "my-pubsub-name"; +const string TopicName = "topic-a"; +IReadOnlyList BulkPublishData = new List() { + new { Id = "17", Amount = 10m }, + new { Id = "18", Amount = 20m }, + new { Id = "19", Amount = 30m } +}; + +using var client = new DaprClientBuilder().Build(); + +var res = await client.BulkPublishEventAsync(PubsubName, TopicName, BulkPublishData); +if (res == null) { + throw new Exception("null response from dapr"); +} +if (res.FailedEntries.Count > 0) +{ + Console.WriteLine("Some events failed to be published!"); + foreach (var failedEntry in res.FailedEntries) + { + Console.WriteLine("EntryId: " + failedEntry.Entry.EntryId + " Error message: " + + failedEntry.ErrorMessage); + } +} +else +{ + Console.WriteLine("Published all events!"); +} +``` + +{{% /codetab %}} + +{{% codetab %}} + +```python +import requests +import json + +base_url = "http://localhost:3500/v1.0-alpha1/publish/bulk/{}/{}" +pubsub_name = "my-pubsub-name" +topic_name = "topic-a" +payload = [ + { + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "event": "first text message", + "contentType": "text/plain" + }, + { + "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", + "event": { + "message": "second JSON message" + }, + "contentType": "application/json" + } +] + +response = requests.post(base_url.format(pubsub_name, topic_name), json=payload) +print(response.status_code) +``` + +{{% /codetab %}} + +{{% codetab %}} + +```go +package main + +import ( + "fmt" + "strings" + "net/http" + "io/ioutil" +) + +const ( + pubsubName = "my-pubsub-name" + topicName = "topic-a" + baseUrl = "http://localhost:3500/v1.0-alpha1/publish/bulk/%s/%s" +) + +func main() { + url := fmt.Sprintf(baseUrl, pubsubName, topicName) + method := "POST" + payload := strings.NewReader(`[ + { + "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", + "event": "first text message", + "contentType": "text/plain" + }, + { + "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", + "event": { + "message": "second JSON message" + }, + "contentType": "application/json" + } +]`) + + client := &http.Client {} + req, _ := http.NewRequest(method, url, payload) + + req.Header.Add("Content-Type", "application/json") + res, err := client.Do(req) + // ... +} +``` + +{{% /codetab %}} + +{{% codetab %}} + ```bash curl -X POST http://localhost:3500/v1.0-alpha1/publish/bulk/my-pubsub-name/topic-a \ -H 'Content-Type: application/json' \ -d '[ { "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", - "event": "first", + "event": "first text message", "contentType": "text/plain" }, { "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", "event": { - "message": "second" + "message": "second JSON message" }, "contentType": "application/json" }, @@ -140,13 +259,13 @@ Invoke-RestMethod -Method Post -ContentType 'application/json' -Uri 'http://loca -Body '[ { "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", - "event": "first", + "event": "first text message", "contentType": "text/plain" }, { "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", "event": { - "message": "second" + "message": "second JSON message" }, "contentType": "application/json" }, diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md index 93bc84314..b7c999a94 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md @@ -119,7 +119,7 @@ By default, all topic messages associated with an instance of a pub/sub componen Dapr can set a timeout message on a per-message basis, meaning that if the message is not read from the pub/sub component, then the message is discarded. This timeout message prevents a build up of unread messages. If a message has been in the queue longer than the configured TTL, it is marked as dead. For more information, read [pub/sub message TTL]({{< ref pubsub-message-ttl.md >}}). -### Send and receive messages in bulk +### Publish and subscribe to bulk messages Dapr supports sending and receiving multiple messages in a single request. This is useful for applications that require a high throughput. For more information, read [pub/sub bulk messages]({{< ref pubsub-bulk.md >}}). diff --git a/daprdocs/content/en/reference/api/pubsub_api.md b/daprdocs/content/en/reference/api/pubsub_api.md index 3bdbe09aa..198f71f10 100644 --- a/daprdocs/content/en/reference/api/pubsub_api.md +++ b/daprdocs/content/en/reference/api/pubsub_api.md @@ -89,13 +89,13 @@ curl -X POST http://localhost:3500/v1.0-alpha1/publish/bulk/pubsubName/deathStar -d '[ { "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", - "event": "first", + "event": "first text message", "contentType": "text/plain" }, { "entryId": "b1f40bd6-4af2-11ed-b878-0242ac120002", "event": { - "message": "second" + "message": "second JSON message" }, "contentType": "application/json" }, @@ -104,7 +104,7 @@ curl -X POST http://localhost:3500/v1.0-alpha1/publish/bulk/pubsubName/deathStar ### Headers -The `Content-Type` header should always be set to `application/json`. +The `Content-Type` header should always be set to `application/json` since the request body is a JSON array. ### URL Parameters @@ -134,14 +134,14 @@ Metadata can be sent via query parameters in the request's URL. It must be prefi |403|Forbidden by access controls| |500|At least one message failed to be delivered| -The response body is a JSON containing a list of failed entries. Example: +In case of a 500 status code, the response body will contain a JSON object containing a list of entries that failed to be delivered. For example from our request above, if the entry with event `"first text message"` failed to be delivered, the response would contain its entry ID and an error message from the underlying pub/sub component. ```json { "failedEntries": [ { "entryId": "ae6bf7c6-4af2-11ed-b878-0242ac120002", - "error": "error message" + "error": "some error message" }, ], "errorCode": "ERR_PUBSUB_PUBLISH_MESSAGE" From 864db6341f98a54607997cb8dc80113c2c82fb65 Mon Sep 17 00:00:00 2001 From: Shubham Sharma Date: Mon, 30 Jan 2023 13:15:15 +0530 Subject: [PATCH 17/25] Address comments Signed-off-by: Shubham Sharma --- .../building-blocks/pubsub/pubsub-bulk.md | 29 ++++++++++--------- .../building-blocks/pubsub/pubsub-overview.md | 2 +- 2 files changed, 17 insertions(+), 14 deletions(-) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md index afaff5430..35c88dd86 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-bulk.md @@ -10,22 +10,15 @@ description: "Learn how to use the bulk publish and subscribe APIs in Dapr." The bulk publish and subscribe APIs are in **alpha** stage. {{% /alert %}} -With the bulk publish and subscribe APIs, you can publish and subscribe to multiple messages in a single request. - - -## Native bulk publish and subscribe support - -When a pub/sub component supports the bulk publish API natively, Dapr also publishes messages to the underlying pub/sub component in bulk. - -Otherwise, Dapr falls back to sending messages one by one to the underlying pub/sub component. This is still more efficient than using the regular publish API, because applications can still send multiple messages in a single request to Dapr. - -## Supported components - -Refer to the [component reference]({{< ref supported-pubsub >}}) to see which components support the bulk publish API natively. +With the bulk publish and subscribe APIs, you can publish and subscribe to multiple messages in a single request. When writing applications that need to send or receive a large number of messages, using bulk operations allows achieving high throughput by reducing the overall number of requests between the Dapr sidecar, the application, and the underlying pub/sub broker. ## Publishing messages in bulk -The bulk publish API allows you to publish multiple messages to a topic in a single request. If any of the messages fail to publish, the bulk publish operation returns a list of failed messages. Note, the bulk publish operation does not guarantee the order of messages. +### Restrictions when publishing messages in bulk + +The bulk publish API allows you to publish multiple messages to a topic in a single request. It is *non-transactional*, i.e., from a single bulk request, some messages can succeed and some can fail. If any of the messages fail to publish, the bulk publish operation returns a list of failed messages. + +The bulk publish operation also does not guarantee any ordering of messages. ### Example @@ -276,6 +269,16 @@ Invoke-RestMethod -Method Post -ContentType 'application/json' -Uri 'http://loca {{< /tabs >}} +## How components handle publishing and subscribing to bulk messages + +Some pub/sub brokers support sending and receiving multiple messages in a single request. When a component supports bulk publish or subscribe operations, Dapr runtime uses them to further optimize the communication between the Dapr sidecar and the underlying pub/sub broker. + +For components that do not have bulk publish or subscribe support, Dapr runtime uses the regular publish and subscribe APIs to send and receive messages one by one. This is still more efficient than directly using the regular publish or subscribe APIs, because applications can still send/receive multiple messages in a single request to/from Dapr. + +## Supported components + +Refer to the [component reference]({{< ref supported-pubsub >}}) to see which components support bulk publish and subscribe operations. + ## Related links - List of [supported pub/sub components]({{< ref supported-pubsub >}}) diff --git a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md index b7c999a94..b0015ee2e 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md +++ b/daprdocs/content/en/developing-applications/building-blocks/pubsub/pubsub-overview.md @@ -121,7 +121,7 @@ Dapr can set a timeout message on a per-message basis, meaning that if the messa ### Publish and subscribe to bulk messages -Dapr supports sending and receiving multiple messages in a single request. This is useful for applications that require a high throughput. For more information, read [pub/sub bulk messages]({{< ref pubsub-bulk.md >}}). +Dapr supports sending and receiving multiple messages in a single request. When writing applications that need to send or receive a large number of messages, using bulk operations allows achieving high throughput by reducing the overall number of requests. For more information, read [pub/sub bulk messages]({{< ref pubsub-bulk.md >}}). ## Try out pub/sub From 9551d689ae7e83585513564ec7e7d64d8faea720 Mon Sep 17 00:00:00 2001 From: Pravin Pushkar Date: Wed, 1 Feb 2023 01:04:16 +0530 Subject: [PATCH 18/25] [HTTP Binding]: adding metadata options for client auth during mTLS (#3050) * [HTTP Binding]: adding metadata options for client authentication during mTLS Signed-off-by: Pravin Pushkar * Apply suggestions from code review Co-authored-by: Hannah Hunter <94493363+hhunter-ms@users.noreply.github.com> Signed-off-by: Pravin Pushkar * Update daprdocs/content/en/reference/components-reference/supported-bindings/http.md Signed-off-by: Mark Fussell * Update daprdocs/content/en/reference/components-reference/supported-bindings/http.md Signed-off-by: Mark Fussell * Update daprdocs/content/en/reference/components-reference/supported-bindings/http.md Signed-off-by: Mark Fussell --------- Signed-off-by: Pravin Pushkar Signed-off-by: Mark Fussell Co-authored-by: Hannah Hunter <94493363+hhunter-ms@users.noreply.github.com> Co-authored-by: Mark Fussell --- .../supported-bindings/http.md | 21 + daprdocs/package-lock.json | 873 ++++++++++++------ 2 files changed, 625 insertions(+), 269 deletions(-) diff --git a/daprdocs/content/en/reference/components-reference/supported-bindings/http.md b/daprdocs/content/en/reference/components-reference/supported-bindings/http.md index ab0ba190a..4d71f6ae6 100644 --- a/daprdocs/content/en/reference/components-reference/supported-bindings/http.md +++ b/daprdocs/content/en/reference/components-reference/supported-bindings/http.md @@ -20,6 +20,13 @@ spec: metadata: - name: url value: http://something.com + - name: MTLSRootCA + value: /Users/somepath/root.pem # or + - name: MTLSClientCert + value: /Users/somepath/client.pem # or + - name: MTLSClientKey + value: /Users/somepath/client.key # or + ``` ## Spec metadata fields @@ -27,6 +34,9 @@ spec: | Field | Required | Binding support | Details | Example | |--------------------|:--------:|--------|--------|---------| | url | Y | Output |The base URL of the HTTP endpoint to invoke | `http://host:port/path`, `http://myservice:8000/customers` +| MTLSRootCA | N | Output |Path to root ca certificate or pem encoded string | +| MTLSClientCert | N | Output |Path to client certificate or pem encoded string | +| MTLSClientKey | N | Output |Path client private key or pem encoded string | ## Binding support @@ -292,6 +302,17 @@ curl -d '{ "operation": "get" }' \ {{< /tabs >}} +## Using mTLS or enabling client TLS authentication along with HTTPS +You can configure the HTTP binding to use mTLS or client TLS authentication along with HTTPS by providing the `MTLSRootCA`, `MTLSClientCert`, and `MTLSClientKey` metadata fields in the binding component. + +These fields can be passed as a file path or as a pem encoded string. +- If the file path is provided, the file is read and the contents are used. +- If the pem encoded string is provided, the string is used as is. +When these fields are configured, the Dapr sidecar uses the provided certificate to authenticate itself with the server during the TLS handshake process. + +### When to use: +You can use this when the server with which the HTTP binding is configured to communicate requires mTLS or client TLS authentication. + ## Related links diff --git a/daprdocs/package-lock.json b/daprdocs/package-lock.json index 2d310e1d5..adc813bba 100644 --- a/daprdocs/package-lock.json +++ b/daprdocs/package-lock.json @@ -1,615 +1,842 @@ { "name": "dapr-docs-hugo", "version": "0.0.1", - "lockfileVersion": 1, + "lockfileVersion": 3, "requires": true, - "dependencies": { - "@babel/code-frame": { + "packages": { + "": { + "name": "dapr-docs-hugo", + "version": "0.0.1", + "dependencies": { + "autoprefixer": "^10.2.5", + "postcss": "^8.3.0" + }, + "devDependencies": { + "autoprefixer": "^10.2.5", + "postcss-cli": "^8.3.1" + } + }, + "node_modules/@babel/code-frame": { "version": "7.12.13", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.12.13.tgz", "integrity": "sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g==", "dev": true, - "requires": { + "dependencies": { "@babel/highlight": "^7.12.13" } }, - "@babel/helper-validator-identifier": { + "node_modules/@babel/helper-validator-identifier": { "version": "7.14.0", "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.0.tgz", "integrity": "sha512-V3ts7zMSu5lfiwWDVWzRDGIN+lnCEUdaXgtVHJgLb1rGaA6jMrtB9EmE7L18foXJIE8Un/A/h6NJfGQp/e1J4A==", "dev": true }, - "@babel/highlight": { + "node_modules/@babel/highlight": { "version": "7.14.0", "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.14.0.tgz", "integrity": "sha512-YSCOwxvTYEIMSGaBQb5kDDsCopDdiUGsqpatp3fOlI4+2HQSkTmEVWnVuySdAC5EWCqSWWTv0ib63RjR7dTBdg==", "dev": true, - "requires": { + "dependencies": { "@babel/helper-validator-identifier": "^7.14.0", "chalk": "^2.0.0", "js-tokens": "^4.0.0" } }, - "@nodelib/fs.scandir": { + "node_modules/@nodelib/fs.scandir": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.3.tgz", "integrity": "sha512-eGmwYQn3gxo4r7jdQnkrrN6bY478C3P+a/y72IJukF8LjB6ZHeB3c+Ehacj3sYeSmUXGlnA67/PmbM9CVwL7Dw==", "dev": true, - "requires": { + "dependencies": { "@nodelib/fs.stat": "2.0.3", "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" } }, - "@nodelib/fs.stat": { + "node_modules/@nodelib/fs.stat": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.3.tgz", "integrity": "sha512-bQBFruR2TAwoevBEd/NWMoAAtNGzTRgdrqnYCc7dhzfoNvqPzLyqlEQnzZ3kVnNrSp25iyxE00/3h2fqGAGArA==", - "dev": true + "dev": true, + "engines": { + "node": ">= 8" + } }, - "@nodelib/fs.walk": { + "node_modules/@nodelib/fs.walk": { "version": "1.2.4", "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.4.tgz", "integrity": "sha512-1V9XOY4rDW0rehzbrcqAmHnz8e7SKvX27gh8Gt2WgB0+pdzdiLV83p72kZPU+jvMbS1qU5mauP2iOvO8rhmurQ==", "dev": true, - "requires": { + "dependencies": { "@nodelib/fs.scandir": "2.1.3", "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" } }, - "@types/color-name": { + "node_modules/@types/color-name": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", "dev": true }, - "@types/parse-json": { + "node_modules/@types/parse-json": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz", "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==", "dev": true }, - "ansi-regex": { + "node_modules/ansi-regex": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", - "dev": true + "dev": true, + "engines": { + "node": ">=8" + } }, - "ansi-styles": { + "node_modules/ansi-styles": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, - "requires": { + "dependencies": { "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" } }, - "anymatch": { + "node_modules/anymatch": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", "dev": true, - "requires": { + "dependencies": { "normalize-path": "^3.0.0", "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" } }, - "array-union": { + "node_modules/array-union": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", - "dev": true + "dev": true, + "engines": { + "node": ">=8" + } }, - "at-least-node": { + "node_modules/at-least-node": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", - "dev": true + "dev": true, + "engines": { + "node": ">= 4.0.0" + } }, - "autoprefixer": { + "node_modules/autoprefixer": { "version": "10.2.6", "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.2.6.tgz", "integrity": "sha512-8lChSmdU6dCNMCQopIf4Pe5kipkAGj/fvTMslCsih0uHpOrXOPUEVOmYMMqmw3cekQkSD7EhIeuYl5y0BLdKqg==", - "requires": { + "dev": true, + "dependencies": { "browserslist": "^4.16.6", "caniuse-lite": "^1.0.30001230", "colorette": "^1.2.2", "fraction.js": "^4.1.1", "normalize-range": "^0.1.2", "postcss-value-parser": "^4.1.0" + }, + "bin": { + "autoprefixer": "bin/autoprefixer" + }, + "engines": { + "node": "^10 || ^12 || >=14" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + "peerDependencies": { + "postcss": "^8.1.0" } }, - "binary-extensions": { + "node_modules/binary-extensions": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==", - "dev": true + "dev": true, + "engines": { + "node": ">=8" + } }, - "braces": { + "node_modules/braces": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", "dev": true, - "requires": { + "dependencies": { "fill-range": "^7.0.1" + }, + "engines": { + "node": ">=8" } }, - "browserslist": { + "node_modules/browserslist": { "version": "4.16.6", "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.16.6.tgz", "integrity": "sha512-Wspk/PqO+4W9qp5iUTJsa1B/QrYn1keNCcEP5OvP7WBwT4KaDly0uONYmC6Xa3Z5IqnUgS0KcgLYu1l74x0ZXQ==", - "requires": { + "dev": true, + "dependencies": { "caniuse-lite": "^1.0.30001219", "colorette": "^1.2.2", "electron-to-chromium": "^1.3.723", "escalade": "^3.1.1", "node-releases": "^1.1.71" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" } }, - "callsites": { + "node_modules/callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", - "dev": true + "dev": true, + "engines": { + "node": ">=6" + } }, - "caniuse-lite": { + "node_modules/caniuse-lite": { "version": "1.0.30001230", "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001230.tgz", - "integrity": "sha512-5yBd5nWCBS+jWKTcHOzXwo5xzcj4ePE/yjtkZyUV1BTUmrBaA9MRGC+e7mxnqXSA90CmCA8L3eKLaSUkt099IQ==" + "integrity": "sha512-5yBd5nWCBS+jWKTcHOzXwo5xzcj4ePE/yjtkZyUV1BTUmrBaA9MRGC+e7mxnqXSA90CmCA8L3eKLaSUkt099IQ==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + } }, - "chalk": { + "node_modules/chalk": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, - "requires": { + "dependencies": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" } }, - "chokidar": { + "node_modules/chokidar": { "version": "3.4.2", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", "dev": true, - "requires": { + "dependencies": { "anymatch": "~3.1.1", "braces": "~3.0.2", - "fsevents": "~2.1.2", "glob-parent": "~5.1.0", "is-binary-path": "~2.1.0", "is-glob": "~4.0.1", "normalize-path": "~3.0.0", "readdirp": "~3.4.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "optionalDependencies": { + "fsevents": "~2.1.2" } }, - "cliui": { + "node_modules/cliui": { "version": "7.0.4", "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", "dev": true, - "requires": { + "dependencies": { "string-width": "^4.2.0", "strip-ansi": "^6.0.0", "wrap-ansi": "^7.0.0" } }, - "color-convert": { + "node_modules/color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", "dev": true, - "requires": { + "dependencies": { "color-name": "1.1.3" } }, - "color-name": { + "node_modules/color-name": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", "dev": true }, - "colorette": { + "node_modules/colorette": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.2.2.tgz", "integrity": "sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==" }, - "cosmiconfig": { + "node_modules/cosmiconfig": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.0.0.tgz", "integrity": "sha512-pondGvTuVYDk++upghXJabWzL6Kxu6f26ljFw64Swq9v6sQPUL3EUlVDV56diOjpCayKihL6hVe8exIACU4XcA==", "dev": true, - "requires": { + "dependencies": { "@types/parse-json": "^4.0.0", "import-fresh": "^3.2.1", "parse-json": "^5.0.0", "path-type": "^4.0.0", "yaml": "^1.10.0" + }, + "engines": { + "node": ">=10" } }, - "dependency-graph": { + "node_modules/dependency-graph": { "version": "0.9.0", "resolved": "https://registry.npmjs.org/dependency-graph/-/dependency-graph-0.9.0.tgz", "integrity": "sha512-9YLIBURXj4DJMFALxXw9K3Y3rwb5Fk0X5/8ipCzaN84+gKxoHK43tVKRNakCQbiEx07E8Uwhuq21BpUagFhZ8w==", - "dev": true + "dev": true, + "engines": { + "node": ">= 0.6.0" + } }, - "dir-glob": { + "node_modules/dir-glob": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", "dev": true, - "requires": { + "dependencies": { "path-type": "^4.0.0" + }, + "engines": { + "node": ">=8" } }, - "electron-to-chromium": { + "node_modules/electron-to-chromium": { "version": "1.3.739", "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.739.tgz", - "integrity": "sha512-+LPJVRsN7hGZ9EIUUiWCpO7l4E3qBYHNadazlucBfsXBbccDFNKUBAgzE68FnkWGJPwD/AfKhSzL+G+Iqb8A4A==" + "integrity": "sha512-+LPJVRsN7hGZ9EIUUiWCpO7l4E3qBYHNadazlucBfsXBbccDFNKUBAgzE68FnkWGJPwD/AfKhSzL+G+Iqb8A4A==", + "dev": true }, - "emoji-regex": { + "node_modules/emoji-regex": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, - "error-ex": { + "node_modules/error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", "dev": true, - "requires": { + "dependencies": { "is-arrayish": "^0.2.1" } }, - "escalade": { + "node_modules/escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", - "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==" + "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "dev": true, + "engines": { + "node": ">=6" + } }, - "escape-string-regexp": { + "node_modules/escape-string-regexp": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", - "dev": true + "dev": true, + "engines": { + "node": ">=0.8.0" + } }, - "fast-glob": { + "node_modules/fast-glob": { "version": "3.2.4", "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.4.tgz", "integrity": "sha512-kr/Oo6PX51265qeuCYsyGypiO5uJFgBS0jksyG7FUeCyQzNwYnzrNIMR1NXfkZXsMYXYLRAHgISHBz8gQcxKHQ==", "dev": true, - "requires": { + "dependencies": { "@nodelib/fs.stat": "^2.0.2", "@nodelib/fs.walk": "^1.2.3", "glob-parent": "^5.1.0", "merge2": "^1.3.0", "micromatch": "^4.0.2", "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8" } }, - "fastq": { + "node_modules/fastq": { "version": "1.8.0", "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.8.0.tgz", "integrity": "sha512-SMIZoZdLh/fgofivvIkmknUXyPnvxRE3DhtZ5Me3Mrsk5gyPL42F0xr51TdRXskBxHfMp+07bcYzfsYEsSQA9Q==", "dev": true, - "requires": { + "dependencies": { "reusify": "^1.0.4" } }, - "fill-range": { + "node_modules/fill-range": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", "dev": true, - "requires": { + "dependencies": { "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" } }, - "fraction.js": { + "node_modules/fraction.js": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/fraction.js/-/fraction.js-4.1.1.tgz", - "integrity": "sha512-MHOhvvxHTfRFpF1geTK9czMIZ6xclsEor2wkIGYYq+PxcQqT7vStJqjhe6S1TenZrMZzo+wlqOufBDVepUEgPg==" + "integrity": "sha512-MHOhvvxHTfRFpF1geTK9czMIZ6xclsEor2wkIGYYq+PxcQqT7vStJqjhe6S1TenZrMZzo+wlqOufBDVepUEgPg==", + "dev": true, + "engines": { + "node": "*" + }, + "funding": { + "type": "patreon", + "url": "https://www.patreon.com/infusion" + } }, - "fs-extra": { + "node_modules/fs-extra": { "version": "9.0.1", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.0.1.tgz", "integrity": "sha512-h2iAoN838FqAFJY2/qVpzFXy+EBxfVE220PalAqQLDVsFOHLJrZvut5puAbCdNv6WJk+B8ihI+k0c7JK5erwqQ==", "dev": true, - "requires": { + "dependencies": { "at-least-node": "^1.0.0", "graceful-fs": "^4.2.0", "jsonfile": "^6.0.1", "universalify": "^1.0.0" + }, + "engines": { + "node": ">=10" } }, - "fsevents": { + "node_modules/fsevents": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", + "deprecated": "\"Please update to latest v2.3 or v2.2\"", "dev": true, - "optional": true + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } }, - "get-caller-file": { + "node_modules/get-caller-file": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true + "dev": true, + "engines": { + "node": "6.* || 8.* || >= 10.*" + } }, - "get-stdin": { + "node_modules/get-stdin": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-8.0.0.tgz", "integrity": "sha512-sY22aA6xchAzprjyqmSEQv4UbAAzRN0L2dQB0NlN5acTTK9Don6nhoc3eAbUnpZiCANAMfd/+40kVdKfFygohg==", - "dev": true + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, - "glob-parent": { + "node_modules/glob-parent": { "version": "5.1.2", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, - "requires": { + "dependencies": { "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" } }, - "globby": { + "node_modules/globby": { "version": "11.0.1", "resolved": "https://registry.npmjs.org/globby/-/globby-11.0.1.tgz", "integrity": "sha512-iH9RmgwCmUJHi2z5o2l3eTtGBtXek1OYlHrbcxOYugyHLmAsZrPj43OtHThd62Buh/Vv6VyCBD2bdyWcGNQqoQ==", "dev": true, - "requires": { + "dependencies": { "array-union": "^2.1.0", "dir-glob": "^3.0.1", "fast-glob": "^3.1.1", "ignore": "^5.1.4", "merge2": "^1.3.0", "slash": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "graceful-fs": { + "node_modules/graceful-fs": { "version": "4.2.4", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.4.tgz", "integrity": "sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw==", "dev": true }, - "has-flag": { + "node_modules/has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", - "dev": true + "dev": true, + "engines": { + "node": ">=4" + } }, - "ignore": { + "node_modules/ignore": { "version": "5.1.8", "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.1.8.tgz", "integrity": "sha512-BMpfD7PpiETpBl/A6S498BaIJ6Y/ABT93ETbby2fP00v4EbvPBXWEoaR1UBPKs3iR53pJY7EtZk5KACI57i1Uw==", - "dev": true + "dev": true, + "engines": { + "node": ">= 4" + } }, - "import-cwd": { + "node_modules/import-cwd": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/import-cwd/-/import-cwd-3.0.0.tgz", "integrity": "sha512-4pnzH16plW+hgvRECbDWpQl3cqtvSofHWh44met7ESfZ8UZOWWddm8hEyDTqREJ9RbYHY8gi8DqmaelApoOGMg==", "dev": true, - "requires": { + "dependencies": { "import-from": "^3.0.0" + }, + "engines": { + "node": ">=8" } }, - "import-fresh": { + "node_modules/import-fresh": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", "dev": true, - "requires": { + "dependencies": { "parent-module": "^1.0.0", "resolve-from": "^4.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "import-from": { + "node_modules/import-from": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/import-from/-/import-from-3.0.0.tgz", "integrity": "sha512-CiuXOFFSzkU5x/CR0+z7T91Iht4CXgfCxVOFRhh2Zyhg5wOpWvvDLQUsWl+gcN+QscYBjez8hDCt85O7RLDttQ==", "dev": true, - "requires": { + "dependencies": { "resolve-from": "^5.0.0" }, - "dependencies": { - "resolve-from": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", - "dev": true - } + "engines": { + "node": ">=8" } }, - "is-arrayish": { + "node_modules/import-from/node_modules/resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-arrayish": { "version": "0.2.1", "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=", "dev": true }, - "is-binary-path": { + "node_modules/is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", "dev": true, - "requires": { + "dependencies": { "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" } }, - "is-extglob": { + "node_modules/is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "dev": true + "dev": true, + "engines": { + "node": ">=0.10.0" + } }, - "is-fullwidth-code-point": { + "node_modules/is-fullwidth-code-point": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true + "dev": true, + "engines": { + "node": ">=8" + } }, - "is-glob": { + "node_modules/is-glob": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", "dev": true, - "requires": { + "dependencies": { "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" } }, - "is-number": { + "node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true + "dev": true, + "engines": { + "node": ">=0.12.0" + } }, - "js-tokens": { + "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", "dev": true }, - "json-parse-even-better-errors": { + "node_modules/json-parse-even-better-errors": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", "dev": true }, - "jsonfile": { + "node_modules/jsonfile": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.0.1.tgz", "integrity": "sha512-jR2b5v7d2vIOust+w3wtFKZIfpC2pnRmFAhAC/BuweZFQR8qZzxH1OyrQ10HmdVYiXWkYUqPVsz91cG7EL2FBg==", "dev": true, - "requires": { - "graceful-fs": "^4.1.6", + "dependencies": { "universalify": "^1.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" } }, - "lines-and-columns": { + "node_modules/lines-and-columns": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.1.6.tgz", "integrity": "sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=", "dev": true }, - "lodash.difference": { + "node_modules/lodash.difference": { "version": "4.5.0", "resolved": "https://registry.npmjs.org/lodash.difference/-/lodash.difference-4.5.0.tgz", "integrity": "sha1-nMtOUF1Ia5FlE0V3KIWi3yf9AXw=", "dev": true }, - "lodash.forown": { + "node_modules/lodash.forown": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/lodash.forown/-/lodash.forown-4.4.0.tgz", "integrity": "sha1-hRFc8E9z75ZuztUlEdOJPMRmg68=", "dev": true }, - "lodash.get": { + "node_modules/lodash.get": { "version": "4.4.2", "resolved": "https://registry.npmjs.org/lodash.get/-/lodash.get-4.4.2.tgz", "integrity": "sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk=", "dev": true }, - "lodash.groupby": { + "node_modules/lodash.groupby": { "version": "4.6.0", "resolved": "https://registry.npmjs.org/lodash.groupby/-/lodash.groupby-4.6.0.tgz", "integrity": "sha1-Cwih3PaDl8OXhVwyOXg4Mt90A9E=", "dev": true }, - "lodash.sortby": { + "node_modules/lodash.sortby": { "version": "4.7.0", "resolved": "https://registry.npmjs.org/lodash.sortby/-/lodash.sortby-4.7.0.tgz", "integrity": "sha1-7dFMgk4sycHgsKG0K7UhBRakJDg=", "dev": true }, - "merge2": { + "node_modules/merge2": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", - "dev": true + "dev": true, + "engines": { + "node": ">= 8" + } }, - "micromatch": { + "node_modules/micromatch": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.2.tgz", "integrity": "sha512-y7FpHSbMUMoyPbYUSzO6PaZ6FyRnQOpHuKwbo1G+Knck95XVU4QAiKdGEnj5wwoS7PlOgthX/09u5iFJ+aYf5Q==", "dev": true, - "requires": { + "dependencies": { "braces": "^3.0.1", "picomatch": "^2.0.5" + }, + "engines": { + "node": ">=8" } }, - "nanoid": { + "node_modules/nanoid": { "version": "3.3.2", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.2.tgz", - "integrity": "sha512-CuHBogktKwpm5g2sRgv83jEy2ijFzBwMoYA60orPDR7ynsLijJDqgsi4RDGj3OJpy3Ieb+LYwiRmIOGyytgITA==" + "integrity": "sha512-CuHBogktKwpm5g2sRgv83jEy2ijFzBwMoYA60orPDR7ynsLijJDqgsi4RDGj3OJpy3Ieb+LYwiRmIOGyytgITA==", + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } }, - "node-releases": { + "node_modules/node-releases": { "version": "1.1.72", "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.72.tgz", - "integrity": "sha512-LLUo+PpH3dU6XizX3iVoubUNheF/owjXCZZ5yACDxNnPtgFuludV1ZL3ayK1kVep42Rmm0+R9/Y60NQbZ2bifw==" + "integrity": "sha512-LLUo+PpH3dU6XizX3iVoubUNheF/owjXCZZ5yACDxNnPtgFuludV1ZL3ayK1kVep42Rmm0+R9/Y60NQbZ2bifw==", + "dev": true }, - "normalize-path": { + "node_modules/normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "dev": true + "dev": true, + "engines": { + "node": ">=0.10.0" + } }, - "normalize-range": { + "node_modules/normalize-range": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/normalize-range/-/normalize-range-0.1.2.tgz", - "integrity": "sha1-LRDAa9/TEuqXd2laTShDlFa3WUI=" + "integrity": "sha1-LRDAa9/TEuqXd2laTShDlFa3WUI=", + "dev": true, + "engines": { + "node": ">=0.10.0" + } }, - "parent-module": { + "node_modules/parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", "dev": true, - "requires": { + "dependencies": { "callsites": "^3.0.0" + }, + "engines": { + "node": ">=6" } }, - "parse-json": { + "node_modules/parse-json": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", "dev": true, - "requires": { + "dependencies": { "@babel/code-frame": "^7.0.0", "error-ex": "^1.3.1", "json-parse-even-better-errors": "^2.3.0", "lines-and-columns": "^1.1.6" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "path-type": { + "node_modules/path-type": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", - "dev": true + "dev": true, + "engines": { + "node": ">=8" + } }, - "picomatch": { + "node_modules/picomatch": { "version": "2.2.2", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", - "dev": true + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } }, - "pify": { + "node_modules/pify": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=", - "dev": true + "dev": true, + "engines": { + "node": ">=0.10.0" + } }, - "postcss": { + "node_modules/postcss": { "version": "8.3.0", "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.3.0.tgz", "integrity": "sha512-+ogXpdAjWGa+fdYY5BQ96V/6tAo+TdSSIMP5huJBIygdWwKtVoB5JWZ7yUd4xZ8r+8Kvvx4nyg/PQ071H4UtcQ==", - "requires": { + "dependencies": { "colorette": "^1.2.2", "nanoid": "^3.1.23", "source-map-js": "^0.6.2" + }, + "engines": { + "node": "^10 || ^12 || >=14" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" } }, - "postcss-cli": { + "node_modules/postcss-cli": { "version": "8.3.1", "resolved": "https://registry.npmjs.org/postcss-cli/-/postcss-cli-8.3.1.tgz", "integrity": "sha512-leHXsQRq89S3JC9zw/tKyiVV2jAhnfQe0J8VI4eQQbUjwIe0XxVqLrR+7UsahF1s9wi4GlqP6SJ8ydf44cgF2Q==", "dev": true, - "requires": { + "dependencies": { "chalk": "^4.0.0", "chokidar": "^3.3.0", "dependency-graph": "^0.9.0", @@ -623,246 +850,348 @@ "slash": "^3.0.0", "yargs": "^16.0.0" }, - "dependencies": { - "ansi-styles": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", - "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", - "dev": true, - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", - "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } + "bin": { + "postcss": "bin/postcss" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "postcss": "^8.0.0" } }, - "postcss-load-config": { + "node_modules/postcss-cli/node_modules/ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", + "dev": true, + "dependencies": { + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/postcss-cli/node_modules/chalk": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/postcss-cli/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/postcss-cli/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/postcss-cli/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/postcss-cli/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/postcss-load-config": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/postcss-load-config/-/postcss-load-config-3.0.1.tgz", "integrity": "sha512-/pDHe30UYZUD11IeG8GWx9lNtu1ToyTsZHnyy45B4Mrwr/Kb6NgYl7k753+05CJNKnjbwh4975amoPJ+TEjHNQ==", "dev": true, - "requires": { + "dependencies": { "cosmiconfig": "^7.0.0", "import-cwd": "^3.0.0" + }, + "engines": { + "node": ">= 10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" } }, - "postcss-reporter": { + "node_modules/postcss-reporter": { "version": "7.0.2", "resolved": "https://registry.npmjs.org/postcss-reporter/-/postcss-reporter-7.0.2.tgz", "integrity": "sha512-JyQ96NTQQsso42y6L1H1RqHfWH1C3Jr0pt91mVv5IdYddZAE9DUZxuferNgk6q0o6vBVOrfVJb10X1FgDzjmDw==", "dev": true, - "requires": { + "dependencies": { "colorette": "^1.2.1", "lodash.difference": "^4.5.0", "lodash.forown": "^4.4.0", "lodash.get": "^4.4.2", "lodash.groupby": "^4.6.0", "lodash.sortby": "^4.7.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + "peerDependencies": { + "postcss": "^8.1.0" } }, - "postcss-value-parser": { + "node_modules/postcss-value-parser": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.1.0.tgz", - "integrity": "sha512-97DXOFbQJhk71ne5/Mt6cOu6yxsSfM0QGQyl0L25Gca4yGWEGJaig7l7gbCX623VqTBNGLRLaVUCnNkcedlRSQ==" + "integrity": "sha512-97DXOFbQJhk71ne5/Mt6cOu6yxsSfM0QGQyl0L25Gca4yGWEGJaig7l7gbCX623VqTBNGLRLaVUCnNkcedlRSQ==", + "dev": true }, - "pretty-hrtime": { + "node_modules/pretty-hrtime": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz", "integrity": "sha1-t+PqQkNaTJsnWdmeDyAesZWALuE=", - "dev": true + "dev": true, + "engines": { + "node": ">= 0.8" + } }, - "read-cache": { + "node_modules/read-cache": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/read-cache/-/read-cache-1.0.0.tgz", "integrity": "sha1-5mTvMRYRZsl1HNvo28+GtftY93Q=", "dev": true, - "requires": { + "dependencies": { "pify": "^2.3.0" } }, - "readdirp": { + "node_modules/readdirp": { "version": "3.4.0", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", "dev": true, - "requires": { + "dependencies": { "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" } }, - "require-directory": { + "node_modules/require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", - "dev": true + "dev": true, + "engines": { + "node": ">=0.10.0" + } }, - "resolve-from": { + "node_modules/resolve-from": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", - "dev": true + "dev": true, + "engines": { + "node": ">=4" + } }, - "reusify": { + "node_modules/reusify": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", - "dev": true + "dev": true, + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } }, - "run-parallel": { + "node_modules/run-parallel": { "version": "1.1.9", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.1.9.tgz", "integrity": "sha512-DEqnSRTDw/Tc3FXf49zedI638Z9onwUotBMiUFKmrO2sdFKIbXamXGQ3Axd4qgphxKB4kw/qP1w5kTxnfU1B9Q==", "dev": true }, - "slash": { + "node_modules/slash": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", - "dev": true + "dev": true, + "engines": { + "node": ">=8" + } }, - "source-map-js": { + "node_modules/source-map-js": { "version": "0.6.2", "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-0.6.2.tgz", - "integrity": "sha512-/3GptzWzu0+0MBQFrDKzw/DvvMTUORvgY6k6jd/VS6iCR4RDTKWH6v6WPwQoUO8667uQEf9Oe38DxAYWY5F/Ug==" + "integrity": "sha512-/3GptzWzu0+0MBQFrDKzw/DvvMTUORvgY6k6jd/VS6iCR4RDTKWH6v6WPwQoUO8667uQEf9Oe38DxAYWY5F/Ug==", + "engines": { + "node": ">=0.10.0" + } }, - "string-width": { + "node_modules/string-width": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.2.tgz", "integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==", "dev": true, - "requires": { + "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=8" } }, - "strip-ansi": { + "node_modules/strip-ansi": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", "dev": true, - "requires": { + "dependencies": { "ansi-regex": "^5.0.0" + }, + "engines": { + "node": ">=8" } }, - "supports-color": { + "node_modules/supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, - "requires": { + "dependencies": { "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" } }, - "to-regex-range": { + "node_modules/to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "dev": true, - "requires": { + "dependencies": { "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" } }, - "universalify": { + "node_modules/universalify": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/universalify/-/universalify-1.0.0.tgz", "integrity": "sha512-rb6X1W158d7pRQBg5gkR8uPaSfiids68LTJQYOtEUhoJUWBdaQHsuT/EUduxXYxcrt4r5PJ4fuHW1MHT6p0qug==", - "dev": true + "dev": true, + "engines": { + "node": ">= 10.0.0" + } }, - "wrap-ansi": { + "node_modules/wrap-ansi": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", "dev": true, - "requires": { + "dependencies": { "ansi-styles": "^4.0.0", "string-width": "^4.1.0", "strip-ansi": "^6.0.0" }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - } + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "y18n": { + "node_modules/wrap-ansi/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/wrap-ansi/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", - "dev": true + "dev": true, + "engines": { + "node": ">=10" + } }, - "yaml": { + "node_modules/yaml": { "version": "1.10.2", "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", - "dev": true + "dev": true, + "engines": { + "node": ">= 6" + } }, - "yargs": { + "node_modules/yargs": { "version": "16.2.0", "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", "dev": true, - "requires": { + "dependencies": { "cliui": "^7.0.2", "escalade": "^3.1.1", "get-caller-file": "^2.0.5", @@ -870,13 +1199,19 @@ "string-width": "^4.2.0", "y18n": "^5.0.5", "yargs-parser": "^20.2.2" + }, + "engines": { + "node": ">=10" } }, - "yargs-parser": { + "node_modules/yargs-parser": { "version": "20.2.7", "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.7.tgz", "integrity": "sha512-FiNkvbeHzB/syOjIUxFDCnhSfzAL8R5vs40MgLFBorXACCOAEaWu0gRZl14vG8MR9AOJIZbmkjhusqBYZ3HTHw==", - "dev": true + "dev": true, + "engines": { + "node": ">=10" + } } } -} \ No newline at end of file +} From a547209996fc797853de2018d57b104f747cb79c Mon Sep 17 00:00:00 2001 From: Roberto Rojas Date: Tue, 31 Jan 2023 15:11:35 -0500 Subject: [PATCH 19/25] [1.10][AWS SNS/SQS] PubSub Component to Stable (#3095) * marks aws snssqs state store component as stable Signed-off-by: Roberto J Rojas * updates pubsub sqs component docs Signed-off-by: Roberto J Rojas --------- Signed-off-by: Roberto J Rojas --- .../supported-pubsub/setup-aws-snssqs.md | 7 +++++++ daprdocs/data/components/pubsub/aws.yaml | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-aws-snssqs.md b/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-aws-snssqs.md index 06f540d8b..f0332f086 100644 --- a/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-aws-snssqs.md +++ b/daprdocs/content/en/reference/components-reference/supported-pubsub/setup-aws-snssqs.md @@ -105,14 +105,21 @@ Using SQS FIFO (`fifo` metadata field set to `"true"`) per AWS specifications pr Specifying `fifoMessageGroupID` limits the number of concurrent consumers of the FIFO queue used to only one but guarantees global ordering of messages published by the app's Dapr sidecars. See [this AWS blog post](https://aws.amazon.com/blogs/compute/solving-complex-ordering-challenges-with-amazon-sqs-fifo-queues/) to better understand the topic of Message Group IDs and FIFO queues. +To avoid losing the order of messages delivered to consumers, the FIFO configuration for the SQS Component requires the `concurrencyMode` metadata field set to `"single"`. + #### Default parallel `concurrencyMode` Since v1.8.0, the component supports the `"parallel"` `concurrencyMode` as its default mode. In prior versions, the component default behavior was calling the subscriber a single message at a time and waiting for its response. +#### SQS dead-letter Queues + +When configuring the PubSub component with SQS dead-letter queues, the metadata fields `messageReceiveLimit` and `sqsDeadLettersQueueName` must both be set to a value. For `messageReceiveLimit`, the value must be greater than `0` and the `sqsDeadLettersQueueName` must not be empty string. + {{% alert title="Important" color="warning" %}} When running the Dapr sidecar (`daprd`) with your application on EKS (AWS Kubernetes) node/pod already attached to an IAM policy defining access to AWS resources, you **must not** provide AWS access-key, secret-key, and tokens in the definition of the component spec. {{% /alert %}} + ## Create an SNS/SQS instance {{< tabs "Self-Hosted" "Kubernetes" "AWS" >}} diff --git a/daprdocs/data/components/pubsub/aws.yaml b/daprdocs/data/components/pubsub/aws.yaml index fa5328ab9..682428c38 100644 --- a/daprdocs/data/components/pubsub/aws.yaml +++ b/daprdocs/data/components/pubsub/aws.yaml @@ -1,5 +1,5 @@ - component: AWS SNS/SQS link: setup-aws-snssqs - state: Beta + state: Stable version: v1 - since: "1.6" + since: "1.10" From 64f1ccbbf9edd4947f1c107d39a15df01ccb9c51 Mon Sep 17 00:00:00 2001 From: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> Date: Wed, 1 Feb 2023 11:01:13 -0800 Subject: [PATCH 20/25] Document that --app-id cannot contain dots in self-hosted mode Fixes #2969 Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> --- .../content/en/concepts/dapr-services/sidecar.md | 9 +++++++-- daprdocs/content/en/reference/cli/dapr-run.md | 12 ++++++------ 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/daprdocs/content/en/concepts/dapr-services/sidecar.md b/daprdocs/content/en/concepts/dapr-services/sidecar.md index 473f001c9..0f553c497 100644 --- a/daprdocs/content/en/concepts/dapr-services/sidecar.md +++ b/daprdocs/content/en/concepts/dapr-services/sidecar.md @@ -23,7 +23,11 @@ The sidecar APIs are called from your application over local http or gRPC endpoi ## Self-hosted with `dapr run` -When Dapr is installed in [self-hosted mode]({{}}), the `daprd` binary is downloaded and placed under the user home directory (`$HOME/.dapr/bin` for Linux/MacOS or `%USERPROFILE%\.dapr\bin\` for Windows). In self-hosted mode, running the Dapr CLI [`run` command]({{< ref dapr-run.md >}}) launches the `daprd` executable together with the provided application executable. This is the recommended way of running the Dapr sidecar when working locally in scenarios such as development and testing. The various arguments the CLI exposes to configure the sidecar can be found in the [Dapr run command reference]({{}}). +When Dapr is installed in [self-hosted mode]({{}}), the `daprd` binary is downloaded and placed under the user home directory (`$HOME/.dapr/bin` for Linux/macOS or `%USERPROFILE%\.dapr\bin\` for Windows). + +In self-hosted mode, running the Dapr CLI [`run` command]({{< ref dapr-run.md >}}) launches the `daprd` executable together with the provided application executable. This is the recommended way of running the Dapr sidecar when working locally in scenarios such as development and testing. + +The various arguments the CLI exposes to configure the sidecar can be found in the [Dapr run command reference]({{}}). ## Kubernetes with `dapr-sidecar-injector` @@ -37,7 +41,8 @@ For a detailed list of all available arguments run `daprd --help` or see this [t ### Examples -1. Start a sidecar along with an application by specifying its unique ID. Note `--app-id` is a required field: +1. Start a sidecar along with an application by specifying its unique ID. + Note `--app-id` is a required field, and cannot contain dots: ```bash daprd --app-id myapp diff --git a/daprdocs/content/en/reference/cli/dapr-run.md b/daprdocs/content/en/reference/cli/dapr-run.md index 995211012..9e0cf642f 100644 --- a/daprdocs/content/en/reference/cli/dapr-run.md +++ b/daprdocs/content/en/reference/cli/dapr-run.md @@ -23,18 +23,17 @@ dapr run [flags] [command] | Name | Environment Variable | Default | Description | | ------------------------------ | -------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | -| `--app-id`, `-a` | `APP_ID` | | The id for your application, used for service discovery | -| `--app-max-concurrency` | | `unlimited` | The concurrency level of the application; default is unlimited | +| `--app-id`, `-a` | `APP_ID` | | The id for your application, used for service discovery. Cannot contain dots. | +| `--app-max-concurrency` | | `unlimited` | The concurrency level of the application; default is unlimited | | `--app-port`, `-p` | `APP_PORT` | | The port your application is listening on | | `--app-protocol`, `-P` | | `http` | The protocol Dapr uses to talk to the application. Valid values are: `http` or `grpc` | | `--app-ssl` | | `false` | Enable https when Dapr invokes the application | -| `--components-path`, `-d` | | Linux/Mac: `$HOME/.dapr/components`
Windows: `%USERPROFILE%\.dapr\components` | **Deprecated** in favor of `--resources-path` | -| `--resources-path`, `-d` | | Linux/Mac: `$HOME/.dapr/components`
Windows: `%USERPROFILE%\.dapr\components` | The path for components directory | +| `--resources-path`, `-d` | | Linux/Mac: `$HOME/.dapr/components`
Windows: `%USERPROFILE%\.dapr\components` | The path for components directory | | `--config`, `-c` | | Linux/Mac: `$HOME/.dapr/config.yaml`
Windows: `%USERPROFILE%\.dapr\config.yaml` | Dapr configuration file | | `--dapr-grpc-port` | `DAPR_GRPC_PORT` | `50001` | The gRPC port for Dapr to listen on | | `--dapr-http-port` | `DAPR_HTTP_PORT` | `3500` | The HTTP port for Dapr to listen on | | `--enable-profiling` | | `false` | Enable "pprof" profiling via an HTTP endpoint | -| `--help`, `-h` | | | Print the help message | +| `--help`, `-h` | | | Print the help message | | `--image` | | | Use a custom Docker image. Format is `repository/image` for Docker Hub, or `example.com/repository/image` for a custom registry. | | `--log-level` | | `info` | The log verbosity. Valid values are: `debug`, `info`, `warn`, `error`, `fatal`, or `panic` | | `--enable-api-logging` | | `false` | Enable the logging of all API calls from application to Dapr | @@ -46,8 +45,9 @@ dapr run [flags] [command] | `--app-health-probe-timeout` | | | Timeout for app health probes in milliseconds | | `--app-health-threshold` | | | Number of consecutive failures for the app to be considered unhealthy | | `--unix-domain-socket`, `-u` | | | Path to a unix domain socket dir mount. If specified, communication with the Dapr sidecar uses unix domain sockets for lower latency and greater throughput when compared to using TCP ports. Not available on Windows. | -| `--dapr-http-max-request-size` | | `4` | Max size of the request body in MB. | +| `--dapr-http-max-request-size` | | `4` | Max size of the request body in MB. | | `--dapr-http-read-buffer-size` | | `4` | Max size of the HTTP read buffer in KB. This also limits the maximum size of HTTP headers. The default 4 KB | +| `--components-path`, `-d` | | Linux/Mac: `$HOME/.dapr/components`
Windows: `%USERPROFILE%\.dapr\components` | **Deprecated** in favor of `--resources-path` | ### Examples From 8d17f5f4dd0c464e1c173974c916874d1709c45a Mon Sep 17 00:00:00 2001 From: Hannah Hunter <94493363+hhunter-ms@users.noreply.github.com> Date: Wed, 1 Feb 2023 13:10:16 -0600 Subject: [PATCH 21/25] update code sample to mark suggestion in issue (#3090) Signed-off-by: Hannah Hunter --- .../howto-invoke-discover-services.md | 37 +++++++++---------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/daprdocs/content/en/developing-applications/building-blocks/service-invocation/howto-invoke-discover-services.md b/daprdocs/content/en/developing-applications/building-blocks/service-invocation/howto-invoke-discover-services.md index e73456d4b..183b537f6 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/service-invocation/howto-invoke-discover-services.md +++ b/daprdocs/content/en/developing-applications/building-blocks/service-invocation/howto-invoke-discover-services.md @@ -191,25 +191,24 @@ using System.Threading; //code namespace EventService { - class Program - { - static async Task Main(string[] args) - { - while(true) { - System.Threading.Thread.Sleep(5000); - Random random = new Random(); - int orderId = random.Next(1,1000); - CancellationTokenSource source = new CancellationTokenSource(); - CancellationToken cancellationToken = source.Token; - using var client = new DaprClientBuilder().Build(); - //Using Dapr SDK to invoke a method - var result = client.CreateInvokeMethodRequest(HttpMethod.Get, "checkout", "checkout/" + orderId, cancellationToken); - await client.InvokeMethodAsync(result); - Console.WriteLine("Order requested: " + orderId); - Console.WriteLine("Result: " + result); - } - } - } + class Program + { + static async Task Main(string[] args) + { + while(true) { + System.Threading.Thread.Sleep(5000); + Random random = new Random(); + int orderId = random.Next(1,1000); + using var client = new DaprClientBuilder().Build(); + + //Using Dapr SDK to invoke a method + var result = client.CreateInvokeMethodRequest(HttpMethod.Get, "checkout", "checkout/" + orderId); + await client.InvokeMethodAsync(result); + Console.WriteLine("Order requested: " + orderId); + Console.WriteLine("Result: " + result); + } + } + } } ``` From 62daf817faa144db36472f182fc8c850f0eeda82 Mon Sep 17 00:00:00 2001 From: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> Date: Wed, 1 Feb 2023 11:24:00 -0800 Subject: [PATCH 22/25] Updated stable / beta components Some components had certification tests but were not marked as stable. Likewise, some components had conformance tests but were not marked as beta. Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> --- daprdocs/data/components/bindings/generic.yaml | 4 ++-- daprdocs/data/components/pubsub/generic.yaml | 16 ++++++++-------- daprdocs/data/components/state_stores/azure.yaml | 4 ++-- .../data/components/state_stores/generic.yaml | 10 +++++----- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/daprdocs/data/components/bindings/generic.yaml b/daprdocs/data/components/bindings/generic.yaml index c093d9bb2..aed6acdb5 100644 --- a/daprdocs/data/components/bindings/generic.yaml +++ b/daprdocs/data/components/bindings/generic.yaml @@ -96,9 +96,9 @@ output: true - component: Redis link: redis - state: Beta + state: Stable version: v1 - since: "1.7" + since: "1.9" features: input: false output: true diff --git a/daprdocs/data/components/pubsub/generic.yaml b/daprdocs/data/components/pubsub/generic.yaml index 6978dc7dd..ce5ed8f34 100644 --- a/daprdocs/data/components/pubsub/generic.yaml +++ b/daprdocs/data/components/pubsub/generic.yaml @@ -3,7 +3,7 @@ state: Deprecated version: v1 since: "1.9" -- component: In Memory +- component: In-memory link: setup-inmemory state: Beta version: v1 @@ -20,14 +20,14 @@ since: "1.0" - component: JetStream link: setup-jetstream - state: Alpha - version: v1 - since: "1.4" -- component: Pulsar - link: setup-pulsar state: Beta version: v1 - since: "1.7" + since: "1.10" +- component: Pulsar + link: setup-pulsar + state: Stable + version: v1 + since: "1.10" - component: MQTT3 link: setup-mqtt3 state: Stable @@ -50,6 +50,6 @@ since: "1.8" - component: Solace-AMQP link: setup-solace-amqp - state: Alpha + state: Beta version: v1 since: "1.10" diff --git a/daprdocs/data/components/state_stores/azure.yaml b/daprdocs/data/components/state_stores/azure.yaml index 1825cb726..e05757dbe 100644 --- a/daprdocs/data/components/state_stores/azure.yaml +++ b/daprdocs/data/components/state_stores/azure.yaml @@ -33,9 +33,9 @@ query: false - component: Azure Table Storage link: setup-azure-tablestorage - state: Beta + state: Stable version: v1 - since: "1.7" + since: "1.9" features: crud: true transactions: false diff --git a/daprdocs/data/components/state_stores/generic.yaml b/daprdocs/data/components/state_stores/generic.yaml index 6959e0aea..5f8506cae 100644 --- a/daprdocs/data/components/state_stores/generic.yaml +++ b/daprdocs/data/components/state_stores/generic.yaml @@ -22,9 +22,9 @@ query: false - component: CockroachDB link: setup-cockroachdb - state: Beta + state: Stable version: v1 - since: "1.7" + since: "1.10" features: crud: true transactions: true @@ -64,7 +64,7 @@ etag: false ttl: false query: false -- component: In Memory +- component: In-memory link: setup-inmemory state: Developer-only version: v1 @@ -110,9 +110,9 @@ query: true - component: MySQL link: setup-mysql - state: Beta + state: Stable version: v1 - since: "1.7" + since: "1.10" features: crud: true transactions: true From 492751f66f787b04afca3f428f94edef8f5aeb4d Mon Sep 17 00:00:00 2001 From: Yaron Schneider Date: Wed, 1 Feb 2023 17:27:39 -0800 Subject: [PATCH 23/25] add security token for http binding (#3109) Signed-off-by: yaron2 --- .../supported-bindings/http.md | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/daprdocs/content/en/reference/components-reference/supported-bindings/http.md b/daprdocs/content/en/reference/components-reference/supported-bindings/http.md index 4d71f6ae6..bc2184073 100644 --- a/daprdocs/content/en/reference/components-reference/supported-bindings/http.md +++ b/daprdocs/content/en/reference/components-reference/supported-bindings/http.md @@ -21,12 +21,17 @@ spec: - name: url value: http://something.com - name: MTLSRootCA - value: /Users/somepath/root.pem # or + value: /Users/somepath/root.pem # OPTIONAL or - name: MTLSClientCert - value: /Users/somepath/client.pem # or + value: /Users/somepath/client.pem # OPTIONAL or - name: MTLSClientKey - value: /Users/somepath/client.key # or - + value: /Users/somepath/client.key # OPTIONAL or + - name: securityToken # OPTIONAL + secretKeyRef: + name: mysecret + key: mytoken + - name: securityTokenHeader + value: "Authorization: Bearer" # OPTIONAL
``` ## Spec metadata fields @@ -37,6 +42,8 @@ spec: | MTLSRootCA | N | Output |Path to root ca certificate or pem encoded string | | MTLSClientCert | N | Output |Path to client certificate or pem encoded string | | MTLSClientKey | N | Output |Path client private key or pem encoded string | +| securityToken | N | Output |The value of a token to be added to an HTTP request as a header. Used together with `securityTokenHeader` | +| securityTokenHeader| N | Output |The name of the header for `securityToken` on an HTTP request that | ## Binding support From d470cd315b749e41246e7056c50fa6fab6e9c728 Mon Sep 17 00:00:00 2001 From: "Alessandro (Ale) Segala" <43508+ItalyPaleAle@users.noreply.github.com> Date: Thu, 2 Feb 2023 09:09:55 -0800 Subject: [PATCH 24/25] Apply suggestions from code review Co-authored-by: Hannah Hunter <94493363+hhunter-ms@users.noreply.github.com> Signed-off-by: Alessandro (Ale) Segala <43508+ItalyPaleAle@users.noreply.github.com> --- daprdocs/content/en/concepts/dapr-services/sidecar.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/daprdocs/content/en/concepts/dapr-services/sidecar.md b/daprdocs/content/en/concepts/dapr-services/sidecar.md index 0f553c497..4f18dce09 100644 --- a/daprdocs/content/en/concepts/dapr-services/sidecar.md +++ b/daprdocs/content/en/concepts/dapr-services/sidecar.md @@ -25,9 +25,9 @@ The sidecar APIs are called from your application over local http or gRPC endpoi When Dapr is installed in [self-hosted mode]({{}}), the `daprd` binary is downloaded and placed under the user home directory (`$HOME/.dapr/bin` for Linux/macOS or `%USERPROFILE%\.dapr\bin\` for Windows). -In self-hosted mode, running the Dapr CLI [`run` command]({{< ref dapr-run.md >}}) launches the `daprd` executable together with the provided application executable. This is the recommended way of running the Dapr sidecar when working locally in scenarios such as development and testing. +In self-hosted mode, running the Dapr CLI [`run` command]({{< ref dapr-run.md >}}) launches the `daprd` executable with the provided application executable. This is the recommended way of running the Dapr sidecar when working locally in scenarios such as development and testing. -The various arguments the CLI exposes to configure the sidecar can be found in the [Dapr run command reference]({{}}). +You can find the various arguments that the CLI exposes to configure the sidecar in the [Dapr run command reference]({{}}). ## Kubernetes with `dapr-sidecar-injector` From 42e8c1f335d04a4ba9d9188bc2272ecc5743db49 Mon Sep 17 00:00:00 2001 From: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> Date: Thu, 2 Feb 2023 09:19:45 -0800 Subject: [PATCH 25/25] Updated per feedback Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com> --- daprdocs/content/en/concepts/dapr-services/sidecar.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/daprdocs/content/en/concepts/dapr-services/sidecar.md b/daprdocs/content/en/concepts/dapr-services/sidecar.md index 4f18dce09..77997387a 100644 --- a/daprdocs/content/en/concepts/dapr-services/sidecar.md +++ b/daprdocs/content/en/concepts/dapr-services/sidecar.md @@ -41,8 +41,9 @@ For a detailed list of all available arguments run `daprd --help` or see this [t ### Examples -1. Start a sidecar along with an application by specifying its unique ID. - Note `--app-id` is a required field, and cannot contain dots: +1. Start a sidecar alongside an application by specifying its unique ID. + + **Note:** `--app-id` is a required field, and cannot contain dots. ```bash daprd --app-id myapp
ComponentBulk PublishBulk Subscribe Status Component version Since runtime version{{ .component }} {{ if .features.bulkPublish }}✅{{else}}{{ end }}{{ if .features.bulkSubscribe }}✅{{else}}{{ end }} {{ .state }} {{ .version }} {{ .since }}