Skip to content

Commit

Permalink
address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
karencfv committed Aug 20, 2024
1 parent ea32c0c commit dcd4f34
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions oximeter/collector/src/agent.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ use futures::TryStreamExt;
use internal_dns::resolver::Resolver;
use internal_dns::ServiceName;
use nexus_client::types::IdSortMode;
use omicron_common::address::CLICKHOUSE_PORT;
use omicron_common::address::NEXUS_INTERNAL_PORT;
use omicron_common::backoff;
use omicron_common::backoff::BackoffError;
Expand Down Expand Up @@ -396,16 +395,15 @@ impl OximeterAgent {
let db_address = if let Some(address) = db_config.address {
address
} else if replicated {
let mut address = resolver
.lookup_socket_v6(ServiceName::ClickhouseServer)
.await?;
address.set_port(CLICKHOUSE_PORT);
SocketAddr::V6(address)
SocketAddr::V6(
resolver
.lookup_socket_v6(ServiceName::ClickhouseServer)
.await?,
)
} else {
let mut address =
resolver.lookup_socket_v6(ServiceName::Clickhouse).await?;
address.set_port(CLICKHOUSE_PORT);
SocketAddr::V6(address)
SocketAddr::V6(
resolver.lookup_socket_v6(ServiceName::Clickhouse).await?,
)
};

// Determine the version of the database.
Expand Down

0 comments on commit dcd4f34

Please sign in to comment.