question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support ScheduledExecutorService per-execution monitoring

See original GitHub issue

Hi!

The latest version of Micrometer (1.1.0) supports per-execution ExecutorService monitoring via TimedExecutorService.

In Project Reactor, we use ScheduledExecutorService (extended version of ExecutorService). Would be nice if Micrometer will add it to ExecutorServiceMetrics, so that we can transparently reuse the infrastructure provided by Micrometer.

See https://github.com/reactor/reactor-core/pull/1281

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:14 (9 by maintainers)

github_iconTop GitHub Comments

5reactions
fragonibcommented, Dec 19, 2018

My understanding is that timed submitted tasks within ExecutorService implies a micrometer strategy that uses a wrapping executor with TimedExecutorService.

Therefore I guess that just using current ExecutorService instrumentation leave some ScheduledExecutorService mehods that submit tasks without being wrapped with Timer. Methods ScheduledExecutorService.schedule, scheduleAtFixedRate and scheduleWithFixedDelay doesn’t submit a task wrapped with Timer.

Also an ExecutorServiceMetrics.monitor specialized for ScheduledExecutorService would be nice.

1reaction
slovdahlcommented, Mar 18, 2019

I have a WIP branch on https://github.com/slovdahl/micrometer/tree/scheduled-executor-service-timings, I’ll submit a PR tomorrow unless there are any objections.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Continuous Monitoring of a function in Java on a single thread
1 Answer 1 ... Make use of scheduleAtFixedRate's method of ScheduledExecutorService method in order to execute the task at regular intervals ...
Read more >
ScheduledExecutorService (Java Platform SE 7 )
An ExecutorService that can schedule commands to run after a given delay, or to execute periodically. The schedule methods create tasks with various...
Read more >
InstrumentedScheduledExecutor...
An ScheduledExecutorService that monitors the number of tasks submitted, running, completed and also keeps a Timer for the task duration.
Read more >
Scheduled Executor Service
ScheduledExecutorService , partially. By partially, we mean the behavior difference in scheduling a task at a fixed rate ( scheduleAtFixedRate() ). Hazelcast's ...
Read more >
Java Tips: Creating a Monitoring-Friendly ExecutorService
This monitoring capability will help us to measure a number of pool parameters i.e., active threads, work queue size etc. in a live...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found