Skip to content

Commit 74b5258

Browse files
authored
Merge branch 'v1.16' into remove-wait_until_ready
2 parents 52b8ed7 + a388998 commit 74b5258

File tree

12 files changed

+234
-120
lines changed

12 files changed

+234
-120
lines changed

daprdocs/content/en/concepts/building-blocks-concept.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ Dapr provides the following building blocks:
3131
| [**Distributed lock**]({{% ref "distributed-lock-api-overview" %}}) | `/v1.0-alpha1/lock` | The distributed lock API enables you to take a lock on a resource so that multiple instances of an application can access the resource without conflicts and provide consistency guarantees.
3232
| [**Cryptography**]({{% ref "cryptography-overview" %}}) | `/v1.0-alpha1/crypto` | The Cryptography API enables you to perform cryptographic operations, such as encrypting and decrypting messages, without exposing keys to your application.
3333
| [**Jobs**]({{% ref "jobs-overview" %}}) | `/v1.0-alpha1/jobs` | The Jobs API enables you to schedule and orchestrate jobs. Example scenarios include: <ul><li>Schedule batch processing jobs to run every business day</li><li>Schedule various maintenance scripts to perform clean-ups</li><li>Schedule ETL jobs to run at specific times (hourly, daily) to fetch new data, process it, and update the data warehouse with the latest information.</li></ul>
34-
| [**Conversation**]({{% ref "conversation-overview" %}}) | `/v1.0-alpha1/conversation` | The Conversation API enables you to supply prompts to converse with different large language models (LLMs) and includes features such as prompt caching and personally identifiable information (PII) obfuscation.
34+
| [**Conversation**]({{% ref "conversation-overview" %}}) | `/v1.0-alpha2/conversation` | The Conversation API enables you to supply prompts to converse with different large language models (LLMs) and includes features such as prompt caching and personally identifiable information (PII) obfuscation.

