Announcement

Collapse
No announcement yet.

InfluxDB History appears to be logging ALL devices

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    InfluxDB History appears to be logging ALL devices

    I first got the feeling that something wasn't quite right when I looked at the debug log when I was trying to get InfluxDB history working. I saw what appeared to be a HUGE number of devices being written to the log. I thought that was odd, since I've only configured three devices to store to InfluxDB, but I thought maybe it was specific to the debug setting.

    But now that I have InfluxDB working, I've done a few SHOW MEASUREMENTS commands and I'm seeing every single device change being written. I know there is a setting to do that for SQLite, but I don't have it set. Also, when I click on "Filter by HS Device" on the History page, I only see three devices listed. Thoughts?

    #2
    The plugin design intent is to maintain a dictionary of I column feature references. When HS generates a callback (HSEvent) the plugin looks at the dictionary to assess if it goes tonInfluxDB. The last build I posted for you contains the detail of each HSEvent and the Dictionary status for contains the reference. Look at the debug to assess what is happening.

    Comment


      #3
      Here is one update from the log for a device that shouldn't be getting logged:

      Code:
      5/30/2021 8:47:26 PM    3031622    | InfluxDB Write URI http://192.168.59.9:8086/api/v2/write?bucket=hs2&orgID=homeseer body mcsMQTT,device=rnbWeather_rnbWeather_Air\ Quality value=15
      Click image for larger version

Name:	aqi2.png
Views:	153
Size:	34.3 KB
ID:	1477257

      Comment


        #4
        I realized there was more from the log I should have posted. Here is what I believe are all the lines associated with that device:

        Code:
        5/30/2021 8:47:26 PM 3031622 | HSEvent 511, InfluxDictionary Contains it=True value=15, Type=VALUE_CHANGE
        5/30/2021 8:47:26 PM 3031622 | HSEvent VALUE_CHANGE| 1024| cf20210412171931waqi| 15| 13| 511
        5/30/2021 8:47:26 PM 3031622 | Calling Influx Write from Thread Queue=0
        5/30/2021 8:47:26 PM 3031622 | InfluxDB Write URI http://192.168.59.9:8086/api/v2/write?bucket=hs2&orgID=homeseer body mcsMQTT,device=rnbWeather_rnbWeather_Air\ Quality value=15
        5/30/2021 8:47:26 PM 3031622 | InfluxDB Write After postStream
        5/30/2021 8:47:26 PM 3031622 | 511 has been blacklisted from event callbacks
        5/30/2021 8:47:26 PM 3031666 | InfluxDB Write Response Success

        Comment


          #5
          This does seem like the History tab setting radio is set to save all InfluxDB which is the bottom radio. I see it could be confusing as this setting is grouped under SQLite heading.

          Click image for larger version

Name:	Capture.PNG
Views:	106
Size:	10.4 KB
ID:	1477314

          Comment


            #6
            Mine is set the same as your screenshot. Should I try changing it to save all and then changing it back again?

            Comment


              #7
              I was adding debug info and found one path for non-plugin devices were the global setting logic was inverted. I left the debug in place but I suspect correcting the logic will fix the problem. Update attached.
              Attached Files

              Comment


                #8
                Thanks Michael. I copied the new files. I'll let it run for a while now and let you know how it goes.

                Comment


                  #9
                  It looks good now. Thanks Michael!

                  Comment

                  Working...
                  X