unstale

npm / @platformatic/kafka

@platformatic/kafka

What changed in @platformatic/kafka 1 to 2, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-25.

8 breaking2 security51 new APIs and options8 performance19 behavior and defaults2 tooling85 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

@platformatic/kafka 2108 changes

Breaking changes 4

Security 2

New APIs and options 25

  • Adds linger to batch messages across send() calls.

    2.17.0release notes

  • Terminal consumer group membership loss is now signaled.

    2.16.0release notes

  • A timeout is available for group leave during consumer close.

    2.15.0release notes

  • Broker connections have an idle-timeout option.

    2.15.0release notes

  • Broker connections have a keep-alive option.

    2.15.0release notes

  • A new partitionAssignerTopicsSelector option is available.

    2.13.0release notes

  • New options for reauthentication are available.

    2.13.0release notes

  • Adds asynchronous gzip compression.

    2.12.0release notes

  • createTopics supports per-topic overrides, and its options schema allows configs.

    2.10.0release notes

  • The group:rebalance event is emitted when partitions are revoked under the consumer protocol.

    2.10.0release notes

  • An event is emitted when heartbeats stop succeeding.

    2.10.0release notes

  • Consumed messages expose the record batch leader epoch.

    2.10.0release notes

  • ConfluentSchemaRegistry requests can include custom HTTP headers.

    2.9.0release notes

  • ConfluentSchemaRegistry supports a retry option.

    2.9.0release notes

  • ConfluentSchemaRegistry supports a timeout option.

    2.9.0release notes

  • TLS options are available for the ConfluentSchemaRegistry HTTP client.

    2.9.0release notes

  • Consumed key and value schema IDs are exposed in message metadata.

    2.9.0release notes

  • Original key and value byte lengths are exposed after Schema Registry decode.

    2.9.0release notes

  • Schema Registry decode errors can soft-fail so consuming continues.

    2.9.0release notes

  • Adds a handler for deserialization errors.

    2.8.0release notes

  • AJV options were added for the schema registry.

    2.6.0release notes

  • Adds a metadata callback for consumer protocols.

    2.4.0release notes

  • Adds client rack support for affinity.

    2.1.0release notes

  • Adds maxBytesPerPartition.

    2.0.0release notes

  • Metadata is now passed as partitioner context, allowing partitioners to use it.

    2.0.0release notes

Performance 7

  • API codecs are loaded on demand.

    2.17.0release notes

  • Producer murmur2 computation now uses 32-bit integer math instead of BigInt.

    2.17.0release notes

  • Option validators are compiled on first use.

    2.17.0release notes

  • The producer no longer builds a partition key for each message.

    2.17.0release notes

  • Consumers decode record batches from a contiguous buffer.

    2.17.0release notes

  • The producer returns record batches as a head and a contiguous body.

    2.17.0release notes

  • Schema registry libraries and the LRU cache are loaded on demand.

    2.17.0release notes

Behavior and default changes 12

  • A closing event is emitted when requests time out.

    2.15.0release notes

  • SNI is enabled by default for non-IP destinations.

    2.14.0release notes

  • Implements KIP-429.

    2.12.0release notes

  • Supports multiple JSON Schema drafts.

    2.8.0release notes

  • Reuses incremental fetch sessions instead of using sessionId=…

    2.3.0release notes

  • Logs the whole error hierarchy for MultipleErrors.

    2.3.0release notes

  • Bootstrap candidates are rotated.

    2.2.2release notes

  • The client tries ApiVersions v3 first, then downgrades to v1.

    2.2.0release notes

  • The package supports all older Kafka API versions, allowing developers to use it with older Kafka APIs.

    2.2.0release notes

  • When schemaType is omitted in fetchSchema, it now defaults to AVRO.

    2.1.0release notes

  • Group assignment user data is no longer parsed.

    2.0.0release notes

  • The maxBytes value is increased.

    2.0.0release notes

Tooling 1

  • Adds CI support for Node.js 26, indicating compatibility with that runtime.

    2.3.0release notes

