Repository navigation
Conversation
…penIntegrationEngine#456) getDashboardChannels filtered deployed channels by the requested channel IDs but added every deploying and undeploying channel unfiltered. A request for channel A made while channel B was mid-deploy or mid-undeploy therefore included B, and GET /channels/{A}/statistics, which returns the first entry, could describe B. Apply the same filter to the transitional sets. The collection logic moves into a package-private static helper so it can be unit tested. Signed-off-by: iacsha <122627209+iacsha@users.noreply.github.com>
iacsha
requested review from
a team,
gibson9583,
jonbartels,
kayyagari,
kpalang,
mgaffigan,
pacmano1 and
ssrowe
November 7, 2026 01:17
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #456.
Cause.
DonkeyEngineController.getDashboardChannels(channelIds)filtersdonkey.getDeployedChannels()by the requested IDs, but then adds every channel indeployingChannelsandundeployingChannelswithout that filter. So while channel B is mid-deploy or mid-undeploy, a request scoped to{A}also gets B.ChannelStatisticsServlet.getStatistics(channelId)returnschannelStatisticsList.get(0), and when A is not deployed, B (a dashboard channel) is listed before undeployed A, so the response describes B. The same helper feedsgetChannelStatusList, so per-channel dashboard status was affected too.Fix. Apply the requested-ID filter to the deploying and undeploying sets as well. Unfiltered requests (no IDs) behave exactly as before, and a deployed channel still wins over a transitional entry with the same ID. The collection logic moved into a package-private static
getDashboardChannels(deployed, deploying, undeploying, channelIds)so it can be unit tested without starting the engine; the instance method delegates to it.Tests. New
DonkeyEngineControllerDashboardChannelsTest(5 cases). With the filter removed, 3 of them fail; with the fix, all pass. Full:server:testpasses (841 tests, 0 failures).End-to-end repro (the issue's steps, on images built from
mainand from this branch, fresh appdata each): two VM-reader channels A and B, A left undeployed; one loop deploys B, sends a message, and undeploys B; three loops pollGET /api/channels/{A}/statisticsfor 90 seconds.mainWith A deployed,
mainhappened not to show it in my runs because HashMap order put A first, which is luck rather than correctness; the fix doesn't depend on ordering.