Skip to content

Improve thread troubleshooting experience #266

Open
@gluck

Description

@gluck

Rx can create threads in various conditions (NewThreadScheduler, EvenLoopScheduler, ThreadPoolScheduler.ScheduleLongRunning, ConcurrencyAbstractionLayer ...), resulting in any leak being impossible to track down to the cause.

Today with the PlatformEnlightmentProvider one can inject thread factories in some of these places, allowing the user to inject troubleshooting information when threads are created such as:

  • debug log before creating thread
  • propagate thread local data
  • forcing background threads
  • formatting extra info into the thread name, such as:
    • parent thread name
    • current UI view/form/window/scene

(in case the user is repacking Rx, he can include the assembly name as well, very useful to us ! - but I digress)

If you ever troubleshoot an application with a thread leak and 200+ Rx threads all called "Thread-#XX", maybe you know where this request comes from :)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions