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

feat: redirect daemon stdout stderr to file #1244

Merged
merged 6 commits into from
Apr 14, 2022

Conversation

jim3ma
Copy link
Member

@jim3ma jim3ma commented Apr 13, 2022

Signed-off-by: Jim Ma [email protected]

Description

  1. The dfget daemon will be launched by dfget command in backgroud, the stdout and stderr will be lost.
    So we need redirect them to log files.
  2. Fix zap grpc log is always wrote to stderr.

Related Issue

Motivation and Context

Screenshots (if appropriate)

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation Update (if none of the other choices apply)

Checklist

  • Code compiles correctly.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@jim3ma jim3ma requested a review from a team as a code owner April 13, 2022 10:12
gaius-qi
gaius-qi previously approved these changes Apr 13, 2022
Copy link
Member

@gaius-qi gaius-qi left a comment

Choose a reason for hiding this comment

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

LGTM

hyy0322
hyy0322 previously approved these changes Apr 13, 2022
@jim3ma jim3ma changed the title feat: redirect daemon stdout stderr to file [WIP] feat: redirect daemon stdout stderr to file Apr 13, 2022
@jim3ma jim3ma dismissed stale reviews from hyy0322 and gaius-qi via 5057e0e April 13, 2022 14:17
@jim3ma jim3ma force-pushed the feat/redirect-daemon-stdout-stderr branch from 5057e0e to 613b059 Compare April 14, 2022 03:12
@codecov-commenter
Copy link

codecov-commenter commented Apr 14, 2022

Codecov Report

Merging #1244 (6b77e55) into main (d1a9741) will decrease coverage by 0.17%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1244      +/-   ##
==========================================
- Coverage   47.70%   47.52%   -0.18%     
==========================================
  Files         134      134              
  Lines       10728    10728              
==========================================
- Hits         5118     5099      -19     
- Misses       5045     5063      +18     
- Partials      565      566       +1     
Flag Coverage Δ
Object-compatibility-e2etests ?
e2etests ?
unittests 47.52% <100.00%> (-0.18%) ⬇️

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

Impacted Files Coverage Δ
scheduler/rpcserver/rpcserver.go 25.00% <100.00%> (ø)
...ent/daemon/peer/peertask_piecetask_synchronizer.go 47.59% <0.00%> (-9.64%) ⬇️
client/daemon/peer/piece_broker.go 89.74% <0.00%> (-2.57%) ⬇️
client/daemon/peer/peertask_conductor.go 58.02% <0.00%> (-0.23%) ⬇️

@jim3ma jim3ma force-pushed the feat/redirect-daemon-stdout-stderr branch 2 times, most recently from 4fdcc11 to 7d4ad63 Compare April 14, 2022 04:36
@jim3ma jim3ma changed the title [WIP] feat: redirect daemon stdout stderr to file feat: redirect daemon stdout stderr to file Apr 14, 2022
@jim3ma jim3ma force-pushed the feat/redirect-daemon-stdout-stderr branch from 7d4ad63 to d1799d2 Compare April 14, 2022 06:02
Copy link
Member

@gaius-qi gaius-qi left a comment

Choose a reason for hiding this comment

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

LGTM

@jim3ma jim3ma merged commit 0d10ee4 into main Apr 14, 2022
@jim3ma jim3ma deleted the feat/redirect-daemon-stdout-stderr branch April 14, 2022 06:40
gaius-qi pushed a commit that referenced this pull request Apr 14, 2022
1. redirect daemon stdout stderr to file
2. fix wrong zap grpc log output

Signed-off-by: Jim Ma <[email protected]>
gaius-qi pushed a commit that referenced this pull request Jun 28, 2023
1. redirect daemon stdout stderr to file
2. fix wrong zap grpc log output

Signed-off-by: Jim Ma <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants