Skip to content

Commit 134006e

Browse files
antiguruclaude
andauthored
cluster-client: move GrpcClientParameters from mz-service (#39457)
`mz-storage-types` depended on `mz-service` only for `GrpcClientParameters`, a plain serde struct. Moving it to `mz-cluster-client`, the crate for types shared by compute and storage, drops `mz-storage-types -> mz-service` and `mz-adapter -> mz-service`. `mz-cluster-client` only depends on `mz-ore` and `mz-repr`, which `mz-storage-types` already uses, so no new transitive dependencies appear. Found with `bin/crate-cuts` (#39447). Touches `mz-cluster-client` like #39449 and #39451, so later ones need a trivial rebase. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 <[email protected]>
1 parent 0acf50c commit 134006e

11 files changed

Lines changed: 8 additions & 10 deletions

File tree

‎Cargo.lock‎

Lines changed: 0 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎src/adapter/Cargo.toml‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@ mz-repr = { path = "../repr", features = ["tracing"] }
6666
mz-rocksdb-types = { path = "../rocksdb-types" }
6767
mz-secrets = { path = "../secrets" }
6868
mz-segment = { path = "../segment" }
69-
mz-service = { path = "../service" }
7069
mz-sql = { path = "../sql" }
7170
mz-sql-parser = { path = "../sql-parser" }
7271
mz-sql-server-util = { path = "../sql-server-util"}

‎src/adapter/src/flags.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
use std::time::Duration;
1111

1212
use mz_adapter_types::dyncfgs::PG_TIMESTAMP_ORACLE_STATEMENT_TIMEOUT;
13+
use mz_cluster_client::params::GrpcClientParameters;
1314
use mz_compute_client::protocol::command::ComputeParameters;
1415
use mz_orchestrator::scheduling_config::{ServiceSchedulingConfig, ServiceTopologySpreadConfig};
1516
use mz_ore::cast::CastFrom;
1617
use mz_ore::error::ErrorExt;
17-
use mz_service::params::GrpcClientParameters;
1818
use mz_sql::session::vars::SystemVars;
1919
use mz_storage_types::parameters::{
2020
PgSourceSnapshotConfig, StorageMaxInflightBytesConfig, StorageParameters,

‎src/cluster-client/src/lib.rs‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ use serde::{Deserialize, Serialize};
2424
pub mod client;
2525
pub mod instances;
2626
pub mod metrics;
27+
pub mod params;
2728

2829
/// A function that computes the lag between the given time and wallclock time.
2930
///
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
// the Business Source License, use of this software will be governed
88
// by the Apache License, Version 2.0.
99

10+
//! gRPC client parameters shared by compute and storage.
11+
1012
use serde::{Deserialize, Serialize};
1113
use std::time::Duration;
1214

‎src/compute-client/src/controller/replica.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ use std::time::{Duration, Instant};
1616
use anyhow::bail;
1717
use mz_build_info::BuildInfo;
1818
use mz_cluster_client::client::ClusterReplicaLocation;
19+
use mz_cluster_client::params::GrpcClientParameters;
1920
use mz_compute_types::dyncfgs::ENABLE_COMPUTE_REPLICA_EXPIRATION;
2021
use mz_dyncfg::{ConfigSet, ConfigUpdates};
2122
use mz_ore::channel::InstrumentedUnboundedSender;
2223
use mz_ore::retry::{Retry, RetryState};
2324
use mz_ore::task::AbortOnDropHandle;
2425
use mz_service::client::{GenericClient, Partitioned};
25-
use mz_service::params::GrpcClientParameters;
2626
use mz_service::transport;
2727
use tokio::select;
2828
use tokio::sync::mpsc::error::SendError;

‎src/compute-client/src/protocol/command.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@
1212
use std::time::Duration;
1313

1414
use mz_cluster_client::client::TryIntoProtocolNonce;
15+
use mz_cluster_client::params::GrpcClientParameters;
1516
use mz_compute_types::dataflows::DataflowDescription;
1617
use mz_compute_types::plan::render_plan::RenderPlan;
1718
use mz_dyncfg::ConfigUpdates;
1819
use mz_expr::RowSetFinishing;
1920
use mz_ore::tracing::OpenTelemetryContext;
2021
use mz_persist_types::PersistLocation;
2122
use mz_repr::{GlobalId, RelationDesc, Row, Timestamp};
22-
use mz_service::params::GrpcClientParameters;
2323
use mz_storage_types::controller::CollectionMetadata;
2424
use mz_tracing::params::TracingParameters;
2525
use serde::{Deserialize, Serialize};

‎src/service/src/lib.rs‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,5 @@
1616
pub mod boot;
1717
pub mod client;
1818
pub mod local;
19-
pub mod params;
2019
pub mod retry;
2120
pub mod transport;

‎src/storage-controller/src/instance.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,14 @@ use itertools::Itertools;
2020
use mz_build_info::BuildInfo;
2121
use mz_cluster_client::ReplicaId;
2222
use mz_cluster_client::client::ClusterReplicaLocation;
23+
use mz_cluster_client::params::GrpcClientParameters;
2324
use mz_dyncfg::ConfigUpdates;
2425
use mz_ore::cast::CastFrom;
2526
use mz_ore::now::NowFn;
2627
use mz_ore::retry::{Retry, RetryState};
2728
use mz_ore::task::AbortOnDropHandle;
2829
use mz_repr::{GlobalId, Timestamp};
2930
use mz_service::client::{GenericClient, Partitioned};
30-
use mz_service::params::GrpcClientParameters;
3131
use mz_service::transport;
3232
use mz_storage_client::client::{
3333
RunIngestionCommand, RunSinkCommand, Status, StatusUpdate, StorageCommand, StorageResponse,

‎src/storage-types/Cargo.toml‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ mz-proto = { path = "../proto" }
5252
mz-repr = { path = "../repr" }
5353
mz-rocksdb-types = { path = "../rocksdb-types" }
5454
mz-secrets = { path = "../secrets" }
55-
mz-service = { path = "../service" }
5655
mz-ssh-util = { path = "../ssh-util" }
5756
mz-sql-parser = { path = "../sql-parser" }
5857
mz-sql-server-util = { path = "../sql-server-util" }

0 commit comments

Comments
 (0)