-
-
Notifications
You must be signed in to change notification settings - Fork 429
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
[OH3] Defining Rules in Main UI increases CPU Load #1877
Comments
+1; same for me on OH3.0.0 stable: It seems to happen when the rule(s) are triggered often, by a constantly changing value (e.g. a temp sensor). The rules seem to take too long to run (e.g. a few seconds for a simple postUpdate) and when there are enough rules running and new ones started upon, the system runs out of memory. So there is a bug in DSL rules processing when they have been defined via the GUI. |
I got this issue as well. My hue dimmer switch state is changed almost instantly, but the rule for it takes like 10 seconds to execute. |
I moved my setup to a Raspberry Pi 4 4GB and now everything is working fine. |
Thanks for the report. I have created #2057 for it, it would be great if you could test a snapshot, once that PR is merged and available in the distro! |
@kaikreuzer: I testet your change with the latest snapshot build an the problem is gone. Thanks a lot for your fix! |
I have a problem with high cpu usage in M2 and M3.
I figuerd out that the reason are rules which are configure over main ui.
I started with 4 rules in a *.rules file with a cpu usage of 1%. In main ui they always stay on "IDLE" after migration them to main ui by copy the generated code by the code view everything was fine, but the logs was full with ERRORs "No pre-parsed script found for e3dc-2". So I deleted the line "// context: e3dc-2" from the code and the log disappears, but the cpu was increased up to 5% per rule and the state stays always on "RUNNING".
Here is my rule code:
It seemed that the rule is parsed every time, because every 5 seconds (5 seconds update period of item E3DC_Extern) I got the log error. Maybe preparsing the rule after saving it in main ui makes the trick.
The text was updated successfully, but these errors were encountered: