Skip to content

Commit 8c76b3d

Browse files
committed
chore: bump rustls and trust-dns deps
1 parent 01fa7be commit 8c76b3d

File tree

4 files changed

+12
-14
lines changed

4 files changed

+12
-14
lines changed

Cargo.toml

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "logdna-client"
3-
version = "0.7.3"
3+
version = "0.7.4"
44
authors = ["[email protected]"]
55
edition = "2018"
66
license = "MIT"
@@ -13,7 +13,7 @@ thiserror = "1"
1313
#io
1414
bytes = "1"
1515
tokio = "1"
16-
async-compression = {version = "0.3", features = ["futures-io", "gzip"]}
16+
async-compression = {version = "0.4", features = ["futures-io", "gzip"]}
1717

1818
# async
1919
futures = "0.3"
@@ -24,11 +24,11 @@ pin-project = "1"
2424
#http/net
2525
http = "0.2"
2626
hyper = { version = "0.14", features = ["client", "tcp", "http2"] }
27-
trust-dns-resolver = "0.22"
27+
trust-dns-resolver = { version = "0.23", features = ["tokio"] }
2828

2929
#tls
30-
rustls = "0.20"
31-
hyper-rustls = { version = "0.23", features = ["http2", "logging"] }
30+
rustls = "0.21"
31+
hyper-rustls = { version = "0.24", features = ["http2", "logging"] }
3232

3333
#utils
3434
backoff = "0.4"

docker/dispatch.sh

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
curpath=$(dirname "$0")
44

5+
# shellcheck disable=SC2317
56
_term() {
67
docker kill "$child"
78
status=$(docker inspect "$child" --format='{{.State.ExitCode}}')

src/body.rs

+1
Original file line numberDiff line numberDiff line change
@@ -844,6 +844,7 @@ pub(crate) mod test {
844844
}
845845

846846
//recursive JSON type
847+
#[allow(clippy::arc_with_non_send_sync)]
847848
pub fn json_st(depth: u32) -> impl Strategy<Value = serde_json::Value> {
848849
let leaf = prop_oneof![
849850
Just(serde_json::Value::Null),

src/dns.rs

+5-9
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ use tokio::sync::Mutex;
1313
use trust_dns_resolver::{
1414
config::{ResolverConfig, ResolverOpts},
1515
lookup_ip::LookupIpIntoIter,
16-
system_conf, AsyncResolver, TokioConnection, TokioConnectionProvider, TokioHandle,
16+
system_conf, TokioAsyncResolver,
1717
};
1818

1919
struct ResolverInner {
20-
resolver: AsyncResolver<TokioConnection, TokioConnectionProvider>,
20+
resolver: TokioAsyncResolver,
2121
backoff: ExponentialBackoff<SystemClock>,
2222
}
2323

@@ -109,8 +109,7 @@ impl Service<hyper_dns::Name> for TrustDnsResolver {
109109
{
110110
std::mem::swap(system_config, new_system_config);
111111
let (config, opts) = system_config.clone();
112-
resolver.resolver =
113-
AsyncResolver::new(config, opts, TokioHandle)?;
112+
resolver.resolver = TokioAsyncResolver::tokio(config, opts);
114113
}
115114
_ => (),
116115
}
@@ -140,16 +139,13 @@ impl Iterator for SocketAddrs {
140139
}
141140
}
142141

143-
async fn new_resolver() -> Result<
144-
AsyncResolver<TokioConnection, TokioConnectionProvider>,
145-
Box<dyn std::error::Error + Send + Sync>,
146-
> {
142+
async fn new_resolver() -> Result<TokioAsyncResolver, Box<dyn std::error::Error + Send + Sync>> {
147143
let (config, opts) = SYSTEM_CONF
148144
.lock()
149145
.expect("Failed to lock SYSTEM_CONF")
150146
.as_ref()
151147
.expect("can't construct TrustDnsResolver if SYSTEM_CONF is error")
152148
.clone();
153-
let resolver = AsyncResolver::new(config, opts, TokioHandle)?;
149+
let resolver = TokioAsyncResolver::tokio(config, opts);
154150
Ok(resolver)
155151
}

0 commit comments

Comments
 (0)