From ac6cf8a50df6392269404ad7d2bace64a80c0439 Mon Sep 17 00:00:00 2001 From: Chris Date: Mon, 12 Oct 2026 08:01:37 -0700 Subject: [PATCH 1/3] fix(test): discover data dirs by listing instead of info.data_dir (#8495) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The conditional_get_304_uses_metadata_without_decoding_damaged_data test constructed the data directory path from info.data_dir.to_string(), but the on-disk directory name may not match the UUID string form. Switch to iterating subdirectories of the object path (matching the delete_object_part_shards helper) so the test is robust regardless of the data_dir naming convention. Verified: cargo nextest run -p rustfs -- conditional_get_304 → PASS --- rustfs/src/app/object/get.rs | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/rustfs/src/app/object/get.rs b/rustfs/src/app/object/get.rs index edbc2e03b..b26b72103 100644 --- a/rustfs/src/app/object/get.rs +++ b/rustfs/src/app/object/get.rs @@ -5893,8 +5893,18 @@ mod tests { *metadata.last_mut().expect("inline data bytes") ^= 1; tokio::fs::write(&meta_path, metadata).await.expect("damage inline payload"); } else { - let data_path = object_path.join(info.data_dir.expect("sharded object data directory").to_string()); - tokio::fs::remove_dir_all(data_path).await.expect("remove object data shards"); + // Discover version data dirs by listing the object directory + // (matching delete_object_part_shards) instead of constructing + // the path from info.data_dir, whose UUID string form may not + // match the on-disk directory name. + let mut entries = tokio::fs::read_dir(&object_path).await.expect("read object dir"); + while let Some(entry) = entries.next_entry().await.expect("read object dir entry") { + if entry.file_type().await.expect("entry file type").is_dir() { + tokio::fs::remove_dir_all(entry.path()) + .await + .expect("remove object data shards"); + } + } } } let resolved = store From d6fe5c30ce722d7f3773984b7d0f1912d63e30ae Mon Sep 17 00:00:00 2001 From: Hauser Date: Mon, 12 Oct 2026 23:02:02 +0800 Subject: [PATCH 2/3] test(e2e): borrow URLs in internode RPC helpers (#8497) Pass existing string slices directly to the client constructor to satisfy strict Clippy without temporary allocations. Co-authored-by: heihutu Co-authored-by: zhi22915 --- crates/e2e_test/src/internode_rpc_signature_e2e_test.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/e2e_test/src/internode_rpc_signature_e2e_test.rs b/crates/e2e_test/src/internode_rpc_signature_e2e_test.rs index a311aa76e..dcc911e77 100644 --- a/crates/e2e_test/src/internode_rpc_signature_e2e_test.rs +++ b/crates/e2e_test/src/internode_rpc_signature_e2e_test.rs @@ -264,7 +264,7 @@ async fn call_make_volume_response( request: MakeVolumeRequest, headers: HeaderMap, ) -> Result, Status> { - let mut client = node_service_time_out_client_no_auth(&url.to_string()) + let mut client = node_service_time_out_client_no_auth(url) .await .map_err(|err| Status::unavailable(format!("cannot reach the node service: {err}")))?; let mut rpc_request = Request::new(request); @@ -273,7 +273,7 @@ async fn call_make_volume_response( } async fn call_ping_response(url: &str, headers: HeaderMap) -> Result, Status> { - let mut client = node_service_time_out_client_no_auth(&url.to_string()) + let mut client = node_service_time_out_client_no_auth(url) .await .map_err(|err| Status::unavailable(format!("cannot reach the node service: {err}")))?; let mut rpc_request = Request::new(PingRequest { From 5d8e143505205d2f21f6f32a33f6aee9f29482b0 Mon Sep 17 00:00:00 2001 From: GatewayJ <835269233@qq.com> Date: Mon, 12 Oct 2026 23:07:46 +0800 Subject: [PATCH 3/3] fix(admin): add OIDC policy log fields (#8496) --- rustfs/src/admin/service/federated_identity.rs | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/rustfs/src/admin/service/federated_identity.rs b/rustfs/src/admin/service/federated_identity.rs index 7417a7322..cdc197633 100644 --- a/rustfs/src/admin/service/federated_identity.rs +++ b/rustfs/src/admin/service/federated_identity.rs @@ -30,6 +30,10 @@ use std::collections::{BTreeMap, HashMap}; use time::{Duration, OffsetDateTime}; use tracing::{debug, warn}; +const LOG_COMPONENT_ADMIN: &str = "admin"; +const LOG_SUBSYSTEM_OIDC: &str = "oidc"; +const EVENT_ADMIN_OIDC_POLICY: &str = "admin_oidc_policy"; + pub(crate) struct DefaultFederatedSessionBinding; // Legacy receivers reject an empty parsed mapping; current receivers ignore it when the virtual-parent marker is present. @@ -339,6 +343,9 @@ impl FederatedSessionBinding for DefaultFederatedSessionBinding { for policy_name in &selected_policy_names { let exists = iam_store.policy_exists(policy_name).await.map_err(|err| { warn!( + event = EVENT_ADMIN_OIDC_POLICY, + component = LOG_COMPONENT_ADMIN, + subsystem = LOG_SUBSYSTEM_OIDC, provider_id = %authorization.provider_id, parent_user = %parent_user, policy = %policy_name, @@ -367,6 +374,9 @@ impl FederatedSessionBinding for DefaultFederatedSessionBinding { .map_err(|rejection| match rejection { OidcPolicyRejection::Unsupported(policy_names) => { warn!( + event = EVENT_ADMIN_OIDC_POLICY, + component = LOG_COMPONENT_ADMIN, + subsystem = LOG_SUBSYSTEM_OIDC, provider_id = %authorization.provider_id, parent_user = %parent_user, unsupported_policies = ?policy_names, @@ -376,6 +386,9 @@ impl FederatedSessionBinding for DefaultFederatedSessionBinding { } OidcPolicyRejection::Unresolved(policy_names) => { debug!( + event = EVENT_ADMIN_OIDC_POLICY, + component = LOG_COMPONENT_ADMIN, + subsystem = LOG_SUBSYSTEM_OIDC, provider_id = %authorization.provider_id, parent_user = %parent_user, unresolved_policies = ?policy_names, @@ -389,6 +402,9 @@ impl FederatedSessionBinding for DefaultFederatedSessionBinding { })?; if !selection.ignored.is_empty() { debug!( + event = EVENT_ADMIN_OIDC_POLICY, + component = LOG_COMPONENT_ADMIN, + subsystem = LOG_SUBSYSTEM_OIDC, provider_id = %authorization.provider_id, parent_user = %parent_user, ignored_group_policies = ?selection.ignored,