apisix icon indicating copy to clipboard operation
apisix copied to clipboard

fix: stream route matcher is nil after first match

Open nic-6443 opened this issue 1 year ago • 0 comments

Description

Fix https://github.com/apache/apisix/issues/11259

this bug introduced in https://github.com/apache/apisix/pull/10298/files#diff-0234dd467ed66c3dffbef844397e9e7e018c287aab324ba8dd0b5a9e03b89360, I have no idea why made those changes, set route.value.xxx_matcher to nil is insane, the stream route only working in first matched request now, after first match, all requests to same stream route will be panic with nil matcher: image image

Checklist

  • [x] I have explained the need for this PR and the problem it solves
  • [x] I have explained the changes or the new features added to this PR
  • [x] I have added tests corresponding to this change
  • [ ] I have updated the documentation to reflect this change
  • [x] I have verified that this change is backward compatible (If not, please discuss on the APISIX mailing list first)

nic-6443 avatar May 20 '24 14:05 nic-6443