From b4b3f77c2a624f455a8f8f8875feb445618eb9fc Mon Sep 17 00:00:00 2001 From: Arijit Ray <35370469+itsarijitray@users.noreply.github.com> Date: Wed, 8 Oct 2025 17:57:30 +0530 Subject: [PATCH 1/2] Add batch size --- .../src/destinations/kafka/send/index.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/packages/destination-actions/src/destinations/kafka/send/index.ts b/packages/destination-actions/src/destinations/kafka/send/index.ts index 55094ad9d7..71520d72d0 100644 --- a/packages/destination-actions/src/destinations/kafka/send/index.ts +++ b/packages/destination-actions/src/destinations/kafka/send/index.ts @@ -50,6 +50,13 @@ const action: ActionDefinition = { default: true, unsafe_hidden: true }, + batch_size: { + label: 'Batch Size', + description: 'Maximum number of events to include in each batch. Actual batch sizes may be lower.', + type: 'number', + required: false, + default: 1000 + }, batch_keys: { label: 'Batch Keys', description: 'The keys to use for batching the events.', From f54412463233e17f0cf1a0d799734f5490a08cc8 Mon Sep 17 00:00:00 2001 From: Arijit Ray <35370469+itsarijitray@users.noreply.github.com> Date: Wed, 8 Oct 2025 17:58:52 +0530 Subject: [PATCH 2/2] Add batch size --- .../src/destinations/kafka/send/generated-types.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/destination-actions/src/destinations/kafka/send/generated-types.ts b/packages/destination-actions/src/destinations/kafka/send/generated-types.ts index 8a68e951c4..a17e3b3ca8 100644 --- a/packages/destination-actions/src/destinations/kafka/send/generated-types.ts +++ b/packages/destination-actions/src/destinations/kafka/send/generated-types.ts @@ -33,6 +33,10 @@ export interface Payload { * If true, Segment will batch events before sending to Kafka. */ enable_batching?: boolean + /** + * Maximum number of events to include in each batch. Actual batch sizes may be lower. + */ + batch_size?: number /** * The keys to use for batching the events. */