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

QPS config #127

Merged

Conversation

JustinKuli
Copy link
Member

@JustinKuli JustinKuli commented Apr 21, 2023

The recommended settings are like 2:30:45 for concurrency:qps:burst. When QPS or Burst are not explicitly set, they will scale based on concurrency.

Refs:

This should help keep things a little bit more clear as we add more
options.

Signed-off-by: Justin Kulikauskas <jkulikau@redhat.com>
flags.Float32Var(
&opts.clientQPS,
"client-max-qps",
30, // 15 * concurrency is recommended
Copy link
Member

Choose a reason for hiding this comment

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

I was thinking that if the QPS is not explicitly set, then we can do 15 * evaluationConcurrency rather than rely on the user to know they should also adjust QPS.

Copy link
Member Author

Choose a reason for hiding this comment

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

I was planning on doing that kind of configuration in the addon-controller, but I can do it here.

@@ -176,6 +153,9 @@ func main() {
os.Exit(1)
}

cfg.Burst = int(opts.clientBurst)
cfg.QPS = opts.clientQPS
Copy link
Contributor

Choose a reason for hiding this comment

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

Where cfg.QPS used?

Copy link
Member

@mprahl mprahl Apr 24, 2023

Choose a reason for hiding this comment

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

cfg gets assigned to targetK8sConfig which then gets used to create Kubernetes API client instances for ConfigurationPolicyReconciler. It's also used by the controller-runtime manager to create a Kubernetes API client.

The recommended settings are 2:30:45 for concurrency:qps:burst. When QPS
or Burst are not explicitly set, they will scale based on concurrency.

Refs:
 - https://issues.redhat.com/browse/ACM-4297

Signed-off-by: Justin Kulikauskas <jkulikau@redhat.com>
@openshift-ci
Copy link

openshift-ci bot commented Apr 25, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JustinKuli, mprahl

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:

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants