cats-effect
cats-effect copied to clipboard
Feature Request: Implement a Debugging and Profiling Tool Similar to Tokio-Console
I am writing to propose the implementation of a feature similar to the tokio-console
used in asynchronous Rust applications. This tool has proven to be extremely useful for collecting and displaying in-depth diagnostic data on asynchronous tasks, resources, and operations in an application.
Viewing details for a single task:
In Cats-Effect, we already have the ability to remotely trigger fiber snapshots (see LiveFiberSnapshotTriggerMBean.scala) and expose some coarse metrics in various MBeans (see ComputePoolSamplerMBean.scala). These can be accessed by tools, but a more integrated and user-friendly tool like tokio-console
would be a great addition to the ecosystem.
I believe that the implementation of a similar tool for Cats-Effect would greatly enhance the debugging and profiling experience for developers. I look forward to hearing your thoughts on this proposal.
While I was trying to nerdsnipe @mpilquist into doing this, following links were thrown around:
- Basic intro JMX: I'm just going to keep adding - here's an example of starting the mbean server: https://www.baeldung.com/java-management-extensions
- cjmx - command line JMX tool: https://github.com/cjmx/cjmx
- tui-scala - to implement the rich TUI: https://github.com/oyvindberg/tui-scala
I’m interested in working on something like this. I will create a repo so we can collect ideas, etc.
https://github.com/typelevel/cats-effect-shell
This is cool af. I knew about Tokio shell but had mentally written it off as something we probably wouldn't be able to do. JMX probably gives us an avenue though.