Skip to content
Closed
Show file tree
Hide file tree
Changes from all 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
385 changes: 106 additions & 279 deletions Cargo.lock

Large diffs are not rendered by default.

10 changes: 4 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -473,10 +473,10 @@ crossterm = { version = "0.29.0", features = ["event-stream"] }
# NOTE: if you change the pinned revision of the `crucible` dependencies, you
# must also update the references in package-manifest.toml to match the new
# revision.
crucible-agent-client = { git = "https://github.com/oxidecomputer/crucible", rev = "7103cd3a3d7b0112d2949dd135db06fef0c156bb" }
crucible-pantry-client = { git = "https://github.com/oxidecomputer/crucible", rev = "7103cd3a3d7b0112d2949dd135db06fef0c156bb" }
crucible-smf = { git = "https://github.com/oxidecomputer/crucible", rev = "7103cd3a3d7b0112d2949dd135db06fef0c156bb" }
crucible-common = { git = "https://github.com/oxidecomputer/crucible", rev = "7103cd3a3d7b0112d2949dd135db06fef0c156bb" }
crucible-agent-client = { git = "https://github.com/oxidecomputer/crucible", rev = "fefccc0623038371dbded0458f0645bee6b141cb" }
crucible-pantry-client = { git = "https://github.com/oxidecomputer/crucible", rev = "fefccc0623038371dbded0458f0645bee6b141cb" }
crucible-smf = { git = "https://github.com/oxidecomputer/crucible", rev = "fefccc0623038371dbded0458f0645bee6b141cb" }
crucible-common = { git = "https://github.com/oxidecomputer/crucible", rev = "fefccc0623038371dbded0458f0645bee6b141cb" }
# NOTE: See above!
csv = "1.3.1"
curve25519-dalek = "4"
Expand Down Expand Up @@ -717,7 +717,6 @@ proc-macro2 = "1.0"
progenitor = "0.14.0"
progenitor-client = "0.14.0"
progenitor-extras = "0.2.0"
progenitor-client010 = { package = "progenitor-client", version = "0.10.0" }
# NOTE: if you change the pinned revision of the `bhyve_api` and propolis
# dependencies, you must also update the references in package-manifest.toml to
# match the new revision.
Expand Down Expand Up @@ -751,7 +750,6 @@ regress = "0.10.4"
repo-depot-api = { path = "sled-agent/repo-depot-api" }
repo-depot-client = { path = "clients/repo-depot-client" }
reqwest = { version = "0.13", default-features = false }
reqwest012 = { package = "reqwest", version = "0.12", default-features = false }
ring = "0.17.14"
rpassword = "7.4.0"
rstest = "0.25.0"
Expand Down
1 change: 0 additions & 1 deletion common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ tokio = { workspace = true, features = ["full"] }
uuid.workspace = true
parse-display.workspace = true
progenitor-client.workspace = true
progenitor-client010.workspace = true
progenitor-extras.workspace = true
omicron-workspace-hack.workspace = true
regress.workspace = true
Expand Down
36 changes: 0 additions & 36 deletions common/src/api/external/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -547,42 +547,6 @@ pub trait ClientError: std::fmt::Debug {
// external client, others may require, for example, retries with an alternate
// service instance or additional interpretation to sanitize the output error.
// This should be removed to avoid leaking data.
impl<T: ClientError> From<progenitor_client010::Error<T>> for Error {
fn from(e: progenitor_client010::Error<T>) -> Self {
match e {
// For most error variants, we delegate to the display impl for the
// Progenitor error type, but we pick apart an error response more
// carefully.
progenitor_client010::Error::InvalidRequest(_)
| progenitor_client010::Error::CommunicationError(_)
| progenitor_client010::Error::InvalidResponsePayload(..)
| progenitor_client010::Error::UnexpectedResponse(_)
| progenitor_client010::Error::InvalidUpgrade(_)
| progenitor_client010::Error::ResponseBodyError(_)
| progenitor_client010::Error::PreHookError(_)
| progenitor_client010::Error::PostHookError(_) => {
Error::internal_error(&e.to_string())
}
// This error represents an expected error from the remote service.
progenitor_client010::Error::ErrorResponse(rv) => {
let message = rv.message();

match rv.status() {
http::StatusCode::SERVICE_UNAVAILABLE => {
Error::unavail(&message)
}
status if status.is_client_error() => {
Error::invalid_request(&message)
}
_ => Error::internal_error(&message),
}
}
}
}
}

// Equivalent From impl for progenitor-client 0.13. This coexists with the
// progenitor_client010 impl above during the cross-repo upgrade window.
impl<T: ClientError> From<progenitor_client::Error<T>> for Error {
fn from(e: progenitor_client::Error<T>) -> Self {
match e {
Expand Down
18 changes: 9 additions & 9 deletions common/src/progenitor_operation_retry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ pub enum ProgenitorOperationRetryError<E> {

/// The retry loop progenitor operation saw a permanent client error
#[error("permanent error")]
ProgenitorError(#[source] progenitor_client010::Error<E>),
ProgenitorError(#[source] progenitor_client::Error<E>),
}

impl<E> ProgenitorOperationRetryError<E> {
pub fn is_not_found(&self) -> bool {
match &self {
ProgenitorOperationRetryError::ProgenitorError(e) => match e {
progenitor_client010::Error::ErrorResponse(rv) => {
progenitor_client::Error::ErrorResponse(rv) => {
match rv.status() {
http::StatusCode::NOT_FOUND => true,

Expand Down Expand Up @@ -70,7 +70,7 @@ pub struct ProgenitorOperationRetry<
T,
E: std::fmt::Debug,
F: FnMut() -> Fut,
Fut: Future<Output = Result<T, progenitor_client010::Error<E>>>,
Fut: Future<Output = Result<T, progenitor_client::Error<E>>>,
BF: FnMut() -> BFut,
BFut: Future<Output = Result<bool, Error>>,
> {
Expand All @@ -85,7 +85,7 @@ impl<T, E, F, Fut, BF, BFut> ProgenitorOperationRetry<T, E, F, Fut, BF, BFut>
where
E: std::fmt::Debug + 'static,
F: FnMut() -> Fut,
Fut: Future<Output = Result<T, progenitor_client010::Error<E>>>,
Fut: Future<Output = Result<T, progenitor_client::Error<E>>>,
BF: FnMut() -> BFut,
BFut: Future<Output = Result<bool, Error>>,
{
Expand Down Expand Up @@ -121,7 +121,7 @@ where
}

match f.await {
Err(progenitor_client010::Error::CommunicationError(e)) => {
Err(progenitor_client::Error::CommunicationError(e)) => {
warn!(
log,
"saw transient communication error, retrying...";
Expand All @@ -130,12 +130,12 @@ where

Err(BackoffError::transient(
ProgenitorOperationRetryError::ProgenitorError(
progenitor_client010::Error::CommunicationError(e)
progenitor_client::Error::CommunicationError(e)
)
))
}

Err(progenitor_client010::Error::ErrorResponse(
Err(progenitor_client::Error::ErrorResponse(
response_value,
)) => {
match response_value.status() {
Expand All @@ -144,7 +144,7 @@ where
| http::StatusCode::TOO_MANY_REQUESTS => {
Err(BackoffError::transient(
ProgenitorOperationRetryError::ProgenitorError(
progenitor_client010::Error::ErrorResponse(
progenitor_client::Error::ErrorResponse(
response_value
)
)
Expand All @@ -154,7 +154,7 @@ where
// Anything else is a permanent error
_ => Err(BackoffError::Permanent(
ProgenitorOperationRetryError::ProgenitorError(
progenitor_client010::Error::ErrorResponse(
progenitor_client::Error::ErrorResponse(
response_value
)
)
Expand Down
2 changes: 1 addition & 1 deletion dev-tools/omdb/src/bin/omdb/crucible_pantry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ async fn cmd_volume_info(
args: &VolumeArgs,
) -> Result<(), anyhow::Error> {
let volume = args.uuid.to_string();
let VolumeStatus { active, num_job_handles, seen_active } =
let VolumeStatus { active, num_job_handles, seen_active, info: _ } =
*client.volume_status(&volume).await.context("listing volumes")?;

println!(" active: {}", active);
Expand Down
1 change: 0 additions & 1 deletion nexus/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ ref-cast.workspace = true
rdb-types.workspace = true
regex.workspace = true
reqwest = { workspace = true, features = ["http2", "json"] }
reqwest012 = { workspace = true }
ring.workspace = true
samael.workspace = true
schemars = { workspace = true, features = ["chrono", "uuid1"] }
Expand Down
4 changes: 1 addition & 3 deletions nexus/src/app/crucible.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,9 @@ impl super::Nexus {
&self,
dataset: &db::model::CrucibleDataset,
) -> CrucibleAgentClient {
// Use reqwest012_client because the rev-pinned crucible-agent-client
// is still on reqwest 0.12.
CrucibleAgentClient::new_with_client(
&format!("http://{}", dataset.address()),
self.reqwest012_client.clone(),
self.reqwest_client.clone(),
)
}

Expand Down
5 changes: 1 addition & 4 deletions nexus/src/app/disk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -563,12 +563,9 @@ impl super::Nexus {
// fails, then that failure would be propagated up to the user, and
// that user's program can act accordingly. In a way, the user's
// program is an externally driven saga instead.

// Use reqwest012_client because the rev-pinned
// crucible-pantry-client is still on reqwest 0.12.
let client = crucible_pantry_client::Client::new_with_client(
&format!("http://{}", endpoint),
self.reqwest012_client.clone(),
self.reqwest_client.clone(),
);
let request = crucible_pantry_client::types::BulkWriteRequest {
offset: param.offset,
Expand Down
19 changes: 0 additions & 19 deletions nexus/src/app/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -223,18 +223,8 @@ pub struct Nexus {
///
/// (This does not need to be in an `Arc` because `reqwest::Client` uses
/// `Arc` internally.)
///
/// Currently unused because all `new_with_client` call sites use
/// `reqwest012_client` for cross-repo dependencies that are still on
/// reqwest 0.12. This field will be used again once rev pins are updated.
#[allow(dead_code)]
reqwest_client: reqwest::Client,

/// `reqwest012::Client` for cross-repo dependencies where the rev-pinned
/// dependency is still on reqwest 0.12. Remove once all rev pins are
/// updated.
reqwest012_client: reqwest012::Client,

/// Client to the timeseries database.
timeseries_client: oximeter_db::Client,

Expand Down Expand Up @@ -436,14 +426,6 @@ impl Nexus {
.build()
.map_err(|e| InlineErrorChain::new(&e).to_string())?;

// reqwest 0.12 client for cross-repo dependencies still on reqwest
// 0.12. Remove once all rev pins are updated.
let reqwest012_client = reqwest012::ClientBuilder::new()
.connect_timeout(std::time::Duration::from_secs(15))
.timeout(std::time::Duration::from_secs(15))
.build()
.map_err(|e| InlineErrorChain::new(&e).to_string())?;

// Client to the ClickHouse database.
let timeseries_client = match &config.pkg.timeseries_db.address {
None => {
Expand Down Expand Up @@ -548,7 +530,6 @@ impl Nexus {
producer_server: std::sync::Mutex::new(None),
populate_status,
reqwest_client,
reqwest012_client,
timeseries_client,
webhook_delivery_client,
tunables: config.pkg.tunables.clone(),
Expand Down
12 changes: 6 additions & 6 deletions package-manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -624,10 +624,10 @@ only_for_targets.image = "standard"
# 3. Use source.type = "manual" instead of "prebuilt"
source.type = "prebuilt"
source.repo = "crucible"
source.commit = "7103cd3a3d7b0112d2949dd135db06fef0c156bb"
source.commit = "fefccc0623038371dbded0458f0645bee6b141cb"
# The SHA256 digest is automatically posted to:
# https://buildomat.eng.oxide.computer/public/file/oxidecomputer/crucible/image/<commit>/crucible.sha256.txt
source.sha256 = "8e245572e4b8d1c018884268a6afdf7f79efc22e61b4ed5b5526957bf61ccdcd"
source.sha256 = "e4cbb6e0e5fa023f63a9c30ec9f9303521140ec6e5a6f4481bd89b8527f65b22"
output.type = "zone"
output.intermediate_only = true

Expand All @@ -636,10 +636,10 @@ service_name = "crucible_pantry_prebuilt"
only_for_targets.image = "standard"
source.type = "prebuilt"
source.repo = "crucible"
source.commit = "7103cd3a3d7b0112d2949dd135db06fef0c156bb"
source.commit = "fefccc0623038371dbded0458f0645bee6b141cb"
# The SHA256 digest is automatically posted to:
# https://buildomat.eng.oxide.computer/public/file/oxidecomputer/crucible/image/<commit>/crucible-pantry.sha256.txt
source.sha256 = "7998ddb0bda4c97e3d5fec7c8079bbdfb27ef06dba69ab2867278dc2cd7544f4"
source.sha256 = "060ae649f4ac6dbf94fcd7844df7b07f4570d74e4947229db7f177480eaf5253"
output.type = "zone"
output.intermediate_only = true

Expand All @@ -653,10 +653,10 @@ service_name = "crucible_utils"
only_for_targets.image = "standard"
source.type = "prebuilt"
source.repo = "crucible"
source.commit = "7103cd3a3d7b0112d2949dd135db06fef0c156bb"
source.commit = "fefccc0623038371dbded0458f0645bee6b141cb"
# The SHA256 digest is automatically posted to:
# https://buildomat.eng.oxide.computer/public/file/oxidecomputer/crucible/image/<commit>/crucible-utils.sha256.txt
source.sha256 = "cc661b84fd258467ec1961e8c9879f76d2d07903fb9161012afa75c37490e24f"
source.sha256 = "703b84d5d3a8fc5a1d4816cbeb096e035038c88ffa46bc56fb90dfe7b9a55511"
output.type = "tarball"

# Refer to
Expand Down
1 change: 0 additions & 1 deletion sled-agent/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ range-requests.workspace = true
repo-depot-api.workspace = true
repo-depot-client.workspace = true
reqwest = { workspace = true, features = ["rustls", "stream"] }
reqwest012 = { workspace = true }
schemars = { workspace = true, features = ["chrono", "uuid1"] }
serde.workspace = true
serde_json = { workspace = true, features = ["raw_value"] }
Expand Down
Loading
Loading