From cc2d9bc7234e1d7f52538edab65648fc1199100b Mon Sep 17 00:00:00 2001 From: "R. Tyler Croy" Date: Tue, 29 Oct 2024 16:52:29 +0000 Subject: [PATCH] chore: allow kernel::visotors to be public for Snapshot usage The Snapshot.files() functrion is public but cannot be possibly used because the trait it relies upon isn't public. Oops! Signed-off-by: R. Tyler Croy Sponsored-by: Scribd Inc --- crates/core/src/kernel/snapshot/mod.rs | 2 +- crates/core/src/kernel/snapshot/visitors.rs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/core/src/kernel/snapshot/mod.rs b/crates/core/src/kernel/snapshot/mod.rs index dbd6662f2f..c7daa17bb7 100644 --- a/crates/core/src/kernel/snapshot/mod.rs +++ b/crates/core/src/kernel/snapshot/mod.rs @@ -48,7 +48,7 @@ pub(crate) mod log_segment; pub(crate) mod parse; mod replay; mod serde; -mod visitors; +pub mod visitors; /// A snapshot of a Delta table #[derive(Debug, Serialize, Deserialize, Clone, PartialEq)] diff --git a/crates/core/src/kernel/snapshot/visitors.rs b/crates/core/src/kernel/snapshot/visitors.rs index 1b68026a5b..fc2234a4e2 100644 --- a/crates/core/src/kernel/snapshot/visitors.rs +++ b/crates/core/src/kernel/snapshot/visitors.rs @@ -14,6 +14,7 @@ use crate::kernel::Transaction; /// Allows hooking into the reading of commit files and checkpoints whenever a table is loaded or updated. pub trait ReplayVisitor: std::fmt::Debug + Send + Sync { + /// Return an [Any] type fn as_any(&self) -> &dyn std::any::Any; /// Process a batch