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

Add dummy lsn lease http and page service APIs #7815

Merged
merged 8 commits into from
May 21, 2024
Merged

Conversation

arpad-m
Copy link
Member

@arpad-m arpad-m commented May 20, 2024

We want to introduce a concept of temporary and expiring LSN leases. This adds both a http API as well as one for the page service to obtain temporary LSN leases.

This adds a dummy implementation to unblock integration work of this API. A functional implementation of the lease feature is deferred to a later step.

Fixes #7808

@arpad-m arpad-m requested review from jcsp and koivunej May 20, 2024 22:06
@arpad-m arpad-m requested a review from a team as a code owner May 20, 2024 22:06
Copy link

github-actions bot commented May 20, 2024

3096 tests run: 2969 passed, 0 failed, 127 skipped (full report)


Flaky tests (3)

Postgres 16

  • test_crafted_wal_end[last_wal_record_xlog_switch]: debug

Postgres 14

  • test_crafted_wal_end[wal_record_crossing_segment_followed_by_small_one]: debug
  • test_timeline_deletion_with_files_stuck_in_upload_queue: debug

Code coverage* (full report)

  • functions: 31.3% (6414 of 20474 functions)
  • lines: 48.0% (49312 of 102742 lines)

* collected from Rust tests only


The comment gets automatically updated with the latest test results
62b9583 at 2024-05-21T20:20:11.776Z :recycle:

@arpad-m arpad-m changed the title Add empty lsn API Add empty lsn lease API to pageserver page service and http May 20, 2024
@arpad-m arpad-m changed the title Add empty lsn lease API to pageserver page service and http Add dummy lsn lease http and page service APIs May 20, 2024
Copy link
Contributor

@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.

Smaller nits. I think adding documentation when adding stuff to our models.rs "stuff holder" would help make sense of that file without understanding all of the other code.

Co-authored-by: Joonas Koivunen <joonas@neon.tech>
@arpad-m arpad-m merged commit 679e031 into main May 21, 2024
55 checks passed
@arpad-m arpad-m deleted the arpad/lease_lsn_api branch May 21, 2024 21:31
arpad-m added a commit that referenced this pull request May 22, 2024
In the process_query function in page_service.rs there was some
redundant duplication. Remove it and create a vector of whitespace
separated parts at the start and then use `slice::strip_prefix`. Only
use `starts_with` in the places with multiple whitespace separated
parameters: here we want to preserve grep/rg ability.

Followup of #7815, requested in
#7815 (review)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement dummy lease API implementation
4 participants