Repository navigation
IGNITE-1025 Warn when IP finder has a long list of addresses - #13739
Open
XianReallyHot-ZZH wants to merge 2 commits into
Open
XianReallyHot-ZZH wants to merge 2 commits into
XianReallyHot-ZZH wants to merge 2 commits into
Conversation
Author
|
Per contribution guidelines, adding the Java version used to compile and run tests locally: Test command: |
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.
Description
Ticket: https://issues.apache.org/jira/browse/IGNITE-1025
When the IP finder resolves a long list of addresses, node join/reconnect may take significant time: a connection attempt to an unavailable address usually blocks until socket timeout instead of failing fast (on Windows OS this typically looks like the node hangs for a while).
This PR adds a throttled warning in
TcpDiscoverySpi.resolvedAddresses()when the resolved address list exceedsADDRS_WARN_THRESHOLD(20). The warning explains why startup can be slow and suggests making sure that all IP finder addresses are correct and reachable and reducing the address list.The warning is printed regardless of OS so it is deterministic and testable (CI runs on Linux), while the message text explains the Windows-specific amplification described in the ticket.
Supersedes the stale attempt #2966 (closed in 2022 without review).
Testing
TcpDiscoveryLongAddressListWarnSelfTestadded:testWarnOnLongAddressList— 21 registered addresses → warning is printed.testNoWarnOnShortAddressList— 3 registered addresses → no warning.mvn -pl modules/core test -Dtest=TcpDiscoveryLongAddressListWarnSelfTest— 2/2 green (locally verified red before the fix as well).