Fixes and other changes 57

  • Consumer group options are preserved during internal rejoins.

    2.17.0release notes

  • The number of errors retained across retries is now bounded.

    2.17.0release notes

  • The consumer no longer retries a fetch when its partitions have moved to other leaders.

    2.17.0release notes

  • Fixes handling of null values and batchMaxBytes when messages are batched while lingering.

    2.17.0release notes

  • Offsets queued during an in-flight commit are flushed before partitions are revoked.

    2.16.0release notes

  • The reauthentication timer is cleared when the connection closes.

    2.16.0release notes

  • Offsets are preserved when filtering aborted transactions.

    2.15.0release notes

  • Brokers missing from the latest metadata response are remembered.

    2.15.0release notes

  • Connection errors are caught.

    2.15.0release notes

  • Admin operations preserve consumer group members with malformed payloads.

    2.15.0release notes

  • An in-flight rejoin no longer revives a closed consumer.

    2.15.0release notes

  • Duplicate child messages are removed from joinGroup errors.

    2.15.0release notes

  • Cached leader epochs are invalidated after fenced fetches.

    2.15.0release notes

  • Pending requests fail and reset when the connection closes.

    2.15.0release notes

  • Revoked partitions are no longer committed after a consumer rejoin.

    2.15.0release notes

  • Topic listing tolerates partition metadata errors.

    2.15.0release notes

  • Fixes failures when using Azure.

    2.14.0release notes

  • Stale fetches are discarded after an offset refresh.

    2.13.0release notes

  • Out-of-range partitions are reduced modulo the partition count when selecting send brokers.

    2.13.0release notes

  • The options schema declares isolationLevel as a number.

    2.13.0release notes

  • Retriable error detection is improved.

    2.13.0release notes

  • Legacy metadata advertising is now decoded correctly.

    2.12.1release notes

  • Updates metadata on broker rebalance.

    2.12.0release notes

  • Updates consumer lag after manual commits.

    2.12.0release notes

  • Repeated rejoin errors cause performJoinGroup to retry indefinitely without an error, timeout, or log signal.

    2.12.0release notes

  • Corrects close overload resolution and allows a consumer to close after broker disconnect.

    2.12.0release notes

  • Prevents a crash when a control marker has no aborted transaction range.

    2.12.0release notes

  • Publishes explicit empty KIP-848 assignments.

    2.12.0release notes

  • Disables metadata retrying in the producer loop.

    2.12.0release notes

  • Broker metadata is refreshed after retryable network errors.

    2.10.0release notes

  • Classic heartbeats are rescheduled after a non-group error.

    2.10.0release notes

  • Committed offsets are kept across overlapping refreshes.

    2.10.0release notes

  • Consumed messages preserve duplicate headers.

    2.10.0release notes

  • IPv6 bootstrap broker addresses are parsed correctly.

    2.10.0release notes

  • Failures in the before-deserialization hook are reported through onDeserializationError.

    2.10.0release notes

  • Active streams are closed when leaving a group with the consumer protocol.

    2.9.0release notes

  • A TypeError is no longer uncaught when a closed connection pool errors.

    2.9.0release notes

  • Deserialization errors are now exposed to onCorruptedMessage.

    2.7.0release notes

  • Schema fetching is deduplicated.

    2.6.1release notes

  • Consumer group rejoin now handles stale or incomplete metadata.

    2.3.1release notes

  • Removed partitions are now forgotten in incremental fetch sessions.

    2.3.1release notes

  • Producer initialization fails over from a hung bootstrap broker.

    2.3.1release notes

  • Includes several fixes and improvements to the Admin Client.

    2.3.0release notes

  • Handles empty messages in Confluent Schema Registry.

    2.3.0release notes

  • Restores idempotent producer state after a failure.

    2.3.0release notes

  • Fixes tagged field decoding.

    2.3.0release notes

  • Metadata requests no longer request topic authorized operations.

    2.3.0release notes

  • Sets refreshOffsetsInflight during _construct, fixing the in-flight state during construction.

    2.2.3release notes

  • Synchronous exceptions during retry are routed to the callback.

    2.2.2release notes

  • The connection correlation ID is constrained to 32 bits.

    2.2.2release notes

  • Recovery works when Fetch omits the reset offset.

    2.2.2release notes

  • The coordinator is reset when appropriate.

    2.1.0release notes

  • Undefined options are ignored when merging with defaults, so they no longer override default values.

    2.1.0release notes

  • Always writes the user data bytes field in ConsumerProtocolAssigment.

    2.0.1release notes

  • Fixes recovery from out of range errors.

    2.0.1release notes

  • Fixes stale epoch errors.

    2.0.0release notes

  • Handles Xerial Snappy encoding.

    2.0.0release notes

