Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into ws-toilet
Browse files Browse the repository at this point in the history
  • Loading branch information
schlawg committed Sep 26, 2024
2 parents 566be56 + 34da272 commit 78fb9f5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/main/scala/Monitor.scala
Original file line number Diff line number Diff line change
Expand Up @@ -190,3 +190,4 @@ object Monitor:
val maxDelay = Kamon.gauge("connector.flush.config.maxDelay").withoutTags()
val qSize = Kamon.histogram("connector.flush.qSize").withoutTags()
val channelsToFlush = Kamon.histogram("connector.flush.channelsToFlush").withoutTags()
val scheduledHit = Kamon.counter("connector.scheduledHit").withoutTags()
5 changes: 5 additions & 0 deletions src/main/scala/netty/ActorChannelConnector.scala
Original file line number Diff line number Diff line change
Expand Up @@ -82,3 +82,8 @@ final private class ActorChannelConnector(
else if flushQ.isEmpty then 1.second // hibernate
else 1.millis // interval is 0 but we still need to empty the queue
scheduler.scheduleOnce(nextInterval, () => flush())

def scheduledHit(): Unit =
Monitor.connector.scheduledHit.increment()
scheduler.scheduleOnce(1 millis, () => scheduledHit())
scheduledHit()

0 comments on commit 78fb9f5

Please sign in to comment.