diff --git a/daprdocs/content/en/developing-applications/building-blocks/actors/actors-features-concepts.md b/daprdocs/content/en/developing-applications/building-blocks/actors/actors-features-concepts.md index a9e82c287b2..e486b3243ec 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/actors/actors-features-concepts.md +++ b/daprdocs/content/en/developing-applications/building-blocks/actors/actors-features-concepts.md @@ -14,7 +14,9 @@ Now that you've learned about the [actor building block]({{< ref "actors-overvie Dapr actors are virtual, meaning that their lifetime is not tied to their in-memory representation. As a result, they do not need to be explicitly created or destroyed. The Dapr actor runtime automatically activates an actor the first time it receives a request for that actor ID. If an actor is not used for a period of time, the Dapr actor runtime garbage-collects the in-memory object. It will also maintain knowledge of the actor's existence should it need to be reactivated later. -Invocation of actor methods and reminders reset the idle time, e.g. reminder firing will keep the actor active. Actor reminders fire whether an actor is active or inactive, if fired for inactive actor, it will activate the actor first. Actor timers do not reset the idle time, so timer firing will not keep the actor active. Timers only fire while the actor is active. +Invocation of actor methods, timers, and reminders reset the actor idle time. For example, a reminder firing keeps the actor active. +- Actor reminders fire whether an actor is active or inactive. If fired for an inactive actor, it activates the actor first. +- Actor timers firing reset the idle time; however, timers only fire while the actor is active. The idle timeout and scan interval Dapr runtime uses to see if an actor can be garbage-collected is configurable. This information can be passed when Dapr runtime calls into the actor service to get supported actor types. diff --git a/daprdocs/content/en/developing-applications/building-blocks/workflow/workflow-patterns.md b/daprdocs/content/en/developing-applications/building-blocks/workflow/workflow-patterns.md index c7aebca4e9e..3caeddad25f 100644 --- a/daprdocs/content/en/developing-applications/building-blocks/workflow/workflow-patterns.md +++ b/daprdocs/content/en/developing-applications/building-blocks/workflow/workflow-patterns.md @@ -496,9 +496,8 @@ public class MonitorWorkflow extends Workflow { } // Put the workflow to sleep until the determined time - // Note: ctx.createTimer() method is not supported in the Java SDK yet try { - TimeUnit.SECONDS.sleep(nextSleepInterval.getSeconds()); + ctx.createTimer(nextSleepInterval); } catch (InterruptedException e) { throw new RuntimeException(e); } @@ -745,4 +744,4 @@ External events don't have to be directly triggered by humans. They can also be - Try out the following examples: - [Python](https://github.com/dapr/python-sdk/tree/master/examples/demo_workflow) - [.NET](https://github.com/dapr/dotnet-sdk/tree/master/examples/Workflow) - - [Java](https://github.com/dapr/java-sdk/tree/master/examples/src/main/java/io/dapr/examples/workflows) \ No newline at end of file + - [Java](https://github.com/dapr/java-sdk/tree/master/examples/src/main/java/io/dapr/examples/workflows) diff --git a/daprdocs/content/en/getting-started/install-dapr-selfhost.md b/daprdocs/content/en/getting-started/install-dapr-selfhost.md index 135c1458746..55168bb1898 100644 --- a/daprdocs/content/en/getting-started/install-dapr-selfhost.md +++ b/daprdocs/content/en/getting-started/install-dapr-selfhost.md @@ -23,9 +23,9 @@ Dapr initialization includes: 1. Running a **Dapr placement service container instance** for local actor support. {{% alert title="Docker" color="primary" %}} -The recommended development environment requires [Docker](https://docs.docker.com/install/). While you can [initialize Dapr without a dependency on Docker]({{}})), the next steps in this guide assume the recommended Docker development environment. +The recommended development environment requires [Docker](https://docs.docker.com/install/). While you can [initialize Dapr without a dependency on Docker]({{< ref self-hosted-no-docker.md >}})), the next steps in this guide assume the recommended Docker development environment. -You can also install [Podman](https://podman.io/) in place of Docker. Read more about [initializing Dapr using Podman]({{}}). +You can also install [Podman](https://podman.io/) in place of Docker. Read more about [initializing Dapr using Podman]({{< ref dapr-init.md >}}). {{% /alert %}} ### Step 1: Open an elevated terminal @@ -54,12 +54,35 @@ Run Windows Terminal or command prompt as administrator. ### Step 2: Run the init CLI command +{{< tabs "Linux/MacOS" "Windows">}} + +{{% codetab %}} + +Install the latest Dapr runtime binaries: + +```bash +dapr init +``` + +**If you are installing on Mac OS Silicon with Docker,** you may need to perform the following workaround to enable `dapr init` to talk to Docker without using Kubernetes. +1. Navigate to **Docker Desktop** > **Settings** > **Advanced**. +1. Select the **Enable default Docker socket** checkbox. + +{{% /codetab %}} + +{{% codetab %}} + Install the latest Dapr runtime binaries: ```bash dapr init ``` +{{% /codetab %}} + +{{< /tabs >}} + + ### Step 3: Verify Dapr version ```bash diff --git a/daprdocs/content/en/getting-started/quickstarts/pubsub-quickstart.md b/daprdocs/content/en/getting-started/quickstarts/pubsub-quickstart.md index 63ba887755d..3b459afebfd 100644 --- a/daprdocs/content/en/getting-started/quickstarts/pubsub-quickstart.md +++ b/daprdocs/content/en/getting-started/quickstarts/pubsub-quickstart.md @@ -51,6 +51,20 @@ From the root of the Quickstarts directory, navigate into the pub/sub directory: cd pub_sub/python/sdk ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./checkout +pip3 install -r requirements.txt +cd .. +cd ./order-processor +pip3 install -r requirements.txt +cd .. +cd ./order-processor-fastapi +pip3 install -r requirements.txt +cd .. +``` + ### Step 3: Run the publisher and subscriber With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -215,6 +229,17 @@ From the root of the Quickstarts directory, navigate into the pub/sub directory: cd pub_sub/javascript/sdk ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +npm install +cd .. +cd ./checkout +npm install +cd .. +``` + ### Step 3: Run the publisher and subscriber With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -352,6 +377,18 @@ From the root of the Quickstarts directory, navigate into the pub/sub directory: cd pub_sub/csharp/sdk ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +dotnet restore +dotnet build +cd ../checkout +dotnet restore +dotnet build +cd .. +``` + ### Step 3: Run the publisher and subscriber With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -497,6 +534,17 @@ From the root of the Quickstarts directory, navigate into the pub/sub directory: cd pub_sub/java/sdk ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +mvn clean install +cd .. +cd ./checkout +mvn clean install +cd .. +``` + ### Step 3: Run the publisher and subscriber With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -647,6 +695,16 @@ From the root of the Quickstarts directory, navigate into the pub/sub directory: cd pub_sub/go/sdk ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +go build . +cd ../checkout +go build . +cd .. +``` + ### Step 3: Run the publisher and subscriber With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -878,7 +936,7 @@ with DaprClient() as client: ### Step 5: View the Pub/sub outputs -Notice, as specified in the code above, the publisher pushes a random number to the Dapr sidecar while the subscriber receives it. +The publisher sends orders to the Dapr sidecar while the subscriber receives them. Publisher output: diff --git a/daprdocs/content/en/getting-started/quickstarts/serviceinvocation-quickstart.md b/daprdocs/content/en/getting-started/quickstarts/serviceinvocation-quickstart.md index d75e1a7a6e3..0164e35fddf 100644 --- a/daprdocs/content/en/getting-started/quickstarts/serviceinvocation-quickstart.md +++ b/daprdocs/content/en/getting-started/quickstarts/serviceinvocation-quickstart.md @@ -48,6 +48,16 @@ From the root of the Quickstart clone directory, navigate to the quickstart dire cd service_invocation/python/http ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +pip3 install -r requirements.txt +cd ../checkout +pip3 install -r requirements.txt +cd .. +``` + ### Step 3: Run the `order-processor` and `checkout` services With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -184,6 +194,16 @@ From the root of the Quickstart clone directory, navigate to the quickstart dire cd service_invocation/javascript/http ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +npm install +cd ../checkout +npm install +cd .. +``` + ### Step 3: Run the `order-processor` and `checkout` services With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -314,6 +334,18 @@ From the root of the Quickstart clone directory, navigate to the quickstart dire cd service_invocation/csharp/http ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +dotnet restore +dotnet build +cd ../checkout +dotnet restore +dotnet build +cd .. +``` + ### Step 3: Run the `order-processor` and `checkout` services With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -448,6 +480,16 @@ From the root of the Quickstart clone directory, navigate to the quickstart dire cd service_invocation/java/http ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +mvn clean install +cd ../checkout +mvn clean install +cd .. +``` + ### Step 3: Run the `order-processor` and `checkout` services With the following command, simultaneously run the following services alongside their own Dapr sidecars: @@ -577,6 +619,16 @@ From the root of the Quickstart clone directory, navigate to the quickstart dire cd service_invocation/go/http ``` +Install the dependencies for the `order-processor` and `checkout` apps: + +```bash +cd ./order-processor +go build . +cd ../checkout +go build . +cd .. +``` + ### Step 3: Run the `order-processor` and `checkout` services With the following command, simultaneously run the following services alongside their own Dapr sidecars: diff --git a/daprdocs/content/en/getting-started/quickstarts/statemanagement-quickstart.md b/daprdocs/content/en/getting-started/quickstarts/statemanagement-quickstart.md index 26d63ae9826..bfa8427da8c 100644 --- a/daprdocs/content/en/getting-started/quickstarts/statemanagement-quickstart.md +++ b/daprdocs/content/en/getting-started/quickstarts/statemanagement-quickstart.md @@ -48,6 +48,12 @@ In a terminal window, navigate to the `order-processor` directory. cd state_management/python/sdk/order-processor ``` +Install the dependencies: + +```bash +pip3 install -r requirements.txt +``` + Run the `order-processor` service alongside a Dapr sidecar using [Multi-App Run]({{< ref multi-app-dapr-run >}}). ```bash @@ -163,6 +169,14 @@ Clone the [sample provided in the Quickstarts repo](https://github.com/dapr/quic git clone https://github.com/dapr/quickstarts.git ``` +Install the dependencies for the `order-processor` app: + +```bash +cd ./order-processor +npm install +cd .. +``` + ### Step 2: Manipulate service state In a terminal window, navigate to the `order-processor` directory. @@ -171,6 +185,12 @@ In a terminal window, navigate to the `order-processor` directory. cd state_management/javascript/sdk/order-processor ``` +Install the dependencies: + +```bash +npm install +``` + Run the `order-processor` service alongside a Dapr sidecar. ```bash @@ -297,6 +317,13 @@ In a terminal window, navigate to the `order-processor` directory. cd state_management/csharp/sdk/order-processor ``` +Install the dependencies: + +```bash +dotnet restore +dotnet build +``` + Run the `order-processor` service alongside a Dapr sidecar. ```bash @@ -557,6 +584,12 @@ In a terminal window, navigate to the `order-processor` directory. cd state_management/go/sdk/order-processor ``` +Install the dependencies: + +```bash +go build . +``` + Run the `order-processor` service alongside a Dapr sidecar. ```bash diff --git a/daprdocs/content/en/operations/hosting/kubernetes/cluster/setup-kind.md b/daprdocs/content/en/operations/hosting/kubernetes/cluster/setup-kind.md index 00d34d93ac8..d77f27b3073 100644 --- a/daprdocs/content/en/operations/hosting/kubernetes/cluster/setup-kind.md +++ b/daprdocs/content/en/operations/hosting/kubernetes/cluster/setup-kind.md @@ -113,6 +113,43 @@ If you are using Docker Desktop, verify that you have [the recommended settings] 1. Navigate to `http://localhost:9999` to validate a successful setup. +## Install metrics-server on the Kind Kubernetes Cluster + +1. Get metrics-server manifests + + ```bash + wget https://github.com/kubernetes-sigs/metrics-server/releases/latest/download/components.yaml + ``` + +1. Add insecure TLS parameter to the components.yaml file + + ```yaml + metadata: + labels: + k8s-app: metrics-server + spec: + containers: + - args: + - --cert-dir=/tmp + - --secure-port=4443 + - --kubelet-preferred-address-types=InternalIP,ExternalIP,Hostname + - --kubelet-use-node-status-port + - --kubelet-insecure-tls <==== Add this + - --metric-resolution=15s + image: k8s.gcr.io/metrics-server/metrics-server:v0.6.2 + imagePullPolicy: IfNotPresent + livenessProbe: + failureThreshold: 3 + httpGet: + path: /livez + ``` + +1. Apply modified manifest + + ```bash + kubectl apply -f components.yaml + ``` + ## Related links - [Try out a Dapr quickstart]({{< ref quickstarts.md >}}) - Learn how to [deploy Dapr on your cluster]({{< ref kubernetes-deploy.md >}}) diff --git a/daprdocs/content/en/reference/components-reference/supported-bindings/s3.md b/daprdocs/content/en/reference/components-reference/supported-bindings/s3.md index 7e7b93a8ecd..2de9b95a727 100644 --- a/daprdocs/content/en/reference/components-reference/supported-bindings/s3.md +++ b/daprdocs/content/en/reference/components-reference/supported-bindings/s3.md @@ -151,12 +151,12 @@ To use the S3 component, you need to use an existing bucket. Follow the [AWS doc This component supports **output binding** with the following operations: -- `create` : [Create file](#create-file) -- `get` : [Get file](#get-file) -- `delete` : [Delete file](#delete-file) -- `list`: [List file](#list-files) +- `create` : [Create object](#create-object) +- `get` : [Get object](#get-object) +- `delete` : [Delete object](#delete-object) +- `list`: [List objects](#list-objects) -### Create file +### Create object To perform a create operation, invoke the AWS S3 binding with a `POST` method and the following JSON body: diff --git a/sdkdocs/dotnet b/sdkdocs/dotnet index 99d874a2b13..d023a43ba4f 160000 --- a/sdkdocs/dotnet +++ b/sdkdocs/dotnet @@ -1 +1 @@ -Subproject commit 99d874a2b138af020df099a0fc0a09a7d0597fae +Subproject commit d023a43ba4fd4cddb7aa2c0962cf786f01f58c24 diff --git a/sdkdocs/go b/sdkdocs/go index e16e0350a52..a65eddaa4e9 160000 --- a/sdkdocs/go +++ b/sdkdocs/go @@ -1 +1 @@ -Subproject commit e16e0350a52349b5a05138edc0b58e3be78ee753 +Subproject commit a65eddaa4e9217ed5cdf436b3438d2ffd837ba55 diff --git a/sdkdocs/java b/sdkdocs/java index 5e45aa86b81..a9a09ba2acc 160000 --- a/sdkdocs/java +++ b/sdkdocs/java @@ -1 +1 @@ -Subproject commit 5e45aa86b81748bf1e6efdbf7f52c20645a12435 +Subproject commit a9a09ba2acc39bc7e54a5a7092e1c5820818e23c diff --git a/sdkdocs/js b/sdkdocs/js index df7eff281a5..5c2b40ac94b 160000 --- a/sdkdocs/js +++ b/sdkdocs/js @@ -1 +1 @@ -Subproject commit df7eff281a5a1395a7967c658a5707e8dfb2b99e +Subproject commit 5c2b40ac94b50f6a5bdb32008f6a47da69946d95 diff --git a/sdkdocs/python b/sdkdocs/python index 6171b67db60..ef732090e8e 160000 --- a/sdkdocs/python +++ b/sdkdocs/python @@ -1 +1 @@ -Subproject commit 6171b67db60d51704ed8425ae71dda9226bf1255 +Subproject commit ef732090e8e04629ca573d127c5ee187a505aba4