sunnysabor commented on issue #6662: URL: https://github.com/apache/shenyu/issues/6662#issuecomment-5936744353
Verified against current `upstream/master` at `69399fe5` (merged PR #6925): `SelectorDataRefresh.refresh()` now calls `refreshSelectorDataAll()` before checking `CollectionUtils.isEmpty(data)` and returns immediately for null or empty input. The regression test `SelectorDataRefreshTest#testRefreshWithNullData` verifies the null case; empty input follows the same clearing branch. This appears to resolve the reported stale-cache/NPE behavior, so the issue can be closed if maintainers agree. Code: https://github.com/apache/shenyu/blob/69399fe5af8ddddf55fbc863d4c6c428de8ac4f6/shenyu-sync-data-center/shenyu-sync-data-http/src/main/java/org/apache/shenyu/sync/data/http/refresh/SelectorDataRefresh.java#L69-L77 Test: https://github.com/apache/shenyu/blob/69399fe5af8ddddf55fbc863d4c6c428de8ac4f6/shenyu-sync-data-center/shenyu-sync-data-http/src/test/java/org/apache/shenyu/sync/data/http/refresh/SelectorDataRefreshTest.java#L82-L94 -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
