Skip to content

Commit 9737c5a

Browse files
committed
Fix interface
1 parent 11c910b commit 9737c5a

1 file changed

Lines changed: 1 addition & 12 deletions

File tree

index.d.ts

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -181,18 +181,7 @@ export interface TopicMetadata {
181181
numPartitions: number;
182182
}
183183

184-
/**
185-
* A custom message router interface that can be implemented by the user.
186-
*/
187-
export interface MessageRouter {
188-
/**
189-
* Choose a partition for the given message.
190-
* @param message The message to be routed.
191-
* @param topicMetadata Metadata for the topic.
192-
* @returns The partition index to send the message to.
193-
*/
194-
getPartition(message: Message, topicMetadata: TopicMetadata): number;
195-
}
184+
export type MessageRouter = (message: Message, topicMetadata: TopicMetadata) => number;
196185

197186
export interface SchemaInfo {
198187
schemaType: SchemaType;

0 commit comments

Comments
 (0)