daprdocs/content/en/developing-applications/building-blocks/state-management/howto-outbox.md

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -181,28 +181,20 @@ DAPR_STORE_NAME = "statestore"
181181
async def main():
182182
client = DaprClient()
183183
184-
# Define the first state operation to save the value "2"
185-
op1 = StateItem(
186-
key="key1",
187-
value=b"2"
184+
client.execute_state_transaction(
185+
store_name=DAPR_STORE_NAME,
186+
operations=[
187+
# Define the first state operation to save the value "2"
188+
TransactionalStateOperation(
189+
key='key1', data='2', metadata={'outbox.projection': 'false'}
190+
),
191+
# Define the second state operation to publish the value "3" with metadata
192+
TransactionalStateOperation(
193+
key='key1', data='3', metadata={'outbox.projection': 'true'}
194+
),
195+
],
188196
)
189197
190-
# Define the second state operation to publish the value "3" with metadata
191-
op2 = StateItem(
192-
key="key1",
193-
value=b"3",
194-
options=StateOptions(
195-
metadata={
196-
"outbox.projection": "true"
197-
}
198-
)
199-
)
200-
201-
# Create the list of state operations
202-
ops = [op1, op2]
203-
204-
# Execute the state transaction
205-
await client.state.transaction(DAPR_STORE_NAME, operations=ops)
206198
print("State transaction executed.")
207199
```
208200

daprdocs/content/en/developing-applications/building-blocks/workflow/workflow-multi-app.md

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,11 +73,12 @@ Finally, the target app ID must have the activity or child workflow defined and
7373
{{% /alert %}}
7474

7575
{{% alert title="Important Limitations" color="warning" %}}
76-
**SDKs supporting multi-application workflows** - Multi-application workflows are used via the SDKs.
76+
**SDKs supporting multi-application workflows** - Multi-application workflows are used via the SDKs.
7777
Currently the following are supported:
7878
- **Java** (**only** activity calls)
79-
- **Go** (**both** activities and child workflows calls)
80-
- The Python, .NET, JavaScript SDKs support are planned for future releases
79+
- **Go** (**both** activities and child workflows calls)
80+
- **Python** (**both** activities and child workflows calls)
81+
- The .NET and JavaScript SDKs support are planned for future releases
8182
{{% /alert %}}
8283

8384
## Error handling
@@ -139,6 +140,17 @@ public class BusinessWorkflow implements Workflow {
139140

140141
{{% /tab %}}
141142

143+
{{% tab "Python" %}}
144+
145+
```python
146+
@wfr.workflow
147+
def app1_workflow(ctx: wf.DaprWorkflowContext):
148+
output = yield ctx.call_activity('ActivityA', input='my-input', app_id='App2')
149+
return output
150+
```
151+
152+
{{% /tab %}}
153+
142154
{{< /tabpane >}}
143155

144156
## Multi-application child workflow example
@@ -169,6 +181,17 @@ func BusinessWorkflow(ctx *workflow.WorkflowContext) (any, error) {
169181

170182
{{% /tab %}}
171183

184+
{{% tab "Python" %}}
185+
186+
```python
187+
@wfr.workflow
188+
def workflow1(ctx: wf.DaprWorkflowContext):
189+
output = yield ctx.call_child_workflow(workflow='Workflow2', input='my-input', app_id='App2')
190+
return output
191+
```
192+
193+
{{% /tab %}}
194+
172195
{{< /tabpane >}}
173196

174197
## Related links

daprdocs/content/en/getting-started/quickstarts/conversation-quickstart.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ async function main() {
249249
metadata: {},
250250
};
251251
252-
const reqURL = `${daprHost}:${daprHttpPort}/v1.0-alpha1/conversation/${conversationComponentName}/converse`;
252+
const reqURL = `${daprHost}:${daprHttpPort}/v1.0-alpha2/conversation/${conversationComponentName}/converse`;
253253

254254
try {
255255
const response = await fetch(reqURL, {

daprdocs/content/en/operations/configuration/increase-request-size.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ By default, Dapr has a limit for the request body size, set to 4MB. You can chan
2222
When running in self-hosted mode, use the `--max-body-size` flag to configure Dapr to use non-default request body size:
2323

2424
```bash
25-
dapr run --max-body-size 16 node app.js
25+
dapr run --max-body-size 16Mi node app.js
2626
```
2727
{{% /tab %}}
2828

@@ -52,7 +52,7 @@ spec:
5252
dapr.io/enabled: "true"
5353
dapr.io/app-id: "myapp"
5454
dapr.io/app-port: "8000"
55-
dapr.io/max-body-size: "16"
55+
dapr.io/max-body-size: "16Mi"
5656
#...
5757
```
5858

daprdocs/content/en/operations/hosting/kubernetes/kubernetes-persisting-scheduler.md

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -77,22 +77,6 @@ kubectl delete pvc -n dapr-system dapr-scheduler-data-dir-dapr-scheduler-server-
7777
Persistent Volume Claims are not deleted automatically with an [uninstall]({{% ref dapr-uninstall.md %}}). This is a deliberate safety measure to prevent accidental data loss.
7878
{{% /alert %}}
7979

80-
{{% alert title="Note" color="primary" %}}
81-
For storage providers that do NOT support dynamic volume expansion: If Dapr has ever been installed on the cluster before, the Scheduler's Persistent Volume Claims must be manually uninstalled in order for new ones with increased storage size to be created.
82-
```bash
83-
kubectl delete pvc -n dapr-system dapr-scheduler-data-dir-dapr-scheduler-server-0 dapr-scheduler-data-dir-dapr-scheduler-server-1 dapr-scheduler-data-dir-dapr-scheduler-server-2
84-
```
85-
Persistent Volume Claims are not deleted automatically with an [uninstall]({{< ref dapr-uninstall.md >}}). This is a deliberate safety measure to prevent accidental data loss.
86-
{{% /alert %}}
87-
88-
{{% alert title="Note" color="primary" %}}
89-
For storage providers that do NOT support dynamic volume expansion: If Dapr has ever been installed on the cluster before, the Scheduler's Persistent Volume Claims must be manually uninstalled in order for new ones with increased storage size to be created.
90-
```bash
91-
kubectl delete pvc -n dapr-system dapr-scheduler-data-dir-dapr-scheduler-server-0 dapr-scheduler-data-dir-dapr-scheduler-server-1 dapr-scheduler-data-dir-dapr-scheduler-server-2
92-
```
93-
Persistent Volume Claims are not deleted automatically with an [uninstall]({{< ref dapr-uninstall.md >}}). This is a deliberate safety measure to prevent accidental data loss.
94-
{{% /alert %}}
95-
9680
#### Increase existing Scheduler Storage Size
9781

9882
{{% alert title="Warning" color="warning" %}}

daprdocs/content/en/operations/observability/tracing/otel-collector/open-telemetry-collector-jaeger.md

Lines changed: 100 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,30 @@
11
---
22
type: docs
3-
title: "Using OpenTelemetry Collector to collect traces to send to Jaeger"
4-
linkTitle: "Using the OpenTelemetry for Jaeger"
3+
title: "Using OpenTelemetry to send traces to Jaeger V2"
4+
linkTitle: "Using OpenTelemetry for Jaeger V2"
55
weight: 1200
6-
description: "How to push trace events to Jaeger distributed tracing platform, using the OpenTelemetry Collector."
6+
description: "How to push trace events to Jaeger V2 distributed tracing platform using OpenTelemetry protocol."
77
---
88

9-
While Dapr supports writing traces using OpenTelemetry (OTLP) and Zipkin protocols, Zipkin support for Jaeger has been deprecated in favor of OTLP. Although Jaeger supports OTLP directly, the recommended approach for production is to use the OpenTelemetry Collector to collect traces from Dapr and send them to Jaeger, allowing your application to quickly offload data and take advantage of features like retries, batching, and encryption. For more information, read the Open Telemetry Collector [documentation](https://opentelemetry.io/docs/collector/#when-to-use-a-collector).
9+
Dapr supports writing traces using the OpenTelemetry (OTLP) protocol, and Jaeger V2 natively supports OTLP, allowing Dapr to send traces directly to a Jaeger V2 instance. This approach is recommended for production to leverage Jaeger V2's capabilities for distributed tracing.
10+
1011
{{< tabpane text=true >}}
1112

1213
{{% tab "Self-hosted" %}}
13-
<!-- self-hosted -->
14-
## Configure Jaeger in self-hosted mode
14+
## Configure Jaeger V2 in self-hosted mode
1515

1616
### Local setup
1717

1818
The simplest way to start Jaeger is to run the pre-built, all-in-one Jaeger image published to DockerHub and expose the OTLP port:
1919

2020
```bash
21-
docker run -d --name jaeger \
22-
-p 4317:4317 \
21+
docker run --rm --name jaeger \
2322
-p 16686:16686 \
24-
jaegertracing/all-in-one:1.49
23+
-p 4317:4317 \
24+
-p 4318:4318 \
25+
-p 5778:5778 \
26+
-p 9411:9411 \
27+
cr.jaegertracing.io/jaegertracing/jaeger:2.11.0
2528
```
2629

2730
Next, create the following `config.yaml` file locally:
@@ -58,41 +61,103 @@ To view traces in your browser, go to `http://localhost:16686` to see the Jaeger
5861

5962
{{% tab "Kubernetes" %}}
6063
<!-- kubernetes -->
61-
## Configure Jaeger on Kubernetes with the OpenTelemetry Collector
64+
## Configure Jaeger V2 on Kubernetes
6265

63-
The following steps show you how to configure Dapr to send distributed tracing data to the OpenTelemetry Collector which, in turn, sends the traces to Jaeger.
66+
The following steps show you how to configure Dapr to send distributed tracing data directly to a Jaeger V2 instance deployed using the OpenTelemetry Operator with in-memory storage.
6467

6568
### Prerequisites
6669

6770
- [Install Dapr on Kubernetes]({{% ref kubernetes %}})
68-
- [Set up Jaeger](https://www.jaegertracing.io/docs/1.49/operator/) using the Jaeger Kubernetes Operator
69-
70-
### Set up OpenTelemetry Collector to push to Jaeger
7171

72-
To push traces to your Jaeger instance, install the OpenTelemetry Collector on your Kubernetes cluster.
72+
### Set up Jaeger V2 with the OpenTelemetry Operator
7373

74-
1. Download and inspect the [`open-telemetry-collector-jaeger.yaml`](/docs/open-telemetry-collector/open-telemetry-collector-jaeger.yaml) file.
74+
Jaeger V2 can be deployed using the OpenTelemetry Operator for simplified management and native OTLP support. The following example configures Jaeger V2 with in-memory storage.
7575

76-
1. In the data section of the `otel-collector-conf` ConfigMap, update the `otlp/jaeger.endpoint` value to reflect the endpoint of your Jaeger collector Kubernetes service object.
76+
> **Note on Storage Backends:** This example uses in-memory storage (`memstore`) for simplicity, suitable for development or testing environments as it stores up to 100,000 traces in memory. For production environments, consider configuring a persistent storage backend like Cassandra or Elasticsearch to ensure trace data durability.
7777

78-
1. Deploy the OpenTelemetry Collector into the same namespace where your Dapr-enabled applications are running:
78+
#### Installation
7979

80-
```sh
81-
kubectl apply -f open-telemetry-collector-jaeger.yaml
80+
1. **Install cert-manager** to manage certificates:
81+
```bash
82+
kubectl apply -f https://github.com/cert-manager/cert-manager/releases/download/v1.19.1/cert-manager.yaml -n cert-manager
8283
```
84+
Verify that all resources in the `cert-manager` namespace are ready.
8385

84-
### Set up Dapr to send traces to OpenTelemetryCollector
85-
86-
Create a Dapr configuration file to enable tracing and export the sidecar traces to the OpenTelemetry Collector.
87-
88-
1. Use the [`collector-config-otel.yaml`](/docs/open-telemetry-collector/collector-config-otel.yaml) file to create your own Dapr configuration.
86+
1. **Install the OpenTelemetry Operator**:
87+
```bash
88+
kubectl apply -f https://github.com/open-telemetry/opentelemetry-operator/releases/latest/download/opentelemetry-operator.yaml
89+
```
90+
Confirm that all resources in the `opentelemetry-operator-system` namespace are ready.
91+
92+
1. **Deploy a Jaeger V2 instance with in-memory storage**:
93+
Apply the following configuration to create a Jaeger V2 instance:
94+
```yaml
95+
apiVersion: opentelemetry.io/v1beta1
96+
kind: OpenTelemetryCollector
97+
metadata:
98+
name: jaeger-inmemory-instance
99+
namespace: observability
100+
spec:
101+
image: jaegertracing/jaeger:latest
102+
ports:
103+
- name: jaeger
104+
port: 16686
105+
config:
106+
service:
107+
extensions: [jaeger_storage, jaeger_query]
108+
pipelines:
109+
traces:
110+
receivers: [otlp]
111+
exporters: [jaeger_storage_exporter]
112+
extensions:
113+
jaeger_query:
114+
storage:
115+
traces: memstore
116+
jaeger_storage:
117+
backends:
118+
memstore:
119+
memory:
120+
max_traces: 100000
121+
receivers:
122+
otlp:
123+
protocols:
124+
grpc:
125+
endpoint: 0.0.0.0:4317
126+
http:
127+
endpoint: 0.0.0.0:4318
128+
exporters:
129+
jaeger_storage_exporter:
130+
trace_storage: memstore
131+
```
132+
Apply it with:
133+
```bash
134+
kubectl apply -f jaeger-inmemory.yaml -n observability
135+
```
89136

90-
1. Update the `namespace` and `otel.endpointAddress` values to align with the namespace where your Dapr-enabled applications and OpenTelemetry Collector are deployed.
91137

92-
1. Apply the configuration with:
138+
### Set up Dapr to send traces to Jaeger V2
139+
140+
Create a Dapr configuration file to enable tracing and export the sidecar traces directly to the Jaeger V2 instance.
141+
142+
1. Create a configuration file (e.g., `tracing.yaml`) with the following content, updating the `namespace` and `otel.endpointAddress` to match your Jaeger V2 instance:
143+
```yaml
144+
apiVersion: dapr.io/v1alpha1
145+
kind: Configuration
146+
metadata:
147+
name: tracing
148+
namespace: order-system
149+
spec:
150+
tracing:
151+
samplingRate: "1"
152+
otel:
153+
endpointAddress: "jaeger-inmemory-instance-collector.observability.svc.cluster.local:4317"
154+
isSecure: false
155+
protocol: grpc
156+
```
93157

94-
```sh
95-
kubectl apply -f collector-config.yaml
158+
2. Apply the configuration:
159+
```bash
160+
kubectl apply -f tracing.yaml -n order-system
96161
```
97162

98163
### Deploy your app with tracing enabled
@@ -122,20 +187,20 @@ That’s it! There’s no need to include the OpenTelemetry SDK or instrument yo
122187

123188
### View traces
124189

125-
To view Dapr sidecar traces, port-forward the Jaeger Service and open the UI:
190+
To view Dapr sidecar traces, port-forward the Jaeger V2 service and open the UI:
126191

127192
```bash
128-
kubectl port-forward svc/jaeger-query 16686 -n observability
193+
kubectl port-forward svc/jaeger-inmemory-instance-collector 16686 -n observability
129194
```
130195

131-
In your browser, go to `http://localhost:16686` and you will see the Jaeger UI.
196+
In your browser, go to `http://localhost:16686` to see the Jaeger V2 UI.
132197

133198
![jaeger](/images/jaeger_ui.png)
134199
{{% /tab %}}
135200

136201
{{< /tabpane >}}
202+
137203
## References
138204

139-
- [Jaeger Getting Started](https://www.jaegertracing.io/docs/1.49/getting-started/)
140-
- [Jaeger Kubernetes Operator](https://www.jaegertracing.io/docs/1.49/operator/)
141-
- [OpenTelemetry Collector Exporters](https://opentelemetry.io/docs/collector/configuration/#exporters)
205+
- [Jaeger V2 Getting Started](https://www.jaegertracing.io/docs/2.11/getting-started/)
206+
- [Jaeger V2 Kubernetes Operator](https://www.jaegertracing.io/docs/2.11/deployment/kubernetes/#kubernetes-operator)

0 commit comments

Comments
 (0)