gnuhpc opened a new pull request, #633: URL: https://github.com/apache/fluss-rust/pull/633
## What Introduces a stateful, unbounded KV-table scanner using the **ScanKv API (1061)**. The first `next_batch()` opens the server-side cursor; subsequent calls iterate; dropping the scanner sends a best-effort close. - `client/table/kv_batch_scanner.rs`: `KvBatchScanner` with a per-bucket state machine (Pending → Active → Done), best-effort close on `Drop`, and **retry-with-backoff on any retriable server error** (leader-election races on a freshly created bucket, transient `TooManyScanners`, …) — not just `TooManyScanners`. - `client/table/scanner.rs`: `TableScan::create_kv_batch_scanner()` with PK / bucket-range validation. - `config.rs`: `scanner_kv_fetch_max_bytes` (default 4 MB, matching Java `CLIENT_SCANNER_KV_FETCH_MAX_BYTES`). - `rpc/fluss_api_error.rs`: new error codes 66–69 (`ScannerExpiredException`, `UnknownScannerIdException`, `InvalidScanRequestException`, `TooManyScanners`) with correct retriable classification. - `client/table/batch_scanner.rs`: expose the KV decode helpers (`pub(super)`) for reuse by the new scanner. - `tests/integration/batch_scanner.rs`: 4 KV integration tests; they tolerate `UnsupportedVersion` so they also pass (as no-ops) against 0.9.x servers that lack ScanKv. ## Verification Built + `cargo clippy` clean; `cargo fmt` clean. Integration suite against a real Fluss **1.x** cluster: 70/72 pass. The only 2 failures are the SASL *negative* auth tests (`test_sasl_connect_with_wrong_password`, `test_sasl_connect_with_unknown_user`) — these fail because the **test docker image does not enforce SASL auth** (verified: valid/wrong/unknown credentials all connect). The Rust client's SASL handshake is correct (sends `AuthenticateRequest`, retries `RetriableAuthenticateException`, propagates non-retriable); Fluss's own reference test `SaslAuthenticationITCase` with identical config does reject bad credentials. So this is a test-image/server packaging issue, not an SDK defect. ## Stack Part **6/6** (final), stacked on #632 → … → #628. All target `main`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
