Skip to content

Commit

Permalink
for eventhub disable commit lock (#546)
Browse files Browse the repository at this point in the history
  • Loading branch information
iskakaushik authored Oct 20, 2023
1 parent 8daacce commit 41dfd4f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion flow/connectors/postgres/cdc.go
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,11 @@ func (p *PostgresCDCSource) processMessage(batch *model.RecordBatch, xld pglogre
case *pglogrepl.BeginMessage:
log.Debugf("BeginMessage => FinalLSN: %v, XID: %v", msg.FinalLSN, msg.Xid)
log.Debugf("Locking PullRecords at BeginMessage, awaiting CommitMessage")
p.commitLock = true
if utils.GetEnvBool("PEERDB_BETA_EVENTHUB_PUSH_ASYNC", false) {
p.commitLock = false
} else {
p.commitLock = true
}
case *pglogrepl.InsertMessage:
return p.processInsertMessage(xld.WALStart, msg)
case *pglogrepl.UpdateMessage:
Expand Down

0 comments on commit 41dfd4f

Please sign in to comment.