dapr-derive

Crates.iodapr-derive
lib.rsdapr-derive
version0.1.0-alpha.2
sourcesrc
created_at2019-10-25 10:17:10.268933
updated_at2019-10-29 10:22:37.411906
descriptionDapr SDK for Rust
homepagehttps://github.com/flier/rust-dapr
repositoryhttps://github.com/flier/rust-dapr
max_upload_size
id175569
size14,662
Ryan Levick (rylev)

documentation

README

Dapr SDK for Rust

Dapr is a portable, event-driven, serverless runtime for building distributed applications across cloud and edge.

This is the Dapr SDK for Rust, based on the auto-generated protobuf client.

For more info on Dapr and gRPC, visit this link.

Features

  • Dapr Runtime API with dapr::Runtime
  • Dapr Client with #[dapr::service]

Getting Started

Rust Version

dapr currently works on rust 1.39-beta and above as it requires support for the async_await feature. To install the beta simply follow the commands below:

$ rustup install beta
$ rustup component add rustfmt --toolchain beta
$ cargo +beta build

Tutorials

The examples folder contains a Dapr enabled app that receives events (client), and a caller that invokes the Dapr API (caller).

Run the client

$ cargo +beta build --example client
$ dapr run --log-level debug --protocol grpc --port 3500 --grpc-port 3600 --app-id client --app-port 4000 target/debug/examples/client

Run the caller

$ DAPR_GRPC_PORT=3600 cargo +beta run --example caller

Note: If you don't setup a Dapr binding, expect the error message

Error: Status { code: Unknown, message: "ERR_INVOKE_OUTPUT_BINDING: couldn't find output binding storage" }

License

This project is licensed under the MIT license.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Tonic by you, shall be licensed as MIT, without any additional terms or conditions.

Commit count: 13

cargo fmt