Skip to content

Need batch read API that takes caller-supplied buffer to fill #35

@gammazero

Description

@gammazero

The current batch read API, GetN, creates and returns a new populated buffer on every call. This does not allow the buffer to be reused across multiple calls to GetN, and may result in GC that could be avoided by buffer reuse.

To address this, there should be a new API that takes a buffer, provided by the caller, and drains the queue into that buffer. A call to this API returns when the provided buffer is full or when there are no more items in the queue to drain.

Metadata

Metadata

Assignees

No one assigned

    Labels

    need/triageNeeds initial labeling and prioritization

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions