kerneltime opened a new pull request, #10844: URL: https://github.com/apache/ozone/pull/10844
## What changes were proposed in this pull request? Adds DNS refresh on the DN→SCM heartbeat path, completing the `// TODO: HDDS-15533` left in `HostAndPort` by HDDS-15682 (#10612). #10612 keys SCM-node identity on the stable configured `host:port`, but it resolves the address once and freezes it — so a datanode keeps dialing a dead IP after an SCM pod is rescheduled to a new IP. This change: - Makes `HostAndPort.address` threadsafe (`volatile`) and adds `refresh()` to re-resolve `host:port` and swap the cached address on an IP change (resolving the TODO). - Adds `SCMConnectionManager.refreshSCMServer()`, which rebuilds the endpoint under the **same** `host:port` key and closes the stale proxy. Because the key is stable, there is no re-keying, collision check, or `StateContext` queue migration. - `HeartbeatEndpointTask` triggers the refresh on a connection-class heartbeat failure once the missed-heartbeat threshold is reached, gated by the existing `ozone.client.failover.resolve-needed` flag. New config: `hdds.heartbeat.address.refresh.threshold` (default 3). Off by default — with `ozone.client.failover.resolve-needed=false` (the default) behaviour is unchanged. This replaces the earlier stacked attempt (szetszwo/ozone#11), rebuilt directly on `master` now that #10612 has merged; it also supersedes the closed #10488. ## What is the link to the Apache JIRA? https://issues.apache.org/jira/browse/HDDS-15533 ## How was this patch tested? New `TestHeartbeatEndpointTaskDnsRefresh` verifies a connection-class failure past the threshold triggers the refresh, and that flag-off, application-level errors, and below-threshold do not. `mvn checkstyle:check` passes on `hadoop-hdds/common` and `hadoop-hdds/container-service`. Full module build/tests were not run locally; relying on CI. Generated-by: Claude Code (Opus 4.8) -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
