yummyPancake2607 opened a new pull request, #4020:
URL: https://github.com/apache/iggy/pull/4020

   Add system client methods to the Python SDK for parity with Rust SDK:
   
   - Add client_info.rs wrapping ClientInfo, ClientInfoDetails, 
ConsumerGroupInfo types with pyclass getters
   - Add get_me() -> ClientInfoDetails for current client info
   - Add get_client(client_id) -> ClientInfoDetails | None
   - Add get_clients() -> list[ClientInfo] for all connected clients
   - Register new types in lib.rs pymodule
   - Add iggy_common dependency for ClientInfo/ConsumerGroupInfo
   - Add integration tests for all three methods
   
   ## Which issue does this PR address?
   
   <!--
   We generally require a GitHub issue for all bug fixes and enhancements. Link 
it with GitHub syntax, keep the line that applies and delete the other:
   - `Closes #123` auto-closes the issue when this PR merges (full fix).
   - `Relates to #123` links without closing (partial or related work).
   -->
   
   Relates to #4015
   
   ## Rationale
   
   <!--
   Why is this change needed? If the issue explains it well, a one-liner is 
fine.
   -->
   
   The Rust SDK exposes `get_me`, `get_client`, and `get_clients` via 
`SystemClient`, but the Python SDK had none of them. Every other SDK (Java, 
.NET, Go, etc.) already exposes connection state — this closes the parity gap.
   
   ## What changed?
   
   <!--
   2-4 sentences. Problem first (before), then solution (after).
   
   GOOD:
   
   "Messages were unavailable when background message_saver committed the
   journal and started async disk I/O before completion. Polling during
   this window found neither journal nor disk data.
   
   The fix freezes journal batches in the in-flight buffer before async 
persist."
   
   GOOD:
   
   "When many small messages accumulate in the journal, the flush passes
   thousands of IO vectors to writev(), exceeding IOV_MAX (1024 on Linux)."
   
   BAD:
   - Walls of text
   - "This PR adds..." (we can see the diff)
   -->
   
   The Python SDK had no way to inspect the currently connected client or 
enumerate all connected clients, while every other SDK could. This adds three 
methods (`get_me`, `get_client`, `get_clients`) and their associated wrapper 
types (`ClientInfo`, `ClientInfoDetails`, `ConsumerGroupInfo`) to the Python 
SDK, following the same pattern used for user types in `user.rs`.
   
   ## Local Execution
   
   - Passed: `cargo check`, `cargo clippy --all-features --all-targets -- -D 
warnings`, `cargo fmt --all -- --check`
   - Pre-commit hooks ran / not ran
   
   <!--
   You must run your code locally before submitting.
   "Relying on CI" is not acceptable - PRs from authors who haven't run the 
code will be closed.
   
   Did you have `prek` installed? It runs automatically on commit and covers 
all project languages. See 
[CONTRIBUTING.md](https://github.com/apache/iggy/blob/master/CONTRIBUTING.md).
   -->
   
   ## AI Usage
   
   <!--
   If AI tools were used, please answer:
   1. Which tools? (e.g., GitHub Copilot, Claude, ChatGPT)
   2. Scope of usage? (e.g., autocomplete, generated functions, entire 
implementation)
   3. How did you verify the generated code works correctly?
   4. Can you explain every line of the code if asked?
   
   If no AI tools were used, write "None" or delete this section.
   -->
   
   None
   


-- 
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]

Reply via email to