From 64c815dd50a0c6b6d123111c3f39741c2575be06 Mon Sep 17 00:00:00 2001 From: Marco Neumann Date: Tue, 15 Jun 2021 12:26:30 +0200 Subject: [PATCH] fix: bump catalog version (#1726) This should have been done in #1714. Also add a note so that future devs might hopefully not forget. In any case though the code also works w/o this bump, it's just that the error message is a bit less nice ("cannot parse IOxMetadata" instead of "unsupported catalog version"). Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> --- parquet_file/src/catalog.rs | 2 +- parquet_file/src/metadata.rs | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/parquet_file/src/catalog.rs b/parquet_file/src/catalog.rs index f79a945960..03a85d9655 100644 --- a/parquet_file/src/catalog.rs +++ b/parquet_file/src/catalog.rs @@ -31,7 +31,7 @@ use uuid::Uuid; /// Current version for serialized transactions. /// /// For breaking changes, this will change. -pub const TRANSACTION_VERSION: u32 = 3; +pub const TRANSACTION_VERSION: u32 = 4; /// File suffix for transaction files in object store. pub const TRANSACTION_FILE_SUFFIX: &str = "txn"; diff --git a/parquet_file/src/metadata.rs b/parquet_file/src/metadata.rs index f8af37d57b..7fca9d4471 100644 --- a/parquet_file/src/metadata.rs +++ b/parquet_file/src/metadata.rs @@ -210,6 +210,9 @@ pub type Result = std::result::Result; /// /// This will serialized as [JSON] into the file-level key-value Parquet metadata (under [`METADATA_KEY`]). /// +/// **Important: When changing this structure, consider bumping the +/// [catalog transaction version](crate::catalog::TRANSACTION_VERSION)!** +/// /// [JSON]: https://www.json.org/ #[allow(missing_copy_implementations)] // we want to extend this type in the future #[derive(Serialize, Deserialize, Debug, Clone, Eq, PartialEq)]