Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API collector: high CPU load even if no message are processed #2108

Closed
ghost opened this issue Sep 9, 2021 · 0 comments
Closed

API collector: high CPU load even if no message are processed #2108

ghost opened this issue Sep 9, 2021 · 0 comments
Labels
bug Indicates an unexpected problem or unintended behavior component: bots component: core
Milestone

Comments

@ghost
Copy link

ghost commented Sep 9, 2021

The API collector is consuming a lot of CPU, up to 100%, independent of the actual message load. strace shows, that the bot is always polling redis, for the stats (which are written after the process execution).

The problem is, that the bot declares

__collector_empty_process: bool = True

but this attribute is part of the Bot class:
__collector_empty_process: bool = False

and should therefore be called _Bot__collector_empty_process to be effective. And actually, this should just be called _collector_empty_process

@ghost ghost added bug Indicates an unexpected problem or unintended behavior component: bots component: core labels Sep 9, 2021
@ghost ghost added this to the 3.0.2 milestone Sep 9, 2021
@ghost ghost self-assigned this Sep 9, 2021
ghost pushed a commit that referenced this issue Sep 9, 2021
Make private members `__is_multithreadable` and `__collector_empty_process` protected members `_is_multithreadable` and `_collector_empty_process` to make them easily modifiable by Bot classes

fixes #2108
ghost pushed a commit that referenced this issue Sep 9, 2021
Make private members `__is_multithreadable` and `__collector_empty_process` protected members `_is_multithreadable` and `_collector_empty_process` to make them easily modifiable by Bot classes

fixes #2108
@ghost ghost closed this as completed in 5c91a8c Sep 10, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates an unexpected problem or unintended behavior component: bots component: core
Projects
None yet
Development

No branches or pull requests

0 participants