Skip to content

Conversation

@connorjclark
Copy link
Collaborator

We do a lot of logging on network events when there is <20 inflight. This can be a lot of string operations that are just done for naught if the logging isn't verbose. so I added a simple check to avoid that.

@connorjclark connorjclark requested a review from a team as a code owner June 4, 2022 00:01
@connorjclark connorjclark requested review from brendankenny and removed request for a team June 4, 2022 00:01
// Wait until it calms down a bit to be a little less spammy.
if (inflightRecords.length < 20) {
if (log.isVerbose() && inflightRecords.length < 20 && inflightRecords.length > 0) {
log.verbose('waitFor', `=== Waiting on ${inflightRecords.length} requests to finish`);
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

this made the logs easier to read for me

@connorjclark connorjclark changed the title core(wait-for): guard verbose logic behind log.isVerbose check core(driver): guard verbose logic behind log.isVerbose check Jun 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants