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

UniPS: Catch exception when dumping incr snapshot #9407

Merged
merged 24 commits into from
Sep 4, 2024

Conversation

CalvinNeo
Copy link
Member

@CalvinNeo CalvinNeo commented Sep 4, 2024

What problem does this PR solve?

Issue Number: close #9406, close #9098

Problem Summary:

  1. Print error message and stack
  2. Print error when GetObject timeout

What is changed and how it works?


Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

None

a
Signed-off-by: Calvin Neo <[email protected]>
@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-linked-issue release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Sep 4, 2024
a
Signed-off-by: Calvin Neo <[email protected]>
g
Signed-off-by: Calvin Neo <[email protected]>
Signed-off-by: Calvin Neo <[email protected]>
Signed-off-by: Calvin Neo <[email protected]>
Signed-off-by: Calvin Neo <[email protected]>
Signed-off-by: Calvin Neo <[email protected]>
Signed-off-by: Calvin Neo <[email protected]>
Signed-off-by: Calvin Neo <[email protected]>
Signed-off-by: Calvin Neo <[email protected]>
Copy link
Contributor

ti-chi-bot bot commented Sep 4, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JinheLin, Lloyd-Pottiger

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [JinheLin,Lloyd-Pottiger]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Sep 4, 2024
Copy link
Contributor

ti-chi-bot bot commented Sep 4, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-09-04 07:48:48.743261317 +0000 UTC m=+430653.261314241: ☑️ agreed by JinheLin.
  • 2024-09-04 08:46:58.852466659 +0000 UTC m=+434143.370519583: ☑️ agreed by Lloyd-Pottiger.

@CalvinNeo
Copy link
Member Author

/retest

= writer->writeEditsAndApplyCheckpointInfo(edit_from_mem, compact_opts, options.only_upload_manifest);
data_file_paths = writer->writeSuffix();
fiu_do_on(FailPoints::force_checkpoint_dump_throw_datafile, {
throw Exception(ErrorCodes::LOGICAL_ERROR, "fake checkpoint write exception");
Copy link
Contributor

@JaySon-Huang JaySon-Huang Sep 4, 2024

Choose a reason for hiding this comment

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

nit change

Suggested change
throw Exception(ErrorCodes::LOGICAL_ERROR, "fake checkpoint write exception");
throw Exception(ErrorCodes::FAIL_POINT_ERROR, "fake checkpoint write exception");

Copy link
Member Author

Choose a reason for hiding this comment

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

It should be LOGICAL_ERROR. Because there is another error ErrorCodes::REGION_DATA_SCHEMA_UPDATED which could make prehandle to retry. So error codes matters here.

dbms/src/Storages/Page/V3/CheckpointFile/CPFilesWriter.cpp Outdated Show resolved Hide resolved
@purelind
Copy link
Collaborator

purelind commented Sep 4, 2024

/retest

@JaySon-Huang
Copy link
Contributor

/hold

@ti-chi-bot ti-chi-bot bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 4, 2024
@JaySon-Huang
Copy link
Contributor

JaySon-Huang commented Sep 4, 2024

@CalvinNeo In summary:

  1. operator * / operator-> is a more concise way to accessing an std::optional instance
  2. When logging down the elapsed time in seconds, better use "{:.3f}" to format the output. The output of a floating number using "{}" is not readable sometime.
    here is an example: https://godbolt.org/z/qvrxT7q1Y

@CalvinNeo
Copy link
Member Author

@CalvinNeo In summary:

  1. operator * / operator-> is a more concise way to accessing an std::optional instance
  2. When logging down the elapsed time in seconds, better use "{:.3f}" to format the output. The output of a floating number using "{}" is not readable sometime.
    here is an example: https://godbolt.org/z/qvrxT7q1Y

Got it

@CalvinNeo
Copy link
Member Author

/unhold

@ti-chi-bot ti-chi-bot bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 4, 2024
Copy link
Contributor

ti-chi-bot bot commented Sep 4, 2024

@CalvinNeo: Your PR was out of date, I have automatically updated it for you.

At the same time I will also trigger all tests for you:

/run-all-tests

trigger some heavy tests which will not run always when PR updated.

If the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

@ti-chi-bot ti-chi-bot bot merged commit abb577e into pingcap:master Sep 4, 2024
5 checks passed
CalvinNeo added a commit to CalvinNeo/tiflash that referenced this pull request Sep 23, 2024
…gcap#284)

Signed-off-by: Calvin Neo <[email protected]>
Co-authored-by: ti-chi-bot[bot] <108142056+ti-chi-bot[bot]@users.noreply.github.com>
Co-authored-by: JaySon <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
5 participants