Skip to content

Detecting ring buffer overflows? #6

@tmm1

Description

@tmm1

I'm using a simple ring buffer, as so:

buffer.NewRing(buffer.New(8<<20))

In order to size the ring buffer for my use-case appropriately, I would like to collect some stats on how often it overflows (causing old data to be overwritten). I'm happy to open a PR to this effect, but wanted to discuss a sane API for exposing this information first.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions