kafka_commit()

Read(2604) Label: commit, object,

Description:

Commit the current consumer offset position.

Syntax:

kafka_commit (fd) 

Note:

By default, the external library function (See External Library Guide) commits the real-time consumer offset position synchronously.

Parameter:

fd

A connection object

Option:

@a

Asynchronous commit

Example:

 

A

 

1

=kafka_open("D://kafka.properties","topic-test")

Connect to Kafka server.

2

=kafka_poll(A1)

Get records from topictest.

3

=kafka_commit(A1)

Commit the current consumer offset.

4

=kafka_commit@a(A1)

Asynchronous commit.