relay icon indicating copy to clipboard operation
relay copied to clipboard

ref(buffer): remove peek

Open jjbayer opened this issue 1 year ago • 0 comments

The envelope buffer does not need to peek to function correctly. Without peek, the stack interface becomes easier to implement.

When an element is removed from a stack, we now keep the received_at of the popped element. This means that we relax the LIFO constraint for the sake of simplicity: a stack might be top-priority even though an other stack might have newer envelopes, but only until the next pop.

Another side effect is that empty stacks remain in the priority queue until another pop attempt is made.

ref: https://github.com/getsentry/team-ingest/issues/345

#skip-changelog

jjbayer avatar Oct 13 '24 12:10 jjbayer