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

playground: add panic guard to prevent some corner cases #2457

Merged
merged 1 commit into from
Sep 5, 2024

Conversation

xhebox
Copy link
Collaborator

@xhebox xhebox commented Sep 4, 2024

What problem does this PR solve?

When something is wrong, and tiup did not start the component correctly, playground instance may have a nil process pointer. Let us just prevent it from panic.

Refer https://do.pingcap.net/jenkins/blue/organizations/jenkins/tikv%2Fpd%2Fpull_integration_realcluster_test/detail/pull_integration_realcluster_test/809/pipeline/.

Check List

Tests

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

Code changes

  • Has exported function/method change
  • Has exported variable/fields change
  • Has interface methods change
  • Has persistent data change

Side effects

  • Possible performance regression
  • Increased code complexity
  • Breaking backward compatibility

Related changes

  • Need to cherry-pick to the release branch
  • Need to update the documentation

Release notes:

Prevent possible panic on corner cases of playground startup failure

Signed-off-by: xhe <xw897002528@gmail.com>
Copy link
Contributor

ti-chi-bot bot commented Sep 4, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please ask for approval from xhebox, ensuring that each of them provides their approval before proceeding. For more information see the Code Review Process.

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

Needs approval from an approver in each of these files:

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 the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Sep 4, 2024
@ti-chi-bot ti-chi-bot bot added the lgtm label Sep 5, 2024
Copy link
Contributor

ti-chi-bot bot commented Sep 5, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-09-05 03:20:43.641799055 +0000 UTC m=+500968.159851980: ☑️ agreed by breezewish.

@xhebox xhebox merged commit c1a14a5 into pingcap:master Sep 5, 2024
5 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants