Skip to content

simplify ack/nack handling#912

Merged
michaelklishin merged 1 commit intorabbitmq:masterfrom
bollhals:ackHandling
Jul 10, 2020
Merged

simplify ack/nack handling#912
michaelklishin merged 1 commit intorabbitmq:masterfrom
bollhals:ackHandling

Conversation

@bollhals
Copy link
Contributor

Proposed Changes

There are three main changes here:

  • Cleans up some unused methods in AutorecoveringModel / ExtensionMethods
  • Avoids allocating a BasicAckEventArgs / BasicNackEventArgs if there is no handler.
  • Changes HandleAckNack to call _deliveryTagsCountdown.Signal(count); instead of repeatedly _deliveryTagsCountdown.Signal()

Types of Changes

  • Bug fix (non-breaking change which fixes issue #NNNN)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause an observable behavior change in existing systems)
  • Documentation improvements (corrections, new content, etc)
  • Cosmetic change (whitespace, formatting, etc)

Checklist

  • I have read the CONTRIBUTING.md document
  • I have signed the CA (see https://cla.pivotal.io/sign/rabbitmq)
  • All tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in related repositories

Further Comments

Allocations before:
image

After:
image

Performance before: (consider both methods as it got inlined HandleBasicAck & handleAckNack)
image

after:
image

@michaelklishin michaelklishin merged commit 2e20a8f into rabbitmq:master Jul 10, 2020
michaelklishin added a commit that referenced this pull request Jul 10, 2020
simplify ack/nack handling

(cherry picked from commit 2e20a8f)
michaelklishin added a commit that referenced this pull request Jul 12, 2020
@lukebakken lukebakken added this to the 7.0.0 milestone Jul 13, 2020
@bollhals bollhals deleted the ackHandling branch March 2, 2021 20:49
@lukebakken lukebakken modified the milestones: 8.0.0, 7.0.0 Mar 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants