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

node: Add logging thread to node monitoring wg #4934

Merged
merged 2 commits into from
Jan 6, 2023

Conversation

Eric-Warehime
Copy link
Contributor

Summary

This commit runs a goroutine without adding it to the monitoring wg.

@codecov
Copy link

codecov bot commented Dec 22, 2022

Codecov Report

Merging #4934 (9095e27) into master (3fbe53c) will increase coverage by 0.02%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##           master    #4934      +/-   ##
==========================================
+ Coverage   53.51%   53.53%   +0.02%     
==========================================
  Files         432      432              
  Lines       53615    53616       +1     
==========================================
+ Hits        28691    28706      +15     
+ Misses      22695    22682      -13     
+ Partials     2229     2228       -1     
Impacted Files Coverage Δ
node/node.go 4.27% <0.00%> (-0.01%) ⬇️
cmd/tealdbg/debugger.go 72.69% <0.00%> (-0.81%) ⬇️
ledger/catchpointtracker.go 57.70% <0.00%> (-0.80%) ⬇️
network/wsNetwork.go 64.92% <0.00%> (ø)
network/wsPeer.go 69.21% <0.00%> (+0.23%) ⬆️
catchup/service.go 70.04% <0.00%> (+0.24%) ⬆️
ledger/testing/randomAccounts.go 56.26% <0.00%> (+0.61%) ⬆️
agreement/proposalManager.go 98.03% <0.00%> (+1.96%) ⬆️
agreement/cryptoVerifier.go 69.71% <0.00%> (+2.11%) ⬆️
ledger/tracker.go 78.90% <0.00%> (+4.64%) ⬆️
... and 1 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@@ -399,6 +399,7 @@ func (node *AlgorandFullNode) startMonitoringRoutines() {
go node.oldKeyDeletionThread(node.ctx.Done())

if node.config.EnableUsageLog {
node.monitoringRoutinesWaitGroup.Add(1)
Copy link
Contributor

Choose a reason for hiding this comment

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

there is not corresponding monitoringRoutinesWaitGroup.Done()

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah you're right. It should be passed in via go logging.UsageLogThread(node.ctx, node.log, 100*time.Millisecond, node.monitoringRoutinesWaitGroup). I'm curious why we ended up passing nil instead.

@algorandskiy algorandskiy merged commit fc4e462 into algorand:master Jan 6, 2023
winder pushed a commit to winder/go-algorand that referenced this pull request Jan 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants