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

server: if status address already in use, return an error #15177

Merged
merged 5 commits into from
Mar 18, 2020

Conversation

zimulala
Copy link
Contributor

@zimulala zimulala commented Mar 6, 2020

What problem does this PR solve?

If the status address already in use, we only log it. We don't know why the status server is unavailable except by looking at the logs.
If we don't start the status server, we can set report-status to false.

What is changed and how it works?

If the status address already in use, we return an error and interrupt the service.

Check List

Tests

  • Unit test

Related changes

  • Need to cherry-pick to the release branch

Release note

  • If the status address already in use, return an error

@zimulala zimulala added type/enhancement The issue or PR belongs to an enhancement. component/server needs-cherry-pick-3.0 labels Mar 6, 2020
@codecov
Copy link

codecov bot commented Mar 6, 2020

Codecov Report

❗ No coverage uploaded for pull request base (master@de474b4). Click here to learn what that means.
The diff coverage is n/a.

@@             Coverage Diff             @@
##             master     #15177   +/-   ##
===========================================
  Coverage          ?   80.3849%           
===========================================
  Files             ?        502           
  Lines             ?     134030           
  Branches          ?          0           
===========================================
  Hits              ?     107740           
  Misses            ?      17836           
  Partials          ?       8454

@jackysp
Copy link
Member

jackysp commented Mar 9, 2020

How to avoid the rolling upgrade failure?

@zimulala
Copy link
Contributor Author

@jackysp
I don't understand. If the status address is bind, if we don't return an error(the behavior like before this RP), the rolling upgrade also a failure.

@zimulala
Copy link
Contributor Author

PTAL @jackysp @lysu

@jackysp jackysp requested a review from coocood March 18, 2020 02:58
Copy link
Member

@jackysp jackysp left a comment

Choose a reason for hiding this comment

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

LGTM

@jackysp jackysp added the status/LGT1 Indicates that a PR has LGTM 1. label Mar 18, 2020
@coocood
Copy link
Member

coocood commented Mar 18, 2020

LGTM

@jackysp
Copy link
Member

jackysp commented Mar 18, 2020

/merge

@sre-bot sre-bot added the status/can-merge Indicates a PR has been approved by a committer. label Mar 18, 2020
@sre-bot
Copy link
Contributor

sre-bot commented Mar 18, 2020

Your auto merge job has been accepted, waiting for 15425

@zimulala zimulala added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Mar 18, 2020
@sre-bot
Copy link
Contributor

sre-bot commented Mar 18, 2020

/run-all-tests

@sre-bot
Copy link
Contributor

sre-bot commented Mar 18, 2020

@zimulala merge failed.

@jackysp
Copy link
Member

jackysp commented Mar 18, 2020

/merge

@sre-bot
Copy link
Contributor

sre-bot commented Mar 18, 2020

/run-all-tests

@sre-bot
Copy link
Contributor

sre-bot commented Mar 18, 2020

@zimulala merge failed.

@bb7133
Copy link
Member

bb7133 commented Mar 18, 2020

/run-unit-test /run-integration-common-test

@bb7133 bb7133 merged commit f8b2d96 into pingcap:master Mar 18, 2020
sre-bot pushed a commit to sre-bot/tidb that referenced this pull request Mar 18, 2020
Signed-off-by: sre-bot <sre-bot@pingcap.com>
@sre-bot
Copy link
Contributor

sre-bot commented Mar 18, 2020

cherry pick to release-3.0 in PR #15466

@zimulala zimulala deleted the status-port branch March 18, 2020 11:08
@you06 you06 added this to the v4.0.0-rc milestone Mar 27, 2020
@sre-bot
Copy link
Contributor

sre-bot commented Apr 7, 2020

It seems that, not for sure, we failed to cherry-pick this commit to release-3.1. Please comment '/run-cherry-picker' to try to trigger the cherry-picker if we did fail to cherry-pick this commit before. @zimulala PTAL.

@zimulala
Copy link
Contributor Author

/run-cherry-picker

@sre-bot
Copy link
Contributor

sre-bot commented Apr 10, 2020

cherry pick to release-3.1 in PR #16291

sre-bot pushed a commit to sre-bot/tidb that referenced this pull request Apr 10, 2020
Signed-off-by: sre-bot <sre-bot@pingcap.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/server status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. type/enhancement The issue or PR belongs to an enhancement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants