Skip to content

Commit

Permalink
wip: Replace sawtooth-sdk-rust's client components
Browse files Browse the repository at this point in the history
DONE:
* Use tokio / tmq
* Support multiple connections
* Strategy for choosing write connection

TODO:
* Zmq publisher for embedded
* Drop / close
* De duplication
* GC timed out reply channels
* Add server socket to EmbeddedTP, test using actual ZMQ

Signed-off-by: Ryan Roberts <[email protected]>
  • Loading branch information
ryan-s-roberts committed Jun 16, 2023
1 parent e4a9870 commit fbe90b1
Show file tree
Hide file tree
Showing 31 changed files with 891 additions and 508 deletions.
80 changes: 48 additions & 32 deletions Cargo.lock

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

10 changes: 7 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ anyhow = "1.0.6"
assert_fs = "1.0"
async-graphql = "5.0.6"
async-graphql-poem = "5.0.6"
async-sawtooth-sdk = { path = "crates/async-sawtooth-sdk" }
async-stream = "0.3.3"
async-trait = "0.1.61"
atty = "0.2.14"
Expand Down Expand Up @@ -80,7 +81,7 @@ mockito = "1.0.2"
oauth2 = "4.4"
opa = "0.9.0"
openssl = "0.10.48"
opentelemetry = { version = "0.18.0", features = ["rt-tokio"] }
opentelemetry = { version = "0.19.0", features = ["rt-tokio"] }
opentelemetry-jaeger = { version = "0.17.0", features = [
"rt-tokio",
"reqwest_collector_client",
Expand All @@ -89,10 +90,12 @@ opentelemetry-jaeger = { version = "0.17.0", features = [
owo-colors = "3.5.0"
parking_lot = "0.12.0"
percent-encoding = "2.1.0"
pin-project = "1.0.12"
pin-project-lite = "0.2"
pinvec = "*"
pkcs8 = { version = "*", features = ["std", "alloc"] }
poem = { version = "1.3.30", features = ["opentelemetry", "websocket"] }
portpicker = "0.1.1"
pow_of_2 = "0.1"
proptest = "1.0.0"
prost = "0.10" # common, sawtooth-protocol, sawtooth-tp: version = "0.10.0"
prost-build = "0.10.0"
Expand Down Expand Up @@ -121,13 +124,14 @@ temp-dir = "0.1.11"
tempfile = "3.4.0"
testcontainers = "0.14"
thiserror = "1.0.38"
tmq = { version = "0.3.1", features = ["zmq-vendored"] }
tokio = { version = "1.27", features = [
"time",
"macros",
"rt-multi-thread",
"sync",
] }
tokio-stream = "0.1.11"
tokio-stream = { version = "0.1.11", features = ["sync"] }
toml = "0.7.3"
tracing = "0.1.37"
tracing-elastic-apm = "3.2.3"
Expand Down
8 changes: 6 additions & 2 deletions crates/api/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ async-graphql = { workspace = true, features = [
"uuid",
] }
async-graphql-poem = { workspace = true }
async-sawtooth-sdk = { path = "../async-sawtooth-sdk" }
async-sawtooth-sdk = { workspace = true }
async-stream = { workspace = true }
async-trait = { workspace = true }
base64 = { workspace = true }
Expand All @@ -39,6 +39,9 @@ opa = { workspace = true }
opentelemetry = { workspace = true }
parking_lot = { workspace = true }
poem = { workspace = true }
portpicker = { workspace = true }
prost = { workspace = true }
protobuf = { workspace = true }
r2d2 = { workspace = true }
rand = { workspace = true }
rand_core = { workspace = true }
Expand All @@ -50,6 +53,7 @@ serde_derive = { workspace = true }
serde_json = { workspace = true }
static-iref = { workspace = true }
thiserror = { workspace = true }
tmq = { workspace = true }
tokio = { workspace = true }
tokio-stream = { workspace = true }
tracing = { workspace = true }
Expand All @@ -58,8 +62,8 @@ user-error = { workspace = true }
uuid = { workspace = true }

[dev-dependencies]
chronicle-protocol = { path = "../chronicle-protocol" }
assert_fs = { workspace = true }
chronicle-protocol = { path = "../chronicle-protocol" }
insta = { workspace = true, features = ["json", "yaml"] }
opa-tp-protocol = { path = "../opa-tp-protocol" }
tempfile = { workspace = true }
Expand Down
Loading

0 comments on commit fbe90b1

Please sign in to comment.