+```
+
+Components:
+- dapr_operator
+- dapr_placement
+- dapr_sidecar_injector
+
+Example:
```bash
helm install dapr dapr/dapr --namespace dapr-system --set dapr_operator.logLevel=error
```
-#### Setting the Placement Service log level
-
-```bash
-helm install dapr dapr/dapr --namespace dapr-system --set dapr_placement.logLevel=error
-```
-
-#### Setting the Sidecar Injector log level
-
-```bash
-helm install dapr dapr/dapr --namespace dapr-system --set dapr_sidecar_injector.logLevel=error
-```
-
-## Viewing Logs on Kubernetes
+### Viewing Logs on Kubernetes
Dapr logs are written to stdout and stderr.
This section will guide you on how to view logs for Dapr system components as well as the Dapr sidecar.
-### Sidecar Logs
+#### Sidecar Logs
When deployed in Kubernetes, the Dapr sidecar injector will inject an Dapr container named `daprd` into your annotated pod.
In order to view logs for the sidecar, simply find the pod in question by running `kubectl get pods`:
@@ -134,7 +133,7 @@ time="2019-09-04T02:52:27Z" level=info msg="dapr initialized. Status: Running. I
time="2019-09-04T02:52:27Z" level=info msg="actors: established connection to placement service at dapr-placement.dapr-system.svc.cluster.local:80"
```
-### System Logs
+#### System Logs
Dapr runs the following system pods:
@@ -142,7 +141,7 @@ Dapr runs the following system pods:
* Dapr sidecar injector
* Dapr placement service
-#### Viewing Operator Logs
+#### Operator Logs
```Bash
kubectl logs -l app=dapr-operator -n dapr-system
@@ -153,7 +152,7 @@ time="2019-09-05T19:03:43Z" level=info msg="Dapr Operator is started"
*Note: If Dapr is installed to a different namespace than dapr-system, simply replace the namespace to the desired one in the command above*
-#### Viewing Sidecar Injector Logs
+#### Sidecar Injector Logs
```Bash
kubectl logs -l app=dapr-sidecar-injector -n dapr-system
diff --git a/best-practices/troubleshooting/profiling_debugging.md b/daprdocs/content/en/operations/troubleshooting/profiling-debugging.md
similarity index 78%
rename from best-practices/troubleshooting/profiling_debugging.md
rename to daprdocs/content/en/operations/troubleshooting/profiling-debugging.md
index 173f4f646..a803bd9fa 100644
--- a/best-practices/troubleshooting/profiling_debugging.md
+++ b/daprdocs/content/en/operations/troubleshooting/profiling-debugging.md
@@ -1,4 +1,10 @@
-# Profiling and Debugging
+---
+type: docs
+title: "Profiling & Debugging"
+linkTitle: "Debugging"
+weight: 4000
+description: "Discover problems and issues such as concurrency, performance, cpu and memory usage through a profiling session"
+---
In any real world scenario, an app might start exhibiting undesirable behavior in terms of resource spikes.
CPU/Memory spikes are not uncommon in most cases.
@@ -7,32 +13,47 @@ Dapr allows users to start an on-demand profiling session using `pprof` through
## Enable profiling
-Dapr allows you to enable profiling in both Kubernetes and Standalone modes.
+Dapr allows you to enable profiling in both Kubernetes and stand-alone modes.
-### Kubernetes
+### Stand-alone
-To enable profiling in Kubernetes, simply add the following annotation to your Dapr annotated pod:
-
-
-annotations:
- dapr.io/enabled: "true"
- dapr.io/app-id: "rust-app"
- dapr.io/enable-profiling: "true"
-
-
-### Standalone
-
-To enable profiling in Standalone mode, pass the `enable-profiling` and the `profile-port` flags to the Dapr CLI:
-Note that `profile-port` is not required, and Dapr will pick an available port.
+To enable profiling in Standalone mode, pass the `--enable-profiling` and the `--profile-port` flags to the Dapr CLI:
+Note that `profile-port` is not required, and if not provided Dapr will pick an available port.
```bash
dapr run --enable-profiling true --profile-port 7777 python myapp.py
```
+### Kubernetes
+
+To enable profiling in Kubernetes, simply add the `dapr.io/enable-profiling` annotation to your Dapr annotated pod:
+
+```yml
+ annotations:
+ dapr.io/enabled: "true"
+ dapr.io/app-id: "rust-app"
+ dapr.io/enable-profiling: "true"
+```
+
## Debug a profiling session
After profiling is enabled, we can start a profiling session to investigate what's going on with the Dapr runtime.
+### Stand-alone
+
+For Standalone mode, locate the Dapr instance that you want to profile:
+
+```bash
+dapr list
+APP ID DAPR PORT APP PORT COMMAND AGE CREATED PID
+node-subscriber 3500 3000 node app.js 12s 2019-09-09 15:11.24 896
+```
+
+Grab the DAPR PORT, and if profiling has been enabled as described above, you can now start using `pprof` to profile Dapr.
+Look at the Kubernetes examples above for some useful commands to profile Dapr.
+
+More info on pprof can be found [here](https://github.com/google/pprof).
+
### Kubernetes
First, find the pod containing the Dapr runtime. If you don't already know the the pod name, type `kubectl get pods`:
@@ -82,7 +103,7 @@ For memory related issues, you can profile the heap:
go tool pprof --pdf your-binary-file http://localhost:7777/debug/pprof/heap > heap.pdf
```
-
+
Profiling allocated objects:
@@ -99,19 +120,4 @@ To analyze, grab the file path above (its a dynamic file path, so pay attention
go tool pprof -alloc_objects --pdf /Users/myusername/pprof/pprof.daprd.alloc_objects.alloc_space.inuse_objects.inuse_space.003.pb.gz > alloc-objects.pdf
```
-
-
-### Standalone
-
-For Standalone mode, locate the Dapr instance that you want to profile:
-
-```bash
-dapr list
-APP ID DAPR PORT APP PORT COMMAND AGE CREATED PID
-node-subscriber 3500 3000 node app.js 12s 2019-09-09 15:11.24 896
-```
-
-Grab the DAPR PORT, and if profiling has been enabled as described above, you can now start using `pprof` to profile Dapr.
-Look at the Kubernetes examples above for some useful commands to profile Dapr.
-
-More info on pprof can be found [here](https://github.com/google/pprof).
+
diff --git a/best-practices/troubleshooting/tracing.md b/daprdocs/content/en/operations/troubleshooting/setup-tracing.md
similarity index 65%
rename from best-practices/troubleshooting/tracing.md
rename to daprdocs/content/en/operations/troubleshooting/setup-tracing.md
index a58193839..afdbc8eb7 100644
--- a/best-practices/troubleshooting/tracing.md
+++ b/daprdocs/content/en/operations/troubleshooting/setup-tracing.md
@@ -1,11 +1,77 @@
-# Tracing
+---
+type: docs
+title: "Tracing"
+linkTitle: "Tracing"
+weight: 3000
+description: "Configure Dapr to send distributed tracing data"
+---
Dapr integrates with Open Census for telemetry and tracing.
It is recommended to run Dapr with tracing enabled for any production scenario.
Since Dapr uses Open Census, you can configure various exporters for tracing and telemetry data based on your environment, whether it is running in the cloud or on-premises.
-## Distributed Tracing with Zipkin on Kubernetes
+## Tracing configuration
+
+The `tracing` section under the `Configuration` spec contains the following properties:
+
+```yml
+tracing:
+ enabled: true
+ exporterType: zipkin
+ exporterAddress: ""
+ expandParams: true
+ includeBody: true
+```
+
+The following table lists the different properties.
+
+| Property | Type | Description |
+|----------|------|-------------|
+| enabled | bool | Set tracing to be enabled or disabled
+| exporterType | string | Name of the Open Census exporter to use. For example: Zipkin, Azure Monitor, etc
+| exporterAddress | string | URL of the exporter
+| expandParams | bool | When true, expands parameters passed to HTTP endpoints
+| includeBody | bool | When true, includes the request body in the tracing event
+
+
+## Zipkin in stand-alone mode
+
+The following steps show you how to configure Dapr to send distributed tracing data to Zipkin running as a container on your local machine and view them.
+
+For Standalone mode, create a Dapr configuration file locally and reference it with the Dapr CLI.
+
+1. Create the following YAML file:
+
+ ```yaml
+ apiVersion: dapr.io/v1alpha1
+ kind: Configuration
+ metadata:
+ name: zipkin
+ namespace: default
+ spec:
+ tracing:
+ enabled: true
+ exporterType: zipkin
+ exporterAddress: "http://localhost:9411/api/v2/spans"
+ expandParams: true
+ includeBody: true
+ ```
+
+2. Launch Zipkin using Docker:
+
+ ```bash
+ docker run -d -p 9411:9411 openzipkin/zipkin
+ ```
+
+3. Launch Dapr with the `--config` param:
+
+ ```bash
+ dapr run --app-id mynode --app-port 3000 --config ./config.yaml node app.js
+ ```
+
+
+## Zipkin in Kubernetes mode
The following steps show you how to configure Dapr to send distributed tracing data to Zipkin running as a container in your Kubernetes cluster, and how to view them.
@@ -65,62 +131,5 @@ kubectl port-forward svc/zipkin 9411:9411
On your browser, go to ```http://localhost:9411``` and you should see the Zipkin UI.
-
+
-## Distributed Tracing with Zipkin - Standalone Mode
-
-The following steps show you how to configure Dapr to send distributed tracing data to Zipkin running as a container on your local machine and view them.
-
-For Standalone mode, create a Dapr configuration file locally and reference it with the Dapr CLI.
-
-1. Create the following YAML file:
-
-```yaml
-apiVersion: dapr.io/v1alpha1
-kind: Configuration
-metadata:
- name: zipkin
- namespace: default
-spec:
- tracing:
- enabled: true
- exporterType: zipkin
- exporterAddress: "http://localhost:9411/api/v2/spans"
- expandParams: true
- includeBody: true
-```
-
-2. Launch Zipkin using Docker:
-
-```bash
-docker run -d -p 9411:9411 openzipkin/zipkin
-```
-
-3. Launch Dapr with the `--config` param:
-
-```bash
-dapr run --app-id mynode --app-port 3000 --config ./config.yaml node app.js
-```
-
-## Tracing Configuration
-
-The `tracing` section under the `Configuration` spec contains the following properties:
-
-```yml
-tracing:
- enabled: true
- exporterType: zipkin
- exporterAddress: ""
- expandParams: true
- includeBody: true
-```
-
-The following table lists the different properties.
-
-Property | Type | Description
----- | ------- | -----------
-enabled | bool | Set tracing to be enabled or disabled
-exporterType | string | Name of the Open Census exporter to use. For example: Zipkin, Azure Monitor, etc
-exporterAddress | string | URL of the exporter
-expandParams | bool | When true, expands parameters passed to HTTP endpoints
-includeBody | bool | When true, includes the request body in the tracing event
diff --git a/daprdocs/content/en/reference/_index.md b/daprdocs/content/en/reference/_index.md
new file mode 100644
index 000000000..7908b27c5
--- /dev/null
+++ b/daprdocs/content/en/reference/_index.md
@@ -0,0 +1,7 @@
+---
+type: docs
+title: "Dapr Reference Docs"
+linkTitle: "Reference"
+weight: 60
+description: "Detailed documentation on the Dapr API, CLI, bindings and more"
+---
diff --git a/daprdocs/content/en/reference/api/_index.md b/daprdocs/content/en/reference/api/_index.md
new file mode 100644
index 000000000..03c8a9be6
--- /dev/null
+++ b/daprdocs/content/en/reference/api/_index.md
@@ -0,0 +1,7 @@
+---
+type: docs
+title: Dapr API reference
+linkTitle: "Dapr API"
+weight: 100
+description: "Information on each api, the associated endpoints, and what capabilities are available"
+---
diff --git a/reference/api/actors_api.md b/daprdocs/content/en/reference/api/actors_api.md
similarity index 91%
rename from reference/api/actors_api.md
rename to daprdocs/content/en/reference/api/actors_api.md
index 7f4da8f76..78c30d1e2 100644
--- a/reference/api/actors_api.md
+++ b/daprdocs/content/en/reference/api/actors_api.md
@@ -1,28 +1,14 @@
-# Dapr actors API reference
+---
+type: docs
+title: "Actors API reference"
+linkTitle: "Actors API"
+description: "Detailed documentation on the actors API"
+weight: 500
+---
Dapr provides native, cross-platform and cross-language virtual actor capabilities.
Besides the language specific Dapr SDKs, a developer can invoke an actor using the API endpoints below.
-## Endpoints
-
-- [Service Code Calling to Dapr](#specifications-for-user-service-code-calling-to-dapr)
- - [Invoke Actor Method](#invoke-actor-method)
- - [Actor State Transactions](#actor-state-transactions)
- - [Get Actor State](#get-actor-state)
- - [Create Actor Reminder](#create-actor-reminder)
- - [Get Actor Reminder](#get-actor-reminder)
- - [Delete Actor Reminder](#delete-actor-reminder)
- - [Create Actor Timer](#create-actor-timer)
- - [Delete Actor Timer](#delete-actor-timer)
-- [Dapr Calling to Service Code](#specifications-for-dapr-calling-to-user-service-code)
- - [Get Registered Actors](#get-registered-actors)
- - [Deactivate Actor](#deactivate-actor)
- - [Invoke Actor Method](#invoke-actor-method-1)
- - [Invoke Reminder](#invoke-reminder)
- - [Invoke Timer](#invoke-timer)
- - [Health Checks](#health-check)
-- [Querying Actor State Externally](#querying-actor-state-externally)
-
## User service code calling dapr
### Invoke actor method
@@ -31,7 +17,7 @@ Invoke an actor method through Dapr.
#### HTTP Request
-```http
+```
POST/GET/PUT/DELETE http://localhost:/v1.0/actors///method/
```
@@ -90,7 +76,7 @@ Persists the changed to the state for an actor as a multi-item transaction.
#### HTTP Request
-```http
+```
POST/PUT http://localhost:/v1.0/actors///state
```
@@ -142,7 +128,7 @@ Gets the state for an actor using a specified key.
#### HTTP Request
-```http
+```
GET http://localhost:/v1.0/actors///state/
```
@@ -188,8 +174,8 @@ Creates a persistent reminder for an actor.
#### HTTP Request
-```http
-POST,PUT http://localhost:/v1.0/actors///reminders/
+```
+POST/PUT http://localhost:/v1.0/actors///reminders/
```
Body:
@@ -255,7 +241,7 @@ Gets a reminder for an actor.
#### HTTP Request
-```http
+```
GET http://localhost:/v1.0/actors///reminders/
```
@@ -301,7 +287,7 @@ Deletes a reminder for an actor.
#### HTTP Request
-```http
+```
DELETE http://localhost:/v1.0/actors///reminders/
```
@@ -337,8 +323,8 @@ Creates a timer for an actor.
#### HTTP Request
-```http
-POST,PUT http://localhost:/v1.0/actors///timers/
+```
+POST/PUT http://localhost:/v1.0/actors///timers/
```
Body:
@@ -433,7 +419,7 @@ Gets the registered actors types for this app and the Dapr actor configuration s
#### HTTP Request
-```http
+```
GET http://localhost:/dapr/config
```
@@ -486,7 +472,7 @@ Deactivates an actor by persisting the instance of the actor to the state store
#### HTTP Request
-```http
+```
DELETE http://localhost:/actors//
```
@@ -523,7 +509,7 @@ Invokes a method for an actor with the specified methodName where parameters to
#### HTTP Request
-```http
+```
PUT http://localhost: