Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use hickory-dns #61

Merged
merged 3 commits into from
Dec 9, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [0.9.0](https://github.com/TrueLayer/ginepro/compare/ginepro-v0.9.0...ginepro-v0.8.1) - 2024-12-09

### Other
- Replace `trust-dns-resolver` with `hickory-resolver`([#61](https://github.com/TrueLayer/ginepro/pull/61))

## [0.8.1](https://github.com/TrueLayer/ginepro/compare/ginepro-v0.8.0...ginepro-v0.8.1) - 2024-07-10

### Other
Expand Down
4 changes: 2 additions & 2 deletions ginepro/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "ginepro"
version = "0.8.1"
version = "0.9.0"
edition = "2021"
description = "A client-side gRPC channel implementation for tonic"
repository = "https://github.com/TrueLayer/ginepro"
Expand All @@ -18,7 +18,7 @@ tokio = { version = "1", features = ["full"] }
tonic = { version = "0.12", features = ["tls"] }
tower = { version = "0.4", default-features = false, features = ["discover"] }
tracing = "0.1"
trust-dns-resolver = "0.23"
hickory-resolver = { version = "0.24", features = ["tokio-runtime"] }

[dev-dependencies]
proptest = "1"
Expand Down
2 changes: 1 addition & 1 deletion ginepro/src/dns_resolver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

use crate::{LookupService, ServiceDefinition};
use anyhow::Context;
use hickory_resolver::{system_conf, AsyncResolver, TokioAsyncResolver};
use std::collections::HashSet;
use std::net::SocketAddr;
use trust_dns_resolver::{system_conf, AsyncResolver, TokioAsyncResolver};

/// Implements [`LookupService`] by using DNS queries to lookup [`ServiceDefinition::hostname`].
pub struct DnsResolver {
Expand Down
2 changes: 1 addition & 1 deletion ginepro/src/service_definition.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ impl ServiceDefinition {
pub fn from_parts<T: ToString>(hostname: T, port: u16) -> Result<Self, anyhow::Error> {
let hostname = hostname.to_string();

trust_dns_resolver::Name::from_ascii(&hostname)
hickory_resolver::Name::from_ascii(&hostname)
.map_err(anyhow::Error::from)
.context("invalid 'hostname'")?;

Expand Down
2 changes: 1 addition & 1 deletion shared_proto/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
tonic_build::configure()
.build_server(true)
.build_client(true)
.compile(&["proto/test.proto", "proto/echo.proto"], &["proto/"])?;
.compile_protos(&["proto/test.proto", "proto/echo.proto"], &["proto/"])?;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

compile is deprecated

Ok(())
}
Loading