Repository navigation
fix(requestreply): unregister the request on an early return - #9518
arpitjain099 wants to merge 1 commit into
Conversation
Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: Arpit Jain <arpitjain099@gmail.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: arpitjain099 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Welcome @arpitjain099! It looks like this is your first PR to knative/eventing 🎉 |
|
Hi @arpitjain099. Thanks for your PR. I'm waiting for a knative member to verify that this patch is reasonable to test. If it is, they should reply with Tip We noticed you've done this a few times! Consider joining the org to skip this step and gain Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
handleNewEventregisters the event inh.entriesfirst, then four error paths return without callingdeleteEvent: no broker address annotation, no AES key, a correlation id failure, a dispatch failure. Each one leaves aproxiedRequestholding the request's ResponseWriter in the map for the life of the pod. Only the reply and timeout paths clean up.Moving the cleanup into a
deferafteraddEventcovers every return. The new test posts five events at a broker that is not listening: 5 entries are left behind before the change, 0 after.Proposed Changes
defer, so every return fromhandleNewEventremoves it fromh.entriesPre-review Checklist
Release Note