Skip to content
프로젝트

소개

Dapr 빠른 시작과 튜토리얼입니다. Dapr Workflow(내구성 있는 실행), 내구성 있는 AI 에이전트, 펍/섭, 상태, 액터, 서비스 호출, 작업, 바인딩 등을 다루는 실행 가능한 C#, Go, Java, JavaScript, Python 코드를 제공합니다.

AI 및 머신러닝

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
+1
in 7 days
+2
in 15 days
+2
in 1 month
+2

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

README.md

Original

Dapr Quickstarts and Tutorials

GitHub Actions Workflow Status Discord GitHub License GitHub issue custom search in repo YouTube Channel Views X (formerly Twitter) Follow

Dapr is a portable runtime that gives your applications APIs for durable workflows, AI, messaging, state and more, in any language; this repository holds small, runnable samples for each of those APIs.

If you are new to Dapr and haven't done so already, it is recommended you go through the Dapr Getting Started instructions.

While you run these samples, the free Dapr Dev Dashboard gives you a live view of the apps, workflows, actors, subscriptions, components, state, and logs on your machine. It is an optional local development tool and works with every sample in this repository.

Quickstarts

Pick a building block API (for example, PubSub, state management, etc) and rapidly try it out in your favorite language SDK (recommended), or via HTTP. Visit the Dapr Docs Quickstarts Guide for a comprehensive walkthrough of each example.

Dapr Quickstart Description
Workflow Durable execution with Dapr Workflow: the workflow saves its progress as it runs, so a long-running, stateful process picks up where it left off after a crash or restart
AI A durable AI workflow that has an LLM (OpenAI, Gemini or Anthropic) review a contract and pauses for human approval when the risk is high
Conversation Send prompts to large language models (LLMs) from different providers through one consistent API, including tool calling
Publish and Subscribe Asynchronous communication between two services using messaging
Service Invocation Synchronous communication between two services using HTTP
State Management Store a service's data as key/value pairs in supported state stores
Search Index documents and search their content using the Search API (C# only)
Bindings Work with external systems using input bindings to respond to events and output bindings to call operations
Secrets Management Securely fetch secrets
Actors Create stateful, long running objects with identity
Configuration Get configuration items as key/value pairs or subscribe to changes whenever a configuration item changes
Cryptography Perform cryptographic operations without exposing keys to your application
Resiliency Define and apply fault-tolerant policies (retries/back-offs, timeouts and circuit breakers) to your Dapr API requests
Jobs Dapr Jobs enable you to manage and schedule tasks
Dapr MCP server Give AI agents Dapr's building blocks as tools through the Dapr MCP server

The SDK quickstarts use the Dapr SDKs for Python, Go, .NET, Java and JavaScript. To build AI agents on top of Dapr, see Dapr Agents.

Tutorials

Go deeper into a topic or scenario, oftentimes using building block APIs together to solve problems (for example, build a distributed calculator, build and deploy an app to Kubernetes).

Tutorials Description
Hello-world Demonstrates how to run Dapr locally. Highlights service invocation and state management.
Hello-kubernetes Demonstrates how to run Dapr in Kubernetes. Highlights service invocation and state management.
Distributed-calculator Demonstrates a distributed calculator application that uses Dapr services to power a React web app. Highlights polyglot (multi-language) programming, service invocation and state management.
Pub-sub Demonstrates how to use Dapr to enable pub-sub applications. Uses Redis as a pub-sub component.
Bindings Demonstrates how to use Dapr to create input and output bindings to other components. Uses bindings to Kafka.
Observability Demonstrates Dapr tracing capabilities. Uses Zipkin as a tracing component.
Secret Store Demonstrates the use of Dapr Secrets API to access secret stores.
Workflow Demonstrates how to author and manage Dapr workflows. Includes workflow patterns, resiliency, and common challenges & tips.

Development

Updating sdk versions

  • Python: make update_python_sdk_version [DAPR_VERSION=1.16.0] [FASTAPI_VERSION=1.16.0] [WORKFLOW_VERSION=1.16.0]
  • Go: make update_gosdk_version VERSION=v1.16.0
  • C#: make update_dotnet_sdk_version VERSION=1.19.0
  • Java: make update_java_sdk_version VERSION=1.12.0
  • Javascript: make update_javascript_sdk_version VERSION=3.19.0

Validating all the quickstarts

To run the samples, you need to have Dapr installed. Follow the Getting Started guide to install Dapr.

  • Python: make test_python_quickstarts
  • Go: make test_go_quickstarts
  • Java: make test_java_quickstarts
  • JS: make test_javascript_quickstarts
  • C#: make test_csharp_quickstarts
  • All quickstarts: make test_all_quickstarts

Validating a single quickstart

Navigate to the quickstart directory and run make validate.

cd conversation/python/sdk
make validate

Code of Conduct

Please refer to our Dapr Community Code of Conduct

관련 프로젝트 살펴보기

불러오는 중…