Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pageserver: implement emergency mode for operating without control plane #5469

Merged
merged 6 commits into from
Oct 6, 2023

Conversation

jcsp
Copy link
Contributor

@jcsp jcsp commented Oct 4, 2023

Problem

Pageservers with control_plane_api configured require a control plane to start up: in an incident this might be a problem.

Summary of changes

Note to reviewers: most of the code churn in mgr.rs is the refactor commit that enables the later emergency mode commit: you may want to review commits separately.

  • Add control_plane_emergency_mode configuration property
  • Refactor init_tenant_mgr to separate loading configurations from the main loop where we construct Tenant, so that the generations fetch can peek at the configs in emergency mode.
  • During startup, in emergency mode, attach any tenants that were attached on their last run, using the same generation number.

Closes: #5381
Closes: #5492

@jcsp jcsp added t/feature Issue type: feature, for new features or requests c/storage/pageserver Component: storage: pageserver labels Oct 4, 2023
@jcsp jcsp changed the title [WIP] pageserver: implement emergency mode for operating without control plane pageserver: implement emergency mode for operating without control plane Oct 5, 2023
@github-actions
Copy link

github-actions bot commented Oct 5, 2023

2256 tests run: 2140 passed, 0 failed, 116 skipped (full report)


Code coverage (full report)

  • functions: 52.6% (8144 of 15479 functions)
  • lines: 81.2% (47591 of 58583 lines)

The comment gets automatically updated with the latest test results
a548284 at 2023-10-06T11:36:29.639Z :recycle:

@jcsp jcsp marked this pull request as ready for review October 6, 2023 08:53
@jcsp jcsp requested a review from a team as a code owner October 6, 2023 08:53
@jcsp jcsp requested review from koivunej and removed request for a team October 6, 2023 08:53
Copy link
Member

@koivunej koivunej left a comment

Choose a reason for hiding this comment

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

Unable to catch anything higher level than the span usage, timeouting tests with the many layers being generated (I guess mock_s3 can get slow -- it's the python impl).

@jcsp jcsp requested a review from koivunej October 6, 2023 11:54
Copy link
Member

@koivunej koivunej left a comment

Choose a reason for hiding this comment

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

I think I now understood it. I don't necessarily like the ordering or structuring but unable to suggest a better one. This was split from some other PR so let's hope it'll reorder :)

@jcsp jcsp enabled auto-merge (squash) October 6, 2023 16:22
@jcsp jcsp merged commit ea5a97e into main Oct 6, 2023
39 checks passed
@jcsp jcsp deleted the jcsp/gens-emergency-mode branch October 6, 2023 16:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c/storage/pageserver Component: storage: pageserver t/feature Issue type: feature, for new features or requests
Projects
None yet
2 participants