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

[rrd4j] Correctly identify Number items with dimensions and persist them in the defined unit #8866

Merged
merged 2 commits into from Oct 27, 2020

Conversation

kaikreuzer
Copy link
Member

The persistence service will now use the defined unit of Number items with dimensions (which is derived from the unit given in its state description or - if not set - from the defaults of the used measurement system) for both writing and reading values from the database.

Fixes #8809
Fixes #8856

Signed-off-by: Kai Kreuzer kai@openhab.org

…he defined unit

Signed-off-by: Kai Kreuzer <kai@openhab.org>
@kaikreuzer kaikreuzer added the bug An unexpected problem or unintended behavior of an add-on label Oct 25, 2020
Copy link
Contributor

@lolodomo lolodomo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@wborn wborn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot! 👍

Signed-off-by: Wouter Born <github@maindrain.net>
@wborn wborn merged commit 4cd2a5b into openhab:main Oct 27, 2020
@ghys
Copy link
Member

ghys commented Oct 31, 2020

FYI, either this or a related rrd4j PR had a significant impact on performance with retrieving data from /rest/persistence.
On my RPi3-equivalent, requests that used to be instant now take seconds.

image

Also some things in the UI, like the analyzer, don't work anymore because the unit comes with the number.

@kaikreuzer kaikreuzer deleted the rrdquant branch October 31, 2020 15:09
@kaikreuzer
Copy link
Member Author

FYI, either this or a related rrd4j PR had a significant impact on performance with retrieving data from /rest/persistence.

No idea what could cause this - I don't see any performance degradation on my system so far.

Also some things in the UI, like the analyzer, don't work anymore because the unit comes with the number.

I just noticed the same after upgrading and @lolodomo reported openhab/openhab-core#1781.

@ghys
Copy link
Member

ghys commented Oct 31, 2020

(Copied from openhab/openhab-core#1781 (comment))

I have now downgraded to the M1 version of the rrd4j bundle and I'm back to acceptable perf levels again:
(see ~60ms vs 3.5s)

image

I would suspect there's something way heavier than before being done for each data point.

nowaterman pushed a commit to nowaterman/openhab-addons that referenced this pull request Jan 19, 2021
boehan pushed a commit to boehan/openhab-addons that referenced this pull request Apr 12, 2021
…hem in the defined unit (openhab#8866)

Signed-off-by: Kai Kreuzer <kai@openhab.org>
marcfischerboschio pushed a commit to bosch-io/openhab-addons that referenced this pull request May 5, 2022
…hem in the defined unit (openhab#8866)

Signed-off-by: Kai Kreuzer <kai@openhab.org>
@openhab-bot
Copy link
Collaborator

This pull request has been mentioned on openHAB Community. There might be relevant details there:

https://community.openhab.org/t/persistence-sitemap-charts-blank/153654/1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An unexpected problem or unintended behavior of an add-on
Projects
None yet
5 participants