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

Perf[MQB]: throttle logs critical for broadcast #482

Merged
merged 2 commits into from
Oct 28, 2024

Conversation

678098
Copy link
Collaborator

@678098 678098 commented Oct 28, 2024

Logging every 500 cached PUTs expiration not only generates gigabytes of logs, but also potentially limits broadcast speed.

@678098 678098 requested a review from a team as a code owner October 28, 2024 11:04
<< "pending PUSH messages";
BALL_LOG_DEBUG << d_state_p->uri() << ": "
<< "no more timer scheduled to check expiration of "
<< "pending PUSH messages";
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The same severity as a few lines above

Copy link
Collaborator

@dorjesinpo dorjesinpo left a comment

Choose a reason for hiding this comment

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

Looks good ,but maybe can be simplified

<< bmqt::AckResult::toAscii(ackResult);
if (d_throttledCachedPutMessages.requestPermission()) {
BALL_LOG_INFO << d_state_p->uri() << ": erased window of "
<< numErased << " (" << d_expiredPutNum
Copy link
Collaborator

Choose a reason for hiding this comment

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

d_expiredPutNum is more like "total erased broadcast PUTs". But what is the meaning of this counter; why do we need it?

Copy link
Collaborator Author

@678098 678098 Oct 28, 2024

Choose a reason for hiding this comment

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

If we are throttling logs, we still might want to know how many of these we skipped. Might be useful for debug, but also I'm okay to remove it.

<< " cached broadcasted PUTs upon "
<< bmqt::AckResult::toAscii(ackResult);
if (d_throttledCachedPutMessages.requestPermission()) {
BALL_LOG_INFO << d_state_p->uri() << ": erased window of "
Copy link
Collaborator

Choose a reason for hiding this comment

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

This could very well be BALL_LOG_DEBUG. This log does not have much importance.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Will redo it to debug then and remove the counter. Let's keep it simple.

Signed-off-by: Evgeny Malygin <[email protected]>
@678098 678098 requested a review from dorjesinpo October 28, 2024 14:07
@678098
Copy link
Collaborator Author

678098 commented Oct 28, 2024

@dorjesinpo simplified the changes

@678098 678098 merged commit 6d3790f into bloomberg:main Oct 28, 2024
13 checks passed
@678098 678098 deleted the 241028_fix_frequent_logging branch October 28, 2024 14:23
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.

2 participants