This is an automated email from the ASF dual-hosted git repository.

leekeiabstraction pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fluss-rust.git


The following commit(s) were added to refs/heads/main by this push:
     new 1697ac29 chore: [ci] Fix rustdoc warning and promote warning to error 
in CI (#576)
1697ac29 is described below

commit 1697ac29b693c14ec5b50681db68cb5ac81dbc6c
Author: Kaiqi Dong <[email protected]>
AuthorDate: Thu May 28 22:51:31 2026 +0200

    chore: [ci] Fix rustdoc warning and promote warning to error in CI (#576)
    
    * fix rustdoc and promote warning to error in ci
    
    * address comments
---
 .github/workflows/check_license_and_formatting.yml       |  6 ++++++
 crates/fluss/src/record/kv/mod.rs                        |  2 +-
 crates/fluss/src/record/kv/value_record_batch.rs         | 10 +++++-----
 crates/fluss/src/row/binary/iceberg_binary_row_writer.rs |  3 +--
 4 files changed, 13 insertions(+), 8 deletions(-)

diff --git a/.github/workflows/check_license_and_formatting.yml 
b/.github/workflows/check_license_and_formatting.yml
index 784e778e..881af9f9 100644
--- a/.github/workflows/check_license_and_formatting.yml
+++ b/.github/workflows/check_license_and_formatting.yml
@@ -66,3 +66,9 @@ jobs:
 
       - name: Clippy
         run: cargo clippy --all-targets --workspace -- -D warnings
+
+      - name: Rustdoc
+        # fluss_python is excluded: its [lib] name = "fluss" collides with 
fluss-rs
+        run: cargo doc --workspace --no-deps --exclude fluss_python
+        env:
+          RUSTDOCFLAGS: -D warnings
diff --git a/crates/fluss/src/record/kv/mod.rs 
b/crates/fluss/src/record/kv/mod.rs
index 8f7750a8..4d0f8946 100644
--- a/crates/fluss/src/record/kv/mod.rs
+++ b/crates/fluss/src/record/kv/mod.rs
@@ -32,7 +32,7 @@ pub use kv_record_batch::*;
 pub use kv_record_batch_builder::*;
 pub use kv_record_read_context::{KvRecordReadContext, SchemaGetter};
 pub use read_context::ReadContext;
-pub use value_record_batch::ValueRecordBatch;
+pub(crate) use value_record_batch::ValueRecordBatch;
 
 /// Current KV magic value
 pub const CURRENT_KV_MAGIC_VALUE: u8 = 0;
diff --git a/crates/fluss/src/record/kv/value_record_batch.rs 
b/crates/fluss/src/record/kv/value_record_batch.rs
index cfcb4a6d..fdd6b070 100644
--- a/crates/fluss/src/record/kv/value_record_batch.rs
+++ b/crates/fluss/src/record/kv/value_record_batch.rs
@@ -50,18 +50,18 @@ const RECORD_BATCH_HEADER_SIZE: usize = LENGTH_LENGTH + 
MAGIC_LENGTH + RECORD_CO
 const RECORD_LENGTH_LENGTH: usize = 4;
 
 /// Read-only view over a serialized value-record batch.
-pub struct ValueRecordBatch {
+pub(crate) struct ValueRecordBatch {
     data: Bytes,
 }
 
 impl ValueRecordBatch {
     /// Wraps raw batch bytes. The batch is expected to start at offset 0.
-    pub fn new(data: Bytes) -> Self {
+    pub(crate) fn new(data: Bytes) -> Self {
         Self { data }
     }
 
     /// Number of records declared in the batch header.
-    pub fn record_count(&self) -> Result<i32> {
+    pub(crate) fn record_count(&self) -> Result<i32> {
         if self.data.len() < RECORD_BATCH_HEADER_SIZE {
             return Err(corrupt(format!(
                 "value-record batch too short: {} bytes, need {} for header",
@@ -77,7 +77,7 @@ impl ValueRecordBatch {
     /// Returns one byte range per record, each spanning `[SchemaId | Value]`:
     /// the payload [`crate::row::FixedSchemaDecoder::decode`] expects. Index
     /// [`Self::data`] with a returned range to get it without copying.
-    pub fn value_ranges(&self) -> Result<Vec<Range<usize>>> {
+    pub(crate) fn value_ranges(&self) -> Result<Vec<Range<usize>>> {
         let count = self.record_count()?;
         if count < 0 {
             return Err(corrupt(format!("invalid record count {count}")));
@@ -108,7 +108,7 @@ impl ValueRecordBatch {
     }
 
     /// The underlying batch bytes.
-    pub fn data(&self) -> &Bytes {
+    pub(crate) fn data(&self) -> &Bytes {
         &self.data
     }
 }
diff --git a/crates/fluss/src/row/binary/iceberg_binary_row_writer.rs 
b/crates/fluss/src/row/binary/iceberg_binary_row_writer.rs
index 4320a622..82a61928 100644
--- a/crates/fluss/src/row/binary/iceberg_binary_row_writer.rs
+++ b/crates/fluss/src/row/binary/iceberg_binary_row_writer.rs
@@ -37,11 +37,10 @@ const MICROS_PER_MILLI: i64 = 1_000;
 /// - Variable-length types (string, binary) are written without length 
prefixes
 /// - Decimals are written as unscaled big-endian bytes without length prefixes
 ///
-/// The encoded bytes feed directly into [`IcebergBucketingFunction`]'s 
MurmurHash
+/// The encoded bytes feed directly into `IcebergBucketingFunction`'s 
MurmurHash
 /// for bucket assignment and must match the Java Fluss server's encoding 
exactly.
 ///
 /// [`CompactedRowWriter`]: crate::row::compacted::CompactedRowWriter
-/// [`IcebergBucketingFunction`]: crate::bucketing::IcebergBucketingFunction
 pub struct IcebergBinaryRowWriter {
     position: usize,
     buffer: BytesMut,

Reply via email to