@@ -807,14 +807,6 @@ func (p *Producer) SetOAuthBearerTokenFailure(errstr string) error {
807807// will acquire the internal producer id and epoch, used in all future
808808// transactional messages issued by this producer instance.
809809//
810- // Upon successful return from this function the application has to perform at
811- // least one of the following operations within `transaction.timeout.ms` to
812- // avoid timing out the transaction on the broker:
813- // - `Produce()` (et.al)
814- // - `SendOffsetsToTransaction()`
815- // - `CommitTransaction()`
816- // - `AbortTransaction()`
817- //
818810// Parameters:
819811// - `ctx` - The maximum time to block, or nil for indefinite.
820812// On timeout the operation may continue in the background,
@@ -846,6 +838,14 @@ func (p *Producer) InitTransactions(ctx context.Context) error {
846838// `InitTransactions()` must have been called successfully (once)
847839// before this function is called.
848840//
841+ // Upon successful return from this function the application has to perform at
842+ // least one of the following operations within `transaction.timeout.ms` to
843+ // avoid timing out the transaction on the broker:
844+ // - `Produce()` (et.al)
845+ // - `SendOffsetsToTransaction()`
846+ // - `CommitTransaction()`
847+ // - `AbortTransaction()`
848+ //
849849// Any messages produced, offsets sent (`SendOffsetsToTransaction()`),
850850// etc, after the successful return of this function will be part of
851851// the transaction and committed or aborted atomatically.
0 commit comments