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

feat: add a service option to disable check eovercrowded on server side #2774

Merged
merged 4 commits into from
Oct 14, 2024

Conversation

superhail
Copy link
Contributor

What problem does this PR solve?

Issue Number:

Problem Summary: Sometimes we need to disable check eovercrowded for some methods

What is changed and the side effects?

Changed: add a method/service level option to disable check eovercrowded on server side

Side effects:

  • Performance effects(性能影响): zero/or little

  • Breaking backward compatibility(向后兼容性): no breaking


Check List:

  • Please make sure your changes are compilable(请确保你的更改可以通过编译).
  • When providing us with a new feature, it is best to add related tests(如果你向我们增加一个新的功能, 请添加相关测试).
  • Please follow Contributor Covenant Code of Conduct.(请遵循贡献者准则).

src/brpc/policy/baidu_rpc_protocol.cpp Outdated Show resolved Hide resolved
src/brpc/server.h Show resolved Hide resolved
src/brpc/server.h Outdated Show resolved Hide resolved
src/brpc/server.h Outdated Show resolved Hide resolved
@wwbmmm
Copy link
Contributor

wwbmmm commented Oct 7, 2024

What is the usage scenario of this feature?

@superhail
Copy link
Contributor Author

@wwbmmm we have some control-frame methods which we hope will not fail in case of eovercrowded.

@superhail
Copy link
Contributor Author

@chenBright please help check

Copy link
Contributor

@chenBright chenBright left a comment

Choose a reason for hiding this comment

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

ignore_eovercrowded should also be supported in the HTTP protocol.

@superhail
Copy link
Contributor Author

@chenBright http2 needed as well?

@@ -794,6 +795,7 @@ static bool OptionsAvailableOverRdma(const ServerOptions* opt) {
#endif

static AdaptiveMaxConcurrency g_default_max_concurrency_of_method(0);
static bool g_default_ignore_eovercrowded(false);
Copy link
Contributor

Choose a reason for hiding this comment

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

where is this used?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

i will delete it

@chenBright
Copy link
Contributor

@chenBright http2 needed as well?

http2 also use ProcessHttpRequest.

Protocols that use the is_overcrowded function need as well.

@superhail
Copy link
Contributor Author

@wwbmmm @chenBright all done

@wwbmmm
Copy link
Contributor

wwbmmm commented Oct 14, 2024

LGTM

Copy link
Contributor

@chenBright chenBright left a comment

Choose a reason for hiding this comment

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

LGTM

@chenBright chenBright merged commit 667b96a into apache:master Oct 14, 2024
20 checks passed
@superhail superhail changed the title [feat][WIP] add a method option to disable check eovercrowded on server side [feat]: add a method option to disable check eovercrowded on server side Oct 15, 2024
@superhail superhail changed the title [feat]: add a method option to disable check eovercrowded on server side feat: add a method option to disable check eovercrowded on server side Oct 15, 2024
@superhail superhail changed the title feat: add a method option to disable check eovercrowded on server side feat: add a service option to disable check eovercrowded on server side Oct 21, 2024
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.

3 participants