You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by "shreemaan-abhishek (via GitHub)" <gi...@apache.org> on 2026/04/29 12:06:36 UTC
[PR] fix: rebuild stream router when services change [apisix]
shreemaan-abhishek opened a new pull request, #13318:
URL: https://github.com/apache/apisix/pull/13318
### Description
The stream router in `apisix/stream/router/ip_port.lua` only tracked `stream_routes.conf_version` to decide when to rebuild the internal router. As a result, updates to a service referenced by a stream route did not trigger a rebuild, so changes such as a service arriving after the route, status updates, or deletion were not consistently reflected. Additionally, when a rebuild produced zero TLS routes, the previously built `tls_router` was left in place and could keep dispatching against stale routes. This change tracks the services `conf_version` alongside the stream routes version and rebuilds the router when either changes, and resets `tls_router` to nil when the rebuild yields no TLS routes.
#### Which issue(s) this PR fixes:
Fixes #
### 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
- [ ] 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](https://github.com/apache/apisix/tree/master#community) first)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] fix: rebuild stream router when services change [apisix]
Posted by "shreemaan-abhishek (via GitHub)" <gi...@apache.org>.
shreemaan-abhishek merged PR #13318:
URL: https://github.com/apache/apisix/pull/13318
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org