Share this page

# LrKafkaProducer.sendOffsetsToTransaction

Calls the sendOffsetsToTransaction method on the KafkaProducer initialized for the Vuser.

`public static void sendOffsetToTransaction(Map<TopicPartition, OffsetAndMetadata> offsets, String consumerGroupId) throws ProducerFencedException`

`public static void sendOffsetsToTransaction(Map<TopicPartition, OffsetAndMetadata> offsets, ConsumerGroupMetadata groupMetadata) throws ProducerFencedException`

## Arguments

Name | Description
--- | ---
offsets | Map of topic partitions and the respective offset metadata to be marked
consumerGroupId | ID of the consumer group that will receive the offsets
groupMetadata | Metadata of the consumer group that will receive the offsets

## Return Values

This function does not return any values.

For more information about this function, see the Apache Kafka documentation.

Tips to improve your search results... VuGen Function Reference Version 26.1-26.3 Function Reference 26.1-26.3 All View Local Help Center View Online Help Center Version: