Skip to content

Commit

Permalink
resolve merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
reugn committed Dec 17, 2024
1 parent daccfae commit e26ec24
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pulsar/transaction_impl.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func (txn *transaction) GetState() TxnState {
return TxnState(txn.state.Load())
}

func (txn *transaction) Commit(_ context.Context) error {
func (txn *transaction) Commit(ctx context.Context) error {
if !(txn.state.CompareAndSwap(int32(TxnOpen), int32(TxnCommitting))) {
txnState := txn.state.Load()
return newError(InvalidStatus, txnStateErrorMessage(TxnOpen, TxnState(txnState)))
Expand Down Expand Up @@ -117,7 +117,7 @@ func (txn *transaction) Commit(_ context.Context) error {
return err
}

func (txn *transaction) Abort(_ context.Context) error {
func (txn *transaction) Abort(ctx context.Context) error {
if !(txn.state.CompareAndSwap(int32(TxnOpen), int32(TxnAborting))) {
txnState := txn.state.Load()
return newError(InvalidStatus, txnStateErrorMessage(TxnOpen, TxnState(txnState)))
Expand Down

0 comments on commit e26ec24

Please sign in to comment.