diff --git a/async-nats/Cargo.toml b/async-nats/Cargo.toml index d61882ea9..d24573d32 100644 --- a/async-nats/Cargo.toml +++ b/async-nats/Cargo.toml @@ -3,7 +3,7 @@ name = "async-nats" authors = ["Tomasz Pietrek ", "Casper Beyer "] version = "0.35.1" edition = "2021" -rust = "1.67.0" +rust = "1.74.0" description = "A async Rust NATS client" license = "Apache-2.0" documentation = "https://docs.rs/async-nats" diff --git a/async-nats/tests/compatibility.rs b/async-nats/tests/compatibility.rs index 9d6a7612a..e433fc30c 100644 --- a/async-nats/tests/compatibility.rs +++ b/async-nats/tests/compatibility.rs @@ -41,7 +41,12 @@ mod compatibility { .init(); let url = std::env::var("NATS_URL").unwrap_or_else(|_| "localhost:4222".to_string()); tracing::info!("staring client for object store tests at {}", url); - let client = async_nats::connect(url).await.unwrap(); + let client = async_nats::ConnectOptions::new() + .max_reconnects(10) + .retry_on_initial_connect() + .connect(&url) + .await + .unwrap(); let tests = client .subscribe("tests.object-store.>") @@ -422,7 +427,12 @@ mod compatibility { async fn service_core() { let url = std::env::var("NATS_URL").unwrap_or_else(|_| "localhost:4222".to_string()); tracing::info!("staring client for service tests at {}", url); - let client = async_nats::connect(url).await.unwrap(); + let client = async_nats::ConnectOptions::new() + .max_reconnects(10) + .retry_on_initial_connect() + .connect(&url) + .await + .unwrap(); let mut tests = client .subscribe("tests.service.core.>") diff --git a/async-nats/tests/configs/docker/Dockerfile b/async-nats/tests/configs/docker/Dockerfile index 3203f9cbd..766975d26 100644 --- a/async-nats/tests/configs/docker/Dockerfile +++ b/async-nats/tests/configs/docker/Dockerfile @@ -1,7 +1,7 @@ -FROM rust:1.71.1 +FROM rust:1.78 WORKDIR /usr/src/nats.rs/async-nats ARG PROFILE=test COPY . /usr/src/nats.rs RUN cargo test --features compatibility_tests --no-run ENV NATS_URL=localhost:4222 -CMD cargo test --features compatibility_tests compatibility -- --nocapture \ No newline at end of file +CMD cargo test --features compatibility_tests compatibility -- --nocapture