Skip to content

logging: remove handler's buffer#1796

Merged
pongad merged 1 commit intogoogleapis:masterfrom
pongad:logging-sync
Mar 24, 2017
Merged

logging: remove handler's buffer#1796
pongad merged 1 commit intogoogleapis:masterfrom
pongad:logging-sync

Conversation

@pongad
Copy link
Copy Markdown
Contributor

@pongad pongad commented Mar 23, 2017

LoggingHandler's buffer is redundant,
since it's already using the batching feature.

LoggingHandler.flush previously just flushes its own buffer
and put messages in the batcher's buffer,
without necessarily making RPC calls.
This PR does not fix this problem,
but it makes flush obviously wrong instead of subtly.

The test for flush size is also removed.
Flush size should be forwareded to the batcher,
which already has its own test.

Updates #1795.

LoggingHandler's buffer is redundant,
since it's already using the batching feature.

LoggingHandler.flush previously just flushes its own buffer
and put messages in the batcher's buffer,
without necessarily making RPC calls.
This PR does not fix this problem,
but it makes flush obviously wrong instead of subtly.

The test for flush size is also removed.
Flush size should be forwareded to the batcher,
which already has its own test.

Updates #1795.
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Mar 23, 2017
Copy link
Copy Markdown
Contributor

@garrettjonesgoogle garrettjonesgoogle left a comment

Choose a reason for hiding this comment

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

LGTM

buffer = new LinkedList<>();
}
if (entry != null) {
write(entry, writeOptions);

This comment was marked as spam.

This comment was marked as spam.

@pongad pongad merged commit b5f2281 into googleapis:master Mar 24, 2017
@pongad pongad deleted the logging-sync branch March 24, 2017 03:30
suztomo pushed a commit to suztomo/google-cloud-java that referenced this pull request Mar 11, 2026
suztomo pushed a commit to suztomo/google-cloud-java that referenced this pull request Mar 23, 2026
meltsufin pushed a commit that referenced this pull request May 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants