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

WIP: adjust the operator log level programmatically #1022

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

ffromani
Copy link
Member

WIP TBD

Fixes: #921

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 24, 2024
Copy link
Contributor

openshift-ci bot commented Sep 24, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ffromani

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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 24, 2024
@ffromani ffromani force-pushed the intloglevel branch 4 times, most recently from 16bef84 to 5bbaf83 Compare September 25, 2024 16:59
@shajmakh
Copy link
Member

/cc @shajmakh

spec.LogLevel = defaultLog
}
if spec.OperatorLogLevel == nil {
spec.OperatorLogLevel = &defaultLog
Copy link
Member Author

Choose a reason for hiding this comment

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

nope. We need to fetch from the command line.

// +optional
// +kubebuilder:default=Normal
//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Operator log verbosity"
OperatorLogLevel *operatorv1.LogLevel `json:"operatorLogLevel,omitempty"`
Copy link
Member Author

Choose a reason for hiding this comment

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

should this be an int? probably so, otherwise the mapping with the int flag is poor.

instance.Status.OperatorLogLevel = lev
needStatusUpdate = true
}
}
Copy link
Member Author

Choose a reason for hiding this comment

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

else  {
    instance.Status.OperatorLogLeve = intkloglevel.Get() // needs adjustment, but this is the idea
}

Signed-off-by: Francesco Romani <[email protected]>
Signed-off-by: Francesco Romani <[email protected]>
Signed-off-by: Francesco Romani <[email protected]>
@ffromani
Copy link
Member Author

ffromani commented Oct 3, 2024

depends on #1032

@openshift-merge-robot openshift-merge-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 12, 2024
@openshift-merge-robot
Copy link
Contributor

PR needs rebase.

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 kubernetes-sigs/prow repository.

Copy link
Contributor

openshift-ci bot commented Nov 7, 2024

@ffromani: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/ci-unit 3817828 link true /test ci-unit
ci/prow/ci-e2e 3817828 link true /test ci-e2e
ci/prow/ci-install-e2e 3817828 link true /test ci-install-e2e
ci/prow/ci-e2e-install-hypershift 3817828 link true /test ci-e2e-install-hypershift
ci/prow/ci-index 3817828 link true /test ci-index

Full PR test history. Your PR dashboard.

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 kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Updating the log level in NROP CR doesn't affect log level of the controller pod of the operator
3 participants