-
Notifications
You must be signed in to change notification settings - Fork 344
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
adding priority-class for esIndexCleaner #1732
adding priority-class for esIndexCleaner #1732
Conversation
thanks @swapnilpotnis for this effort! |
The linter is complaining. You need to regenerate the bundle. You can use the following command. |
Signed-off-by: Swapnil Potnis <[email protected]>
1c067dd
to
f9e8d67
Compare
@rubenvp8510 : Done. |
c34fd9b
to
f76e31a
Compare
DCO is failing, You need to sign your commits :) |
Codecov Report
@@ Coverage Diff @@
## main #1732 +/- ##
==========================================
- Coverage 89.45% 89.42% -0.03%
==========================================
Files 100 100
Lines 6116 6118 +2
==========================================
Hits 5471 5471
- Misses 470 471 +1
- Partials 175 176 +1
Continue to review full report at Codecov.
|
Hi @swapnilpotnis are you still interesting on this one? If so please rebase and sign your commits I think after that it will be ready to be merged :) Thanks for your contribution! |
Really sorry for the late response. Will fix it up by today itself and have the PR ready for review. |
ddf6137
to
6f4c3f0
Compare
Signed-off-by: Swapnil Potnis <[email protected]>
6ce380f
to
5646a21
Compare
7b3e94e
to
c4aa417
Compare
Signed-off-by: Swapnil Potnis <[email protected]>
c4aa417
to
bff72dd
Compare
@rubenvp8510 : hey...I have added the unit test case as well as updated the PR with the latest branch commit. Can you please take a look? |
@rubenvp8510 : can you please allow the tests to be run over the PR again? |
@rubenvp8510 : the earlier check seemed to have failed with the error "Build failed: the api.md file has been changed but the generated api.md file isn't up to date. Run 'make api-docs' and update your PR." (https://github.com/jaegertracing/jaeger-operator/runs/5548885043?check_suite_focus=true#step:6:171) but running the command states that no rule has been found to the target "api-docs". I am a bit confused as to how to deal with the error and google wasn't helpful as well in that aspect. Can you please provide me some pointers?? |
@rubenvp8510 : can you please help me with this?? |
Hi did you rebase your PR? try to run it with the PR rebased on top of main. I checkout your branch and I was able to run it and generated the doc file. I can also push a commit with the change if you want. You should see this rule on your Makefile: https://github.com/jaegertracing/jaeger-operator/blob/main/Makefile#L496 |
230d838
to
7a8f8f5
Compare
Signed-off-by: Swapnil Potnis <[email protected]>
7a8f8f5
to
980c6c5
Compare
@rubenvp8510 : thanks for your help. I have updated the PR with the required changes. Can you please run the checks?? |
Signed-off-by: Swapnil Potnis <[email protected]>
@rubenvp8510 : Forgive me as I wasn't aware of the naming convention that was suppose to be followed for which the earlier check had failed. Can you please re-run the tests as I have rectified the variable name as part of the latest commit? |
No problem :) |
2022-03-23T14:25:57.3007810Z --- FAIL: TestPriorityClassName (0.00s) :( |
@rubenvp8510 : can you please run the tests for the latest commit ? |
@rubenvp8510 : alas..!!! The pipelines finally Green :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi @swapnilpotnis, thanks for your pr. I have only 2 last questions :)
@@ -45,6 +45,11 @@ func CreateEsIndexCleaner(jaeger *v1.Jaeger) *batchv1beta1.CronJob { | |||
|
|||
ca.Update(jaeger, commonSpec) | |||
|
|||
priorityClassName := "" | |||
if jaeger.Spec.Storage.EsIndexCleaner.PriorityClassName != "" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this condition?
if the field is not empty, we update priorityClassName
. But if its empty, we dont update priorityClassName
that is initialized with an empty string.
means it is equal to just priorityClassName := jaeger.Spec.Storage.EsIndexCleaner.PriorityClassName
right?
Would it then make sense to assign it directly in the metav1 object?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree on this comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually I looked at other parts of the code where priorityClass has been reference and this was the general approach followed elsewhere as well. Having to go with the same flow, I implemented the same set of changes
ref:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me know if you guys wish to have the assignment in the metav1 object itself so that I can make the changes. Also let me know if you guys wish to have the same set of changes made at other places as well. If that be the case, should I do it in the same PR or create a new PR altogether??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rubenvp8510 / @frzifus : Guys, can you please share your inputs over it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the long response. From my point of view it would make sense to change it at least in this pr. But feel free to change it on the other places too in this or a new pr. What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. Will make the necessary change only for the priorityClass which is part of this PR.
And would create a new PR for the other 2 PriorityClass.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would say only do the change related to this PR, we can do other changes in a separate PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
still a bit confused, isnt it the same like?
if jaeger.Spec.Storage.EsIndexCleaner.PriorityClassName != "" { | |
priorityClassName := "jaeger.Spec.Storage.EsIndexCleaner.PriorityClassName" |
up to you @rubenvp8510
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with the change, but for not blocking this PR we can do the changes in a follow up PR.
084c7ef
to
f7f292b
Compare
@rubenvp8510 / @frzifus : Can you guys please review my PR? |
@rubenvp8510: thanks alot :) |
Signed-off-by: Swapnil Potnis [email protected]
Which problem is this PR solving?
Short description of the changes