Skip to content

Use Buffer as cache in RangeWrite #4453

Closed

Description

@Xuanwo

RangeWrite uses Bytes as cache:

fn fill_cache(&mut self, bs: Bytes) -> usize {
let size = bs.len();
assert!(self.buffer.is_none());
self.buffer = Some(bs);
size
}

We should replace it with Buffer instead to avoid extra copy.

Activity

  1. added
    good first issue
    help wanted
    on Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    coregood first issuehelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions