Repository navigation
Closed
Description
The sync NATS crate currently in use is deprecated and doesn't receive updates anymore. While it works, it causes problems when cargo updateing as the nuid package is incompatible with a newer rand version. Automated update PRs such as #189 fail with:
error[E0432]: unresolved import `rand::distributions`
--> /home/runner/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/nuid-0.3.2/src/lib.rs:19:11
|
19 | use rand::distributions::Alphanumeric;
| ^^^^^^^^^^^^^ could not find `distributions` in `rand`
error[E0599]: the method `sample_iter` exists for struct `OsRng`, but its trait bounds were not satisfied
--> /home/runner/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/nuid-0.3.2/src/lib.rs:82:27
|
82 | for (i, n) in rng.sample_iter(&Alphanumeric).take(PRE_LEN).enumerate() {
| ^^^^^^^^^^^ method cannot be called on `OsRng` due to unsatisfied trait bounds
|
::: /home/runner/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/rand_core-0.9.3/src/os.rs:47:1
|
47 | pub struct OsRng;
| ---------------- doesn't satisfy `OsRng: RngCore` or `OsRng: Rng`
|
= note: the following trait bounds were not satisfied:
`OsRng: RngCore`
which is required by `OsRng: Rng`
`&OsRng: RngCore`
which is required by `&OsRng: Rng`
`&mut OsRng: RngCore`
which is required by `&mut OsRng: Rng`
Some errors have detailed explanations: E0432, E0599.
For more information about an error, try `rustc --explain E0432`.
error: could not compile `nuid` (lib) due to 2 previous errors
A work around is running cargo update [email protected] once, but ideally we'd switch to the maintained async-nats crate.
See also nats-io/nats.rs#1378 and nats-io/nats.rs#1375
PR #191 uses async-nats and tokio. Other tools and extractor can be switchted, once this is merged.
Progress:
-
rpcextractor Add basic RPC extractor with getpeerinfo support #191 -
metricstool Add first integration tests formetricstool #222 -
websockettool refactor: useasync_natsin websocket tool #224 -
loggertool refactor: use async_nats in logger tool #225 -
connectivity-checktool refactor: use async_nats in connectivity-check tool #226 -
ebpfextractor refactor: use async_nats in ebpf-extractor #228
Metadata
Metadata
Assignees
Labels
No labels
Activity
add: ebpf-extractor docs
add: ebpf-extractor docs
0xB10C commentedon Aug 11, 2025
This shouldn't have been closed - #202 should have been closed instead.
change: use async_nats in metrics
change: use async_nats in metrics
change: use async_nats in metrics
add: ebpf-extractor docs
change: use async_nats in metrics
refactor: use async_nats in websocket tool
refactor: use async_nats in websocket tool
refactor: use async_nats in logger tool
refactor: use async_nats in connectivity-check tool
refactor: use async_nats in websocket tool
refactor: use async_nats in logger tool
refactor: use async_nats in connectivity-check tool
refactor: use async_nats in ebpf-extractor
refactor: use async_nats in ebpf-extractor
refactor: use async_nats in ebpf-extractor
refactor: use async_nats in ebpf-extractor
remove: dependency on nats create
refactor: use async_nats in ebpf-extractor
remove: dependency on nats create