Merge branch 'v1.8' into v1.8

This commit is contained in:
Mark Fussell 2022-06-23 21:54:48 -07:00 committed by GitHub
commit bfea6bd295
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 68 additions and 15 deletions

View File

@ -51,10 +51,11 @@ powershell -Command "iwr -useb https://raw.githubusercontent.com/dapr/cli/master
#### Install without administrative rights
If you do not have admin rights, you can install Dapr to an alternate directory via the `DAPR_INSTALL_DIR` environment variable.
If you do not have admin rights, you can install Dapr to an alternate directory via the `DAPR_INSTALL_DIR` environment variable. The script below creates the directory if it does not exist.
```powershell
$script=iwr -useb https://raw.githubusercontent.com/dapr/cli/master/install/install.ps1; $block=[ScriptBlock]::Create($script); invoke-command -ScriptBlock $block -ArgumentList "", "$HOME/dapr"
$Env:DAPR_INSTALL_DIR = "<your_alt_install_dir_path>"
$script=iwr -useb https://raw.githubusercontent.com/dapr/cli/master/install/install.ps1; $block=[ScriptBlock]::Create($script); invoke-command -ScriptBlock $block -ArgumentList "", "$Env:DAPR_INSTALL_DIR"
```
{{% /codetab %}}
@ -168,4 +169,4 @@ Flags:
Use "dapr [command] --help" for more information about a command.
```
{{< button text="Next step: Initialize Dapr >>" page="install-dapr-selfhost" >}}
{{< button text="Next step: Initialize Dapr >>" page="install-dapr-selfhost" >}}

View File

@ -26,7 +26,8 @@ Hit the ground running with our Dapr quickstarts, complete with code samples aim
| [State Management]({{< ref statemanagement-quickstart.md >}}) | Create stateful applications using the state management API. |
| [Publish and Subscribe]({{< ref pubsub-quickstart.md >}}) | Send and receive messages using the publish and subscribe API. |
| [Secrets Management]({{< ref secrets-quickstart.md >}}) | Retrieve secrets in the application code from a configured secret store using the secrets management API. |
| Bindings | Coming soon. |
| Actors | Coming soon. |
| Observability | Coming soon. |
| Configuration | Coming soon. |
| Bindings | Coming soon. |
| Actors | Coming soon. |
| Observability | Coming soon. |
| Configuration | Coming soon. |
| Distributed Lock | Coming soon. |

View File

@ -64,7 +64,9 @@ For Kubernetes:
{{% /codetab %}}
{{% codetab %}}
<!-- IGNORE_LINKS -->
Verify you have an [Azure subscription](https://azure.microsoft.com/free/).
<!-- END_IGNORE -->
1. Open and log into the [Azure portal](https://ms.portal.azure.com/#create/Microsoft.Cache) to start the Azure Redis Cache creation flow.
1. Fill out the necessary information.

View File

@ -10,12 +10,11 @@ Dapr has a metadata API that returns information about the sidecar allowing runt
## Components
Each loaded component provides its name, type and version and also information about supported features in the form of component capabilities.
These features are available for the [state store]({{< ref supported-state-stores.md >}}), [pub/sub]({{< ref supported-pubsub.md >}}) and [binding]({{< ref supported-bindings.md >}}) component types. The table below shows the component type and the list of capabilities for a given version. This list might grow in future and only represents the capabilities of the loaded components.
These features are available for the [state store]({{< ref supported-state-stores.md >}}) and [binding]({{< ref supported-bindings.md >}}) component types. The table below shows the component type and the list of capabilities for a given version. This list might grow in future and only represents the capabilities of the loaded components.
Component type | Capabilites
---------------| ------------
State Store | ETAG, TRANSACTION, ACTOR, QUERY_API
Pub/Sub | TTL
Binding | INPUT_BINDING, OUTPUT_BINDING
## Attributes

View File

@ -28,7 +28,7 @@ spec:
- name: retain
value: "false"
- name: cleanSession
value: "true"
value: "false"
- name: backOffMaxRetries
value: "0"
```
@ -43,9 +43,9 @@ The above example uses secrets as plain strings. It is recommended to use a secr
|--------------------|:--------:|---------|---------|
| url | Y | Address of the MQTT broker. Can be `secretKeyRef` to use a secret reference. <br> Use the **`tcp://`** URI scheme for non-TLS communication. <br> Use the **`ssl://`** URI scheme for TLS communication. | `"tcp://[username][:password]@host.domain[:port]"`
| consumerID | N | The client ID used to connect to the MQTT broker. Defaults to the Dapr app ID. | `"myMqttClientApp"`
| qos | N | Indicates the Quality of Service Level (QoS) of the message. Defaults to `0`. |`1`
| qos | N | Indicates the Quality of Service Level (QoS) of the message ([more info](https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels/)). Defaults to `1`. |`0`, `1`, `2`
| retain | N | Defines whether the message is saved by the broker as the last known good value for a specified topic. Defaults to `"false"`. | `"true"`, `"false"`
| cleanSession | N | Sets the `clean_session` flag in the connection message to the MQTT broker if `"true"`. Defaults to `"true"`. | `"true"`, `"false"`
| cleanSession | N | Sets the `clean_session` flag in the connection message to the MQTT broker if `"true"` ([more info](http://www.steves-internet-guide.com/mqtt-clean-sessions-example/)). Defaults to `"false"`. | `"true"`, `"false"`
| caCert | Required for using TLS | Certificate Authority (CA) certificate in PEM format for verifying server TLS certificates. | `"-----BEGIN CERTIFICATE-----\n<base64-encoded DER>\n-----END CERTIFICATE-----"`
| clientCert | Required for using TLS | TLS client certificate in PEM format. Must be used with `clientKey`. | `"-----BEGIN CERTIFICATE-----\n<base64-encoded DER>\n-----END CERTIFICATE-----"`
| clientKey | Required for using TLS | TLS client key in PEM format. Must be used with `clientCert`. Can be `secretKeyRef` to use a secret reference. | `"-----BEGIN RSA PRIVATE KEY-----\n<base64-encoded PKCS8>\n-----END RSA PRIVATE KEY-----"`
@ -112,7 +112,7 @@ spec:
- name: retain
value: "false"
- name: cleanSession
value: "false"
value: "true"
- name: backoffMaxRetries
value: "0"
```
@ -121,6 +121,8 @@ spec:
The above example uses secrets as plain strings. It is recommended to use a secret store for the secrets as described [here]({{< ref component-secrets.md >}}).
{{% /alert %}}
Note that in the case, the value of the consumer ID is random every time Dapr restarts, so we are setting `cleanSession` to true as well.
## Create a MQTT broker
{{< tabs "Self-Hosted" "Kubernetes">}}
@ -129,7 +131,7 @@ The above example uses secrets as plain strings. It is recommended to use a secr
You can run a MQTT broker [locally using Docker](https://hub.docker.com/_/eclipse-mosquitto):
```bash
docker run -d -p 1883:1883 -p 9001:9001 --name mqtt eclipse-mosquitto:1.6.9
docker run -d -p 1883:1883 -p 9001:9001 --name mqtt eclipse-mosquitto:1.6
```
You can then interact with the server using the client port: `mqtt://localhost:1883`
@ -157,7 +159,7 @@ spec:
spec:
containers:
- name: mqtt
image: eclipse-mosquitto:1.6.9
image: eclipse-mosquitto:1.6
imagePullPolicy: IfNotPresent
ports:
- name: default

View File

@ -0,0 +1,37 @@
---
type: docs
title: "In Memory"
linkTitle: "In Memory"
description: "Detailed documentation on the In Memory state component"
aliases:
- "/operations/components/setup-state-store/supported-state-stores/setup-inmemory/"
---
The In Memory state store component is useful for development purposes and works inside of a single machine boundary.
{{% alert title="Warning" color="warning" %}}
This component **shouldn't be used for production**. It is developer only and will never be stable. If you come across a scenario and want to use it in production, you can submit an issue and discuss it with the community.
{{% /alert %}}
## Component format
To setup in-memory state store, create a component of type `state.in-memory`. See [this guide]({{< ref "howto-get-save-state.md#step-1-setup-a-state-store" >}}) on how to create and apply a state store configuration.
```yaml
apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: <NAME>
namespace: <NAMESPACE>
spec:
type: state.in-memory
version: v1
metadata: []
```
> Note: While in-memory does not require any specific metadata for the component to work, `spec.metadata` is a required field.
## Related links
- [Basic schema for a Dapr component]({{< ref component-schema >}})
- Learn [how to create and configure state store components]({{< ref howto-get-save-state.md >}})
- Read more about the [state management building block]({{< ref state-management >}})

View File

@ -64,6 +64,17 @@
etag: false
ttl: false
query: false
- component: In Memory
link: setup-inmemory
state: Developer-only
version: v1
since: "1.8"
features:
crud: true
transactions: true
etag: true
ttl: true
query: false
- component: JetStream KV
link: setup-jetstream-kv
state: Alpha