-
Notifications
You must be signed in to change notification settings - Fork 138
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
Switching from logrus to packethost/pkg/log in worker #271
Conversation
Codecov Report
@@ Coverage Diff @@
## master #271 +/- ##
=======================================
Coverage 24.24% 24.24%
=======================================
Files 15 15
Lines 1353 1353
=======================================
Hits 328 328
Misses 1006 1006
Partials 19 19 Continue to review full report at Codecov.
|
Thank you for taking care of it. |
Looks like a fantastic start at this 👍 |
a48369c
to
6960d5f
Compare
@gianarb @thebsdbox |
@gauravgahlot similar to tinkerbell/osie#107 some of those lines look like they did not come from packethost/pkg/log (the ones missing ts, caller, service keys). I suspect those are from output of |
@gauravgahlot please rebase |
6960d5f
to
ffb5798
Compare
## Description The PR updates Boots to use the latest version of `packethost/pkg/log` package. ## Why is this needed Required for dependent [PR tink #271](tinkerbell/tink#271). ## How Has This Been Tested? Tested by executing an end-to-end workflow.
## Description The PR updates Hegel to use the latest version of `packethost/pkg/log` package. ## Why is this needed Required for dependent [PR tink #271](tinkerbell/tink#271). ## How Has This Been Tested? Tested by executing an end-to-end workflow.
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.
Few things need updating wrt the log calls. Also can you change all calls of fmt.Errorf
to errors.Wrapf
instead.
0479ed9
to
0e340e7
Compare
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.
Also can you change the calls to errors.Wrapf to just errors.Wrap where there's no fmt'ing done?
c81380a
to
3d934f7
Compare
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.
2 things should be fixed throughout the whole diff:
- Please update the cases where
errors.Wrapf
was used buterrors.Wrap
is better. - A bunch of log.With()s are called with context keys that aren't very good keys, should single word for easy lookup. Most of the keys uses actually look like they would be passed to
Info()
instead.
c59f765
to
20b962b
Compare
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.
allllllllmost there.
@gauravgahlot can you edit the |
20b962b
to
9c1d7b1
Compare
9c1d7b1
to
266ae83
Compare
The second error type returned by waitContainer was ignored and never logged or used by its only caller executeAction. So, there is no point in returning two error types. Signed-off-by: Gaurav Gahlot <[email protected]>
266ae83
to
d94afc8
Compare
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.
Please squash the review fixes
into the replace 'logrus' with 'packethost/pkg/log'
commit.
review fixes Signed-off-by: Gaurav Gahlot <[email protected]>
Signed-off-by: Gaurav Gahlot <[email protected]>
Signed-off-by: Gaurav Gahlot <[email protected]>
d94afc8
to
92b240d
Compare
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.
Finally! Thanks for all the follow through.
Description
Replacing
logrus
withpackethost/pkg/log
.Depends on:
Why is this needed
The PR aims to keep the logging package consistent across the Tink repository.
How Has This Been Tested?
Tested the changes by executing an end-to-end workflow.
Worker Logs