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

NETOBSERV-1053 optionnal loki / console plugin #354

Merged
merged 7 commits into from
Jun 29, 2023

Conversation

jpinsonneau
Copy link
Contributor

Added enable options on both Loki and ConsolePlugin CR sections. Default true.

  • Loki write stage is skipped in FLP if spec.Loki.enable is false
  • ConsolePlugin is deployed only when both enable options are true, else any existing content is removed.

@@ -94,6 +95,7 @@ spec:
maxBackoff: 5s
maxRetries: 2
consolePlugin:
enable: true
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 feel it would be usefull to be able to disable console plugin even using Loki.
WDYT ?

Copy link
Member

Choose a reason for hiding this comment

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

why not
a downside is adding more settings always makes it feels more complicated to the user - I think we tend to have a bunch of never-used settings that over-complicate the experience
but a "enable" flag looks simple enough to understand so that's fine with me :-)

@codecov
Copy link

codecov bot commented May 31, 2023

Codecov Report

Merging #354 (6ecb1e6) into main (63c9a93) will increase coverage by 0.09%.
The diff coverage is 55.10%.

@@            Coverage Diff             @@
##             main     #354      +/-   ##
==========================================
+ Coverage   53.58%   53.68%   +0.09%     
==========================================
  Files          45       45              
  Lines        5488     5510      +22     
==========================================
+ Hits         2941     2958      +17     
- Misses       2337     2342       +5     
  Partials      210      210              
Flag Coverage Δ
unittests 53.68% <55.10%> (+0.09%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
api/v1alpha1/flowcollector_webhook.go 0.00% <0.00%> (ø)
api/v1alpha1/zz_generated.conversion.go 0.26% <0.00%> (ø)
api/v1beta1/flowcollector_types.go 100.00% <ø> (ø)
...trollers/consoleplugin/consoleplugin_reconciler.go 62.17% <25.00%> (+1.21%) ⬆️
controllers/flowlogspipeline/flp_common_objects.go 86.58% <80.95%> (-0.02%) ⬇️
api/v1beta1/zz_generated.deepcopy.go 52.72% <100.00%> (+1.09%) ⬆️
pkg/helper/flowcollector.go 68.05% <100.00%> (+0.91%) ⬆️

@jotak
Copy link
Member

jotak commented Jun 5, 2023

Thanks!
/lgtm

@openshift-ci openshift-ci bot added the lgtm label Jun 5, 2023
@Amoghrd
Copy link
Contributor

Amoghrd commented Jun 15, 2023

/ok-to-test

@openshift-ci openshift-ci bot added the ok-to-test To set manually when a PR is safe to test. Triggers image build on PR. label Jun 15, 2023
@github-actions
Copy link

New images:

  • quay.io/netobserv/network-observability-operator:d7d492d
  • quay.io/netobserv/network-observability-operator-bundle:v0.0.0-d7d492d
  • quay.io/netobserv/network-observability-operator-catalog:v0.0.0-d7d492d

They will expire after two weeks.

Catalog source:

apiVersion: operators.coreos.com/v1alpha1
kind: CatalogSource
metadata:
  name: netobserv-dev
  namespace: openshift-marketplace
spec:
  sourceType: grpc
  image: quay.io/netobserv/network-observability-operator-catalog:v0.0.0-d7d492d
  displayName: NetObserv development catalog
  publisher: Me
  updateStrategy:
    registryPoll:
      interval: 1m

@Amoghrd
Copy link
Contributor

Amoghrd commented Jun 27, 2023

@jpinsonneau Could you rebase this PR? I can go ahead testing it once thats done

enable:
default: true
description: enable the console plugin deployment. spec.Loki.enable
must be true
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it better if it says must also be true?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Why not 😄
d902fc6

@Amoghrd
Copy link
Contributor

Amoghrd commented Jun 27, 2023

/label qe-approved

@openshift-ci openshift-ci bot added qe-approved QE has approved this pull request and removed lgtm labels Jun 27, 2023
@github-actions github-actions bot removed the ok-to-test To set manually when a PR is safe to test. Triggers image build on PR. label Jun 28, 2023
@jpinsonneau
Copy link
Contributor Author

/label qe-approved

@Amoghrd Did you test it anyways ?

I've rebased the code and addressed your feedback.
Thanks !

@Amoghrd
Copy link
Contributor

Amoghrd commented Jun 28, 2023

Yeah I tested it before rebasing. But will just test again just to be sure everything is working fine after too.

@Amoghrd
Copy link
Contributor

Amoghrd commented Jun 28, 2023

/ok-to-test

@openshift-ci openshift-ci bot added the ok-to-test To set manually when a PR is safe to test. Triggers image build on PR. label Jun 28, 2023
@github-actions
Copy link

New images:

  • quay.io/netobserv/network-observability-operator:3c8afad
  • quay.io/netobserv/network-observability-operator-bundle:v0.0.0-3c8afad
  • quay.io/netobserv/network-observability-operator-catalog:v0.0.0-3c8afad

They will expire after two weeks.

Catalog source:

apiVersion: operators.coreos.com/v1alpha1
kind: CatalogSource
metadata:
  name: netobserv-dev
  namespace: openshift-marketplace
spec:
  sourceType: grpc
  image: quay.io/netobserv/network-observability-operator-catalog:v0.0.0-3c8afad
  displayName: NetObserv development catalog
  publisher: Me
  updateStrategy:
    registryPoll:
      interval: 1m

@Amoghrd
Copy link
Contributor

Amoghrd commented Jun 28, 2023

Tested after rebase, works as expected!

@jotak
Copy link
Member

jotak commented Jun 28, 2023

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Jun 28, 2023
@jpinsonneau
Copy link
Contributor Author

/approve

@openshift-ci
Copy link

openshift-ci bot commented Jun 29, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jpinsonneau

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-merge-robot openshift-merge-robot merged commit e2d77a1 into netobserv:main Jun 29, 2023
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm ok-to-test To set manually when a PR is safe to test. Triggers image build on PR. qe-approved QE has approved this pull request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants