Skip to content

xtrabackup: Add a buffered reader in front of xtrabackup's stdout pipe.#5666

Merged
deepthi merged 1 commit intovitessio:masterfrom
planetscale:xtrabackup-read-buffer
Jan 9, 2020
Merged

xtrabackup: Add a buffered reader in front of xtrabackup's stdout pipe.#5666
deepthi merged 1 commit intovitessio:masterfrom
planetscale:xtrabackup-read-buffer

Conversation

@enisoc
Copy link
Copy Markdown
Member

@enisoc enisoc commented Jan 7, 2020

The buffered reader implements WriteTo(), which allows io.CopyN() to avoid allocating a new buffer every time.

From the flamegraph in #5613, we can see that there is a decent-sized chunk attributed directly to io.copyBuffer (excluding its descendants). This change should eliminate that one section, although it's unlikely this is the real cause of #5613.

The buffered reader implements WriteTo(), which allows io.CopyN() to
avoid allocating a new buffer every time.

Signed-off-by: Anthony Yeh <enisoc@planetscale.com>
Copy link
Copy Markdown
Collaborator

@deepthi deepthi left a comment

Choose a reason for hiding this comment

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

LGTM

@deepthi deepthi merged commit eb923fc into vitessio:master Jan 9, 2020
@deepthi deepthi deleted the xtrabackup-read-buffer branch January 9, 2020 19:55
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