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

High CPU usage for zero interval for missing events #328

Open
juacas opened this issue May 4, 2024 · 4 comments
Open

High CPU usage for zero interval for missing events #328

juacas opened this issue May 4, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@juacas
Copy link

juacas commented May 4, 2024

It's not really a big bug because the function does what it says, but it can cause problems difficult to detect by the users

Describe the bug
When "interval for missing events" is set to zero Magic Areas consumes all the CPU in the thread of the event loop.

It impacts severely in overall HA performance.

Maybe other small values will behave similar.
To Reproduce

Select any area.
Configure interval for missing events to zero.
See the CPU performance and Magic Areas' debug logs.

Expected behavior
1- interpret 0 as "no checking of missing events". This is a common convention.
2- check for a reasonable range of values maybe related to "clearing interval".

Best regards.

@juacas juacas added the bug Something isn't working label May 4, 2024
@jseidl
Copy link
Owner

jseidl commented May 5, 2024

This seems very reasonable. Added to the backlog

@jseidl
Copy link
Owner

jseidl commented Sep 5, 2024

This should be fixed by now as update interval is no longer configurable :P (solved itself)

@jseidl jseidl closed this as completed Sep 5, 2024
@jseidl
Copy link
Owner

jseidl commented Sep 5, 2024

Misspoke, that's not the case, still valid issue

@jseidl jseidl reopened this Sep 5, 2024
@jseidl
Copy link
Owner

jseidl commented Sep 9, 2024

I wonder if there's a use case for this option to be configurable. I'm split between adding limits vs removing this configuration option completely. Thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants