-
Notifications
You must be signed in to change notification settings - Fork 394
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
WT-13912 Create a new checkpoint struct dedicated to handles information #11347
Conversation
Thanks for creating a pull request! Please answer the questions below by editing this comment. Type of change made in this PR
What makes this change safe?Answering this question helps the reviewers understand where they should focus their attention. Please consider these prompts:
References: Checklist before requesting a review
|
src/checkpoint/checkpoint.h
Outdated
wt_shared wt_off_t logsize; /* Checkpoint log size period */ | ||
bool signalled; /* Checkpoint signalled */ | ||
|
||
WT_CKPT_HANDLE handle; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should I make this plural?
WT_CKPT_HANDLE handle; | |
WT_CKPT_HANDLES handles; /* Checkpoint handles */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The content of the struct doesn't look like there are many handles.
And it doesn't seem to be a handle. I'd rather call it "stats" or something like that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure if I understand correctly your comment or I misunderstood the fields. AFAIK, those fields reflect stats (indeed) about all the dhandles the checkpoint is currently dealing with. It could be one or thousands.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, after seeing @sueloverso's comment and looking at other structures we have in the code, your comment makes sense @ershov, sorry.
@sueloverso, it seems that we use *_info much less than *_stats, would you be ok with WT_CKPT_HANDLE_STATS
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm good with _STATS
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Renamed in 6f129f9
Test coverage is ok, please refer to the Code change/coverage report links below and try to improve it if feasible.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have one naming question/comment. The change overall LGTM.
src/checkpoint/checkpoint.h
Outdated
struct __wt_ckpt_handle_stats { | ||
uint64_t apply; /* handles applied */ | ||
uint64_t apply_time; /* applied handles gather time */ | ||
uint64_t drop; /* handles drop */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some of these are past tense and others are present, could we change them to be consistent. I don't mind which way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated in be24b26
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, with one suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good change, thanks Etienne!
9ec3e7e
to
d4d1908
Compare
The changes introduce a new struct called
WT_CKPT_HANDLE_STATS
that contains all the information related to handles needed by the checkpoint. The existingWT_CKPT_CONNECTION
struct has been updated to use the new struct.