ryankert01 opened a new pull request, #3642: URL: https://github.com/apache/iggy/pull/3642
## Why The Node SDK omitted the continuation marker after each serialized stream and topic permission entry. Any `createUser` or `updatePermissions` request containing stream-scoped permissions therefore ended before the Rust decoder's required `has_next_stream` byte and was rejected as `Invalid command`. The decoder had the matching cursor bug: it read topic and stream continuation markers without advancing past them, which truncated or corrupted multi-entry permission responses. Existing tests only exercised global permissions with an empty `streams` array. ## What changed - Encode canonical `has_next_topic` and `has_next_stream` markers. - Consume presence and continuation markers while decoding nested permissions. - Omit the permissions length and payload when `createUser` has no permissions. - Add an independent canonical byte vector covering multiple streams and topics. - Exercise scoped permissions through create, update, and get in the Node user E2E test. ## Impact Node SDK clients can create users and update permissions with stream- and topic-scoped authorization. Multi-entry permission responses now round-trip without dropping or misaligning entries. ## Validation - `npm run lint` - `npm run build` - `npm run test:unit` (75 passed) - `node --import @swc-node/register/esm-register --test src/e2e/tcp.user.e2e.ts` (9 passed against a local server) - `cargo test -p iggy_binary_protocol primitives::permissions::tests::roundtrip_with_streams_and_topics -- --exact` -- 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]
