Tags: #<Tag:0x00007fe05dbece28> #<Tag:0x00007fe05dbeccc0>

(Jürgen Baginski) #6

Sorry for not being fluent in html.
Yes, I was referring to the TableHeaders.
Using the call the RestAPI as posted above I do get the items displayed.

Checked the index.html and found some missformed lines (probably caused by copy/paste done via a phone). With the corrected file contents it is working!

Great Job!

(Vincent Regaud) #7


Dropdown to choose the persistence service

(Scott Rushworth) #8

Space was tight, so I added it through a querystring…

http://[openhab server]:8080/static/PersistenceViewer/?rrd4j
http://[openhab server]:8080/static/PersistenceViewer/index.html?rrd4j

(Jürgen Baginski) #9

Using this viewer it will make explaining the way rrd4j is saving data in different archives quite easy.
I do foresee the questions: rrd4j needs saving every minute, why does the viewer not show The minute values for the last xx houres/ days etc? Because you are not looking in archive 1!


(Scott Rushworth) #10

I don’t use rrd4j. Is returning 30 days of data by default too much? I could add another querystring to the URL to configure how far back to go, if no dates are used. Or is changing the dates enough?

(Vincent Regaud) #11

Cool, you da man!

(Jürgen Baginski) #12

IMHO that is enough, in order to look into the different archives of rrd4j one needs to set a specific timeframe. Since that is adjustable the viewer needs this possibility.

(Jürgen Baginski) #13

Question, is MapDB supposed to display data in the viewer
I used:

http://[openhab server]:8080/static/PersistenceViewer/index.html?mapdb
but got only the data from my default persistence (rrd4j).

(Scott Rushworth) #14

I would think so, if it’s queryable. I haven’t used it (I’m only using MariaDB (JDBC). What do you get from…

http://[openhab server]:8080/rest/persistence

(Jürgen Baginski) #15

That gives me rrd4j and mapdb as queryable.
Specifying the serviceID=mapdb does only give an “[]” return

Additionally I am missing some of my Items, especially some that are persisted. Doing a call with the REST API however does show those items.

(Scott Rushworth) #16

In the next couple days, I’ll setup some additional persistence services and look into it.

That’s an odd one. Which persistence service? If you look into the index.html, there is some debugging that’s commented out. See if they help troubleshoot. Are those items in groups? If you don’t specify a startItem, then the script will pull in all items that are groups. That is what you’ll first see in the Items table. If you specify a startItem, you will only see the items in that group.

(Jürgen Baginski) #17

Will look into that after weekend (family meeting because the next generation arrived).

(Vincent Regaud) #18

Baginski 2.0!!

(Jürgen Baginski) #19

:sob: More like 3.0. Thanks

(Scott Rushworth) #20

I found an issue that would have prevented any persistence service from being used other than the default. Try again with the latest. It was working for me with MapDB. And congrats!

(Scott Rushworth) #21

I just made another update that allows for all of the user variables to be put into the URL as a querystring. For example…

http://[openhab server]:8080/static/PersistenceViewer/?serviceId=mapdb&shouldSort=false&startItem=gPersistence

(Scott Rushworth) #22

I added another query string so that the startup behavior can be to load all items (startWithGroups=false). If you have a lot of items, this will cause the page will be very slow to load! The default behavior is to display groups without parents.

(Jürgen Baginski) #23

I found the problem with the missing items! It was between my ears!

I had some items (the ones missing) assigned to a non-existent group!

(Jürgen Baginski) #24

…and the mapDB entries are also shown!

Thank You!

PS: I’m actually most astonished by “was put together by my wife”

(Scott Rushworth) #25

She’s so awesome… documented some of our stuff too… and NEVER an issue with WAF!