Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: set node callback each time we reinit the coordinator in servertailnet#12140

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

spikecurtis
Copy link
Contributor

@spikecurtisspikecurtis commentedFeb 14, 2024
edited
Loading

I think this willresolve#12136 but lets get a proper test at the system level before closing.

Before this change, we only register the node callback at start of day for the server tailnet. If the coordinator changes, like we know happens when we are licensed for the PGCoordinator, we close the connection to the old coord, and open a new one to the new coord.

The callback is designed to direct the updates to the new coordinator, but there is nothing that specifically triggers it to fire after we connect to the new coordinator.

If we have STUN, then period re-STUNs will generally get it to fire eventually, but without STUN it we could go indefinitely without a callback.

This PR changes the servertailnet to re-register the callback each time we reconnect to the coordinator. Registering a callback (even if it's the same callback) triggers an immediate call with our node information, so the new coordinator will have it.

@spikecurtisGraphite App
Copy link
ContributorAuthor

This stack of pull requests is managed by Graphite.Learn more about stacking.

Join@spikecurtis and the rest of your teammates onGraphiteGraphite

@spikecurtisspikecurtis marked this pull request as ready for reviewFebruary 14, 2024 16:35
Copy link
Member

@mafredrimafredri left a comment

Choose a reason for hiding this comment

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

LGTM!

I wonder if the test failure is related, though?

    t.go:108: 2024-02-14 16:34:18.608 [erro]  pgcoord: failed to write binding to database  coordinator_id=d6a85ffb-78b2-4c20-b37a-201b43f7d658  binding_id="[74 174 236 19 74 52 64 134 184 243 51 11 140 133 243 253]"  node="id:2386665641149345937  as_of:{seconds:1707928458  nanos:568114000}  key:\"np\\x8a\\xe4\\x1a\\xebv\\xcc=\\x07\\xe6M\\xf5\\x05\\x84\\x8c\\n\\x99\\x91\\xfb\\xd2ҳ\\x1eY\\x1a\\xeeg\\xce\\x19q\\xf5+B\"  disco:\"discokey:d9c88cb39f04aa14298f300bd8871b1b9916256d3a86b91a73652e1e5229fb13\"  preferred_derp:999  derp_latency:{key:\"999-v4\"  value:0.00029301}  addresses:\"fd7a:115c:a1e0:4594:bb1c:bb6b:af5c:27e7/128\"  allowed_ips:\"fd7a:115c:a1e0:4594:bb1c:bb6b:af5c:27e7/128\"  endpoints:\"127.0.0.1:53738\"  endpoints:\"172.17.0.1:53738\"  endpoints:\"192.168.100.229:53738\""  error="pq: insert or update on table \"tailnet_peers\" violates foreign key constraint \"tailnet_peers_coordinator_id_fkey\""

@spikecurtisspikecurtis merged commit04991f4 intomainFeb 14, 2024
@spikecurtisspikecurtis deleted the spike/12136-fix-node-callback-servertailnet branchFebruary 14, 2024 16:45
@spikecurtisGraphite App
Copy link
ContributorAuthor

Merge activity

@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsFeb 14, 2024
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@mafredrimafredrimafredri approved these changes

@coadlercoadlercoadler approved these changes

@deansheatherdeansheatherdeansheather approved these changes

Assignees

@spikecurtisspikecurtis

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

Coder web terminal and apps not loading on big
4 participants
@spikecurtis@mafredri@coadler@deansheather

[8]ページ先頭

©2009-2025 Movatter.jp