Skip to content

Thread pool exhaustion due to MessageListener running on ThreadPool #824

Closed
@IgorMilavec

Description

@IgorMilavec

Session.Connect() (and Session.ConnectAsync() in #819) start MessageListener through ThreadAbstraction that runs the connection message pump on a ThreadPool thread. This causes thread pool exhaustion when the number of connected sessions reaches the maximum number of thread pool threads. Message loop should not be run through thread pool, as this consumes a (limited) shared resource. Also, running a thread for each session impacts system performance and limits scalability of the application.
Preferably we should avoid consuming an entire thread and make the message loop async.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions