From 55ee82f0efd3291d35d0bea464d29ea7ff9c4986 Mon Sep 17 00:00:00 2001 From: Leon Mai Date: Tue, 14 Jul 2020 20:09:13 -0700 Subject: [PATCH] Cosmos - data must be in json (#691) * Document data must be in json * reword Co-authored-by: LM --- howto/setup-state-store/setup-azure-cosmosdb.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/howto/setup-state-store/setup-azure-cosmosdb.md b/howto/setup-state-store/setup-azure-cosmosdb.md index 9a100a705..e5ffa126f 100644 --- a/howto/setup-state-store/setup-azure-cosmosdb.md +++ b/howto/setup-state-store/setup-azure-cosmosdb.md @@ -103,6 +103,14 @@ kubectl apply -f cosmos.yaml To run locally, create a YAML file described above and provide the path to the `dapr run` command with the flag `--components-path`. See [this](https://github.com/dapr/cli#use-non-default-components-path) or run `dapr run --help` for more information on the path. +## Data format + +To use the cosmos state store, your data must be sent to Dapr in json-serialized. Having it just json *serializable* will not work. + +If you are using the Dapr SDKs (e.g. https://github.com/dapr/dotnet-sdk) the SDK will serialize your data to json. + +For examples see the curl operations in the [Partition keys](#partition-keys) section. + ## Partition keys