-
-
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
[automation] Cache parsed script in order to improve performance #2057
Conversation
Signed-off-by: Kai Kreuzer <kai@openhab.org>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Looks like a very nice performance improvement!
I can't seem to find this PR in the list of fixes for 3.0.1. Does that mean we will have to either switch to snapshots or wait for the next milestone to get it? It's kinda critical for my system. |
Signed-off-by: Kai Kreuzer <kai@openhab.org>
@DanielMalmgren Added. 3.0.1 is not yet announced, unfortunately, there were some issues during the build. |
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
Signed-off-by: Kai Kreuzer <kai@openhab.org> GitOrigin-RevId: 531a478
Since we have a dedicated DSLScriptEngine instance per rule script action, we can easily cache the parsed script.
Parsing seems to cause significant CPU and memory usage - with this PR, there is no noticeable CPU activity anymore and also the heap size does not increase over time anymore.
Fixes #1877
Fixes #2031
Signed-off-by: Kai Kreuzer kai@openhab.org