@platformatic/kafka 167 changes

Breaking changes 4

  • Series are no longer run on empty collections.

    1.30.0release notes

  • Reverts Admin export namespacing, changing how Admin exports are named.

    1.25.0release notes

  • Adjusts the default value for partitions.

    1.23.0release notes

  • Adjusts the default value for replicas.

    1.23.0release notes

New APIs and options 26

Performance 1

  • Moves fetch connections to streams for parallelism.

    1.26.0release notes

Behavior and default changes 7

  • When bootstrap brokers are unreachable, the client falls back to discovered brokers.

    1.29.0release notes

  • The connect event is emitted upon SASL re-authentication.

    1.29.0release notes

  • Crypto and compression implementations switch to WASM-based implementations.

    1.27.0release notes

  • Blocks connections while SASL reauthentication is in progress.

    1.26.0release notes

  • More cluster metadata is passed up, making additional metadata available to developers.

    1.24.0release notes

  • Implements request timeouts.

    1.23.0release notes

  • When no topics are provided, offsets are fetched for all topics.

    1.19.0release notes

Tooling 1

  • The typings for runConcurrentCallbacks are improved.

    1.24.0release notes

Fixes and other changes 28

  • Errors are cleaned after success.

    1.34.0release notes

  • Fixed needsRejoin handling for ILLEGAL_GENERATION.

    1.34.0release notes

  • Fixed kAutocommit cascade behavior.

    1.34.0release notes

  • Fixes a memory use regression.

    1.33.0release notes

  • Fixed retries overriding for idempotent.

    1.32.0release notes

  • Fixed SCRAM parameter parsing.

    1.32.0release notes

  • Fixes backpressure processing stalling.

    1.31.0release notes

  • Adds timeout and close handling to connection.ready().

    1.31.0release notes

  • Fixes handling of FENCED_LEADER_EPOCH and undefined entries in MultipleErrors.

    1.31.0release notes

  • Fixes a crash when listing the offset of an unknown partition.

    1.31.0release notes

  • Added support for Kafka 4.1.0.

    1.30.0release notes

  • Fetches are delayed during rebalances.

    1.28.0release notes

  • RedPanda is now supported.

    1.27.0release notes

  • Null is encoded as varint(-1), fixing Kafka tombstone handling.

    1.27.0release notes

  • Fixes consuming behavior upon disconnection.

    1.25.0release notes

  • The ListOffsets API is implemented.

    1.24.0release notes

  • Offset commits now commit offset+1 instead of offset.

    1.24.0release notes

  • Topic creations and deletions are no longer deduplicated irrespective of topics.

    1.24.0release notes

  • Fixes 41/NOT_CONTROLLER for non-Kraft clusters.

    1.23.0release notes

  • Fixes unhandled errors on custom connection errors.

    1.23.0release notes

  • Enables compatibility with TypeScript 4.

    1.23.0release notes

  • Metadata is published to the diagnostic channel even when invoked internally.

    1.21.0release notes

  • Request serialisation errors are handled asynchronously.

    1.21.0release notes

  • Fixed handling of undefined options.

    1.21.0release notes

  • Fixed describeGroup response handling.

    1.20.0release notes

  • Fixed lag computation.

    1.20.0release notes

  • Corrects the typing for consumer.fetch options, so TypeScript users get accurate types.

    1.18.0release notes

  • Fixes ConsumerGroupHeartbeat v0.

    1.18.0release notes