Skip to content

Commit

Permalink
new persistence apis, dependency upgrades, fix numerous dependency is…
Browse files Browse the repository at this point in the history
…sues, change network codec to use LengthDelimited codec, other minor optimisations

new persistence apis:
- write_message_batch
- read_messages
- read_messages
- delete_messages_to
  • Loading branch information
LeonHartley committed Apr 1, 2023
1 parent 8174bea commit fc14e61
Show file tree
Hide file tree
Showing 30 changed files with 1,086 additions and 338 deletions.
83 changes: 47 additions & 36 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 20 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,22 @@ scalable, fault-tolerant modern actor-driven application.
| [coerce-macros](https://crates.io/crates/coerce-macros) | Useful macros allowing for quick implementations of snapshots, JSON-serialisable remote messages and more. | ![crates.io](https://img.shields.io/crates/v/coerce-macros.svg) |
| [coerce-k8s](https://crates.io/crates/coerce-k8s) | Kubernetes discovery provider, automatically discover cluster peers hosted in Kubernetes, based on a configurable pod-selection label | ![crates.io](https://img.shields.io/crates/v/coerce-k8s.svg) |

# Using Coerce in your own project
First step to using Coerce in your project is to add the coerce crate dependency, this can be done by adding the following
to your Cargo.toml:

```toml
[dependencies]
coerce = { version = "0.8", features = ["full"] }
```

Coerce currently relies on an unstable feature from the `tracing` crate, `valuable`, used for enriching logs with
information on the actor context, which can be enabled by adding the following to your `.cargo/config.toml` file:
```
[build]
rustflags = ["--cfg", "tracing_unstable"]
```

## Features

### Actors
Expand Down Expand Up @@ -47,8 +63,10 @@ scalable, fault-tolerant modern actor-driven application.

- Easily accessible metrics and information useful for diagnosis

# How to build

# Building and testing the Coerce libraries
Building Coerce is easy. All you need is the latest Rust stable or nightly installed, along with Cargo.

```shell
# Clone the repository
git clone https://github.com/leonhartley/coerce-rs && cd coerce-rs
Expand All @@ -57,7 +75,7 @@ git clone https://github.com/leonhartley/coerce-rs && cd coerce-rs
cargo build

## Alternatively, if you'd like to build the library, dependencies and run the tests
cargo test
cargo test --all-features
```

# How to run the examples
Expand Down
8 changes: 4 additions & 4 deletions coerce/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "coerce"
description = "Async actor runtime and distributed systems framework"
license = "Apache-2.0"
version = "0.8.5"
version = "0.8.6"
authors = ["Leon Hartley <[email protected]>"]
edition = "2021"
readme = "README.md"
Expand Down Expand Up @@ -80,7 +80,7 @@ async-trait = { version = "0.1" }
hashring = { version = "0.3.0", optional = true }
bytes = { version = "1.4.0", optional = true }
byteorder = { version = "1.4.3", optional = true }
chrono = { version = "0.4.23", features = ["serde"], optional = true }
chrono = { version = "0.4", features = ["serde"], optional = true }
protobuf = { version = "3.2.0", optional = true }
anyhow = { version = "1.0.68", optional = true }
rand = "0.8.5"
Expand All @@ -95,8 +95,8 @@ sha2 = { version = "0.10.6", optional = true }

# API dependencies
axum = { version = "0.6.4", features = ["query"], optional = true }
utoipa = { version = "3.0.1", features = ["axum_extras"], optional = true }
utoipa-swagger-ui = { version = "3.0.2", features = ["axum"], optional = true }
utoipa = { version = "3", features = ["axum_extras", "chrono"], optional = true }
utoipa-swagger-ui = { version = "3", features = ["axum"], optional = true }

[dev-dependencies]
coerce-macros = { version = "0.2.0" }
Expand Down
Loading

0 comments on commit fc14e61

Please sign in to comment.