Skip to content

Update member info on serf EventMemberUpdate#27428

Open
marvinchin wants to merge 1 commit intohashicorp:mainfrom
marvinchin:handle-serf-member-update
Open

Update member info on serf EventMemberUpdate#27428
marvinchin wants to merge 1 commit intohashicorp:mainfrom
marvinchin:handle-serf-member-update

Conversation

@marvinchin
Copy link
Contributor

Description

Fix #27427

Testing & Reproduction steps

Repeated the reproduction in #27427 and verified that it now works.

Happy to add some automated tests if maintainers feel that it's necessary, please feel free to point me to where to add the tests if so.

Reviewer Checklist

  • Backport Labels Please add the correct backport labels as described by the internal
    backporting document.
  • Commit Type Ensure the correct merge method is selected which should be "squash and merge"
    in the majority of situations. The main exceptions are long-lived feature branches or merges where
    history should be preserved.
  • Enterprise PRs If this is an enterprise only PR, please add any required changelog entry
    within the public repository.
  • If a change needs to be reverted, we will roll out an update to the code within 7 days.

Changes to Security Controls

Are there any changes to security controls (access controls, encryption, logging) in this pull request? If so, explain.

@marvinchin marvinchin requested review from a team as code owners January 28, 2026 08:36
@hashicorp-cla-app
Copy link

hashicorp-cla-app bot commented Jan 28, 2026

CLA assistant check
All committers have signed the CLA.

@tgross tgross self-requested a review January 28, 2026 14:27
@tgross tgross self-assigned this Jan 28, 2026
@tgross tgross moved this from Needs Triage to Triaging in Nomad - Community Issues Triage Jan 28, 2026
Copy link
Member

@tgross tgross left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @marvinchin! Thanks for the PR! A few things to address:

  • When the server receives an event on this channel, we update the peersCache with the parsed parts. It looks like if we start accepting EventMemberUpdate that we end up with duplicate entries. So we'll need to de-duplicate those as well.
  • Testing is a little gross because we can't easily force the running agent to update and the TestServer cleans itself up on shutdown. We could probably have a test in nomad/serf_test.go that injects the event directly and that'll exercise things like peersCache, but those changes won't show up in the memberlist. That's probably fine though, as that's what we care about here.
  • Can I get you to sign the CLA and work up a changelog via make changelog?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Development

Successfully merging this pull request may close these issues.

Change to advertised RPC address is not updated when server restarts

2 participants