Skip to content

sync.Pool for expectation channels in SyncProducer #3107

@kasimtj

Description

@kasimtj

Description

We encountered excessive channel creations in SyncProducer.SendMessage/SendMessages methods, application profiling showed that 10% of cpu time spent on channel creation for callback purpose. Lifetime of this channels are short and seems that they can be reused instead of being closed

Additional context

Profiling from production application

Image

I ran benchmarks locally, results are here #3106

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