Skip to content

feat: metric for dropped messages in Shard Region buffer#32887

Merged
sebastian-alfers merged 4 commits intosharding-telemetryfrom
buffer-dropped
Feb 17, 2026
Merged

feat: metric for dropped messages in Shard Region buffer#32887
sebastian-alfers merged 4 commits intosharding-telemetryfrom
buffer-dropped

Conversation

@sebastian-alfers
Copy link
Contributor

No description provided.

/**
* Drop a mesage send to a Shard Region as the buffer is full
*/
def dropMessagesShardRegion(selfAddress: Address, self: ActorRef, typeName: String): Unit
Copy link
Contributor

Choose a reason for hiding this comment

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

Could the name reflect what the doc says better? shardRegionBufferOverflowMessageDrop is a mouthful but says what it does right away.

Also wondering about the imperative names here in general, is that style we have used for other instrumentation rather than facts that something happened? dropMessage vs messageDropped. The method here is reporting that it happened, rather than dropping anything.

Copy link
Contributor

Choose a reason for hiding this comment

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

Looking at CircuitBreakerTelemetry we have onOpen, onClose. In projections Telemetry we have stopped, failed, beforeProcess, afterProcess (but also error rather than onError) so not quite consistent.

It-happened-naming seems more clear, to me, at least.

Copy link
Member

Choose a reason for hiding this comment

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

The naming we use in cinnamon is messageDropped.

Copy link
Contributor

@johanandren johanandren left a comment

Choose a reason for hiding this comment

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

Looks good but a naming question/discussion

* Drop a message send to a Shard Region if the buffer is full.
*/
def shardRegionMessageDropped(selfAddress: Address, self: ActorRef, typeName: String): Unit
def messageDropped(selfAddress: Address, self: ActorRef, typeName: String): Unit
Copy link
Contributor

Choose a reason for hiding this comment

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

Another scaladoc to drop

Copy link
Contributor

@johanandren johanandren left a comment

Choose a reason for hiding this comment

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

LGTM but drop that scaladoc

@sebastian-alfers sebastian-alfers merged commit e8549a1 into sharding-telemetry Feb 17, 2026
10 checks passed
@sebastian-alfers sebastian-alfers deleted the buffer-dropped branch February 17, 2026 10:01
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.

3 participants