meilisearch / meilisearch-go

Golang wrapper for the Meilisearch API
https://www.meilisearch.com
MIT License
480 stars 81 forks source link

WaitForTask leaking CPU usage #522

Closed thisisdev-patrick closed 2 months ago

thisisdev-patrick commented 2 months ago

Description WaitForTask using CPU when Idle (simulation included)

Expected behavior 0 % CPU

Current behavior 4000 Calls to WaitForTask causing 10-15% CPU usage

Screenshots or Logs Arch: image MacOS: image

Environment (please complete the following information):

Simulation code:

https://gist.github.com/thisisdev-patrick/da24fb4757820c611e2ea696d2e93953

curquiza commented 2 months ago

Hello @thisisdev-patrick thanks for the report

Any PRs are welcome to help on this 🙏

thisisdev-patrick commented 2 months ago

working on it