iobroker.influxdb 4.0.2 → 5.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +33 -242
  3. package/RetentionPolicies.md +23 -22
  4. package/admin/i18n/{de/translations.json → de.json} +22 -4
  5. package/admin/i18n/{en/translations.json → en.json} +21 -3
  6. package/admin/i18n/{es/translations.json → es.json} +19 -1
  7. package/admin/i18n/fr.json +107 -0
  8. package/admin/i18n/it.json +107 -0
  9. package/admin/i18n/{nl/translations.json → nl.json} +18 -0
  10. package/admin/i18n/pl.json +107 -0
  11. package/admin/i18n/pt.json +107 -0
  12. package/admin/i18n/ru.json +107 -0
  13. package/admin/i18n/uk.json +107 -0
  14. package/admin/i18n/zh-cn.json +107 -0
  15. package/admin/jsonConfig.json +475 -360
  16. package/admin/jsonCustom.json +1 -1
  17. package/admin/words.js +87 -87
  18. package/build/lib/Database.js +76 -0
  19. package/build/lib/Database.js.map +1 -0
  20. package/build/lib/DatabaseInfluxDB1x.js +194 -0
  21. package/build/lib/DatabaseInfluxDB1x.js.map +1 -0
  22. package/build/lib/DatabaseInfluxDB2x.js +252 -0
  23. package/build/lib/DatabaseInfluxDB2x.js.map +1 -0
  24. package/build/lib/aggregate.js +1398 -0
  25. package/build/lib/aggregate.js.map +1 -0
  26. package/build/main.js +3034 -0
  27. package/build/main.js.map +1 -0
  28. package/docker-compose.yaml +63 -0
  29. package/io-package.json +77 -42
  30. package/package.json +25 -19
  31. package/admin/i18n/fr/translations.json +0 -89
  32. package/admin/i18n/it/translations.json +0 -89
  33. package/admin/i18n/pl/translations.json +0 -89
  34. package/admin/i18n/pt/translations.json +0 -89
  35. package/admin/i18n/ru/translations.json +0 -89
  36. package/admin/i18n/zh-cn/translations.json +0 -89
  37. package/lib/Database.js +0 -30
  38. package/lib/DatabaseInfluxDB1x.js +0 -136
  39. package/lib/DatabaseInfluxDB2x.js +0 -370
  40. package/lib/aggregate.js +0 -1000
  41. package/main.js +0 -2787
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2016-2024 bluefox <dogafox@gmail.com>, apollon77
3
+ Copyright (c) 2016-2026 bluefox <dogafox@gmail.com>, apollon77
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -91,6 +91,7 @@ CREATE USER "user" WITH PASSWORD '<userpassword>'
91
91
  CREATE DATABASE "iobroker"
92
92
  GRANT ALL ON "iobroker" TO "user"
93
93
  ```
94
+
94
95
  Enable authentication by editing /etc/influxdb/influxdb.conf:
95
96
  ```
96
97
  [http]
@@ -105,6 +106,12 @@ Enable authentication by editing /etc/influxdb/influxdb.conf:
105
106
  ```
106
107
  - Restart service: ``` service influxdb restart ```
107
108
 
109
+ ## Self-hosted docker image for InfluxDB
110
+ This version of the adapter could start a self-hosted docker image of InfluxDB 2.x.
111
+ It is not opened for the network and only accessible from localhost. Of course, the docker environment must be installed and running on the host.
112
+
113
+ The `iobroker` user must have access to the docker CLI. To fix the rights start `iob fix`.
114
+
108
115
  ## Installation of Grafana (Charting Tool)
109
116
  There is an additional charting tool for InfluxDB - Grafana.
110
117
  It must be installed additionally.
@@ -375,10 +382,9 @@ sendTo('influxdb.0', 'update', [
375
382
  If you want to flush the buffers for one or all data points to the Database, you can use the build in system function `flushBuffer`:
376
383
 
377
384
  ```javascript
378
- sendTo('influxdb.0', 'flushBuffer', {id: 'mbus.0.counter.xxx'
379
- , result => console.log('deleted, error: ' + result.error));
385
+ sendTo('influxdb.0', 'flushBuffer', {id: 'mbus.0.counter.xxx'}, result => console.log('deleted, error: ' + result.error));
380
386
  ```
381
- if no id is provided all buffers will be flushed.
387
+ if no id is provided, all buffers will be flushed.
382
388
 
383
389
  ## History Logging Management via Javascript
384
390
  The adapter supports enabling and disabling of history logging via JavaScript and also retrieving the list of enabled data points with their settings.
@@ -428,8 +434,8 @@ The message has no parameters.
428
434
 
429
435
  ```javascript
430
436
  sendTo('influxdb.0', 'getEnabledDPs', {}, function (result) {
431
- //result is object like:
432
- {
437
+ // result is an object like:
438
+ console.log(JSON.stringify({
433
439
  'system.adapter.influxdb.0.memRss': {
434
440
  changesOnly: true,
435
441
  debounce: 0,
@@ -440,8 +446,8 @@ sendTo('influxdb.0', 'getEnabledDPs', {}, function (result) {
440
446
  changesRelogInterval: 0,
441
447
  aliasId: ''
442
448
  }
443
- ...
444
- }
449
+ /// ...
450
+ }));
445
451
  });
446
452
  ```
447
453
 
@@ -451,6 +457,24 @@ sendTo('influxdb.0', 'getEnabledDPs', {}, function (result) {
451
457
  -->
452
458
 
453
459
  ## Changelog
460
+ ### 5.0.1 (2026-08-15)
461
+ * (@GermanBluefox) Completely refactored the code to TypeScript and ES6
462
+ * (@GermanBluefox) Added possibility to start docker containers directly from the adapter
463
+ * (mcm1957) Adapter requires admin >= 7.7.2 now
464
+ * (arteck) Fixed the connection handling for InfluxDB 1.x: the health check (ping) and the automatic reconnect were never started
465
+ * (arteck) Fixed the loss of buffered values if the writing was running while new values arrived or if the write failed
466
+ * (arteck) Values are no longer written twice if they are written directly (buffer size 0 or conflicting points)
467
+ * (arteck) State IDs and database names are now escaped in the queries
468
+ * (arteck) The password/token is no longer written into the log by the connection test
469
+ * (arteck) The settings "request timeout" and "validate SSL" are now used for InfluxDB 1.x too
470
+ * (arteck) Fixed the cache file name if more than one instance runs in the compact mode
471
+ * (arteck) Fixed the aggregation for `percentile: 100`/`quantile: 1` and the last value of `integralTotal`
472
+ * (bluefox) Fixed empty charts for the aggregation `onchange` ("raw" in e-charts): it was run through the interval aggregation and returned only `null` values
473
+ * (@GermanBluefox) Minimal node.js version is 22
474
+
475
+ ### 4.0.3 (2024-05-16)
476
+ * (bluefox) Some packages were updated
477
+
454
478
  ### 4.0.2 (2024-01-03)
455
479
  * (bluefox) Corrected JSON config
456
480
  * (Marc-Berg) Corrected filter function in booleanTypeCheckQuery
@@ -465,246 +489,13 @@ sendTo('influxdb.0', 'getEnabledDPs', {}, function (result) {
465
489
  ### 3.1.8 (2022-08-13)
466
490
  * (Apollon77) Fix crash cases reported by Sentry
467
491
 
468
- ### 3.1.7 (2022-06-27)
469
- * (Apollon77) Allows removing a configuration value for "round" in config again
470
-
471
- ### 3.1.6 (2022-06-27)
472
- * (Apollon77) When not count is provided for aggregate "none" or "onchange" then the limit (default 2000) is used as count to define the number of data to return.
473
-
474
- ### 3.1.5 (2022-06-12)
475
- * (Apollon77) Make sure the debug log is active, according to the settings
476
-
477
- ### 3.1.4 (2022-06-08)
478
- * (Apollon77) Performance optimizations for GetHistory calls, especially for "minmax" aggregate method
479
- * (Apollon77) Prevent the crash case reported by Sentry
480
-
481
- ### 3.1.3 (2022-06-01)
482
- * (Apollon77) Corrected issue when testing connection to InfluxDBv1 with weird passwords
483
-
484
- ### 3.1.2 (2022-05-31)
485
- * (Apollon77) Workaround an admin issue when testing connection to InfluxDB
486
-
487
- ### 3.1.0 (2022-05-27)
488
- * (Apollon77) Data are not converted to number if they are other data types on `getHistory` to respect the saved data formats as defined in the datapoint settings for storage.
489
- * (Apollon77) Fix retention change to lower checkbox in UI
490
- * (Apollon77) Allow storeState again to write to InfluxDB for "unknown state ids" - "rules" usage is not supported in for this and storeState would be silently discarded in this case!
491
- * (Apollon77) Fix several crash cases reported by Sentry
492
- * (Apollon77) Make sure disabling "Log changes only" also really do not log the changes anymore
493
- * (Apollon77) Allow storeState and GetHistory also to be called for "unknown ids"
494
-
495
- ### 3.0.2 (2022-05-12)
496
- * (Apollon77) handles an empty Path for InfluxDB 2.0 correctly in all cases
497
-
498
- ### 3.0.1 (2022-05-11)
499
- * (Apollon77) BREAKING: Configuration is only working in the new Admin 5 UI!
500
- * (Apollon77) Did bigger adjustments to the recording logic and added a lot of new Features. Please refer to Changelog and Forum post for details.
501
-
502
- ### 3.0.0 (2022-05-11)
503
- * (Apollon77) Breaking: Configuration is only working in the new Admin 5 UI!
504
- * (Apollon77) Breaking! Did bigger adjustments to the recording logic. Debounce is refined and blockTime is added to differentiate between the two checks
505
- * (Apollon77) Breaking! GetHistory requests now need to deliver the ts in milliseconds! Make sure to use up to date scripts and Charting UIs
506
- * (Apollon77) New setting added to disable the "logging of additional values for charting optimization" - then only the expected data are logged
507
- * (Apollon77) Added new Debug flag to enable/disable debug logging on datapoint level (default is false) to optimize performance
508
- * (Apollon77) Added flag returnNewestEntries for GetHistory to determine which records to return when more entries as "count" are existing for aggregate "none"
509
- * (Apollon77) Flush the buffer for the datapoint which is queried by GetHistory before the query is done, so that all data are in the database
510
- * (Apollon77) make sure id is always returned on GetHistory when addId is set
511
- * (Apollon77) Added aggregate method "percentile" to calculate the percentile (0..100) of the values (requires options.percentile with the percentile level, defaults to 50 if not provided). Basically same as Quantile just different levels are used. Calculation will be done by InfluxDB
512
- * (Apollon77) Added aggregate method "quantile" to calculate the quantile (0..1) of the values (requires options.quantile with the quantile level, defaults to 0.5 if not provided). Basically same as Percentile just different levels are used. Calculation will be done by InfluxDB
513
- * (Apollon77) Added (experimental) method "integral" to calculate the integral of the values. Requires options.integralUnit with the time duration of the integral in seconds, defaults to 60s if not provided. Optionally a linear interpolation can be done by setting options.integralInterpolation to "linear". Calculation will be done byInfluxDB (except for InfluxDB 1 and interpolation "linear", this is done by adapter on raw data)
514
- * (Apollon77) When request contains flag removeBorderValues: true, the result then cut the additional pre and post border values out of the results
515
- * (Apollon77) Enhance the former "Ignore below 0" feature and now allow specifying to ignore below or above specified values. The old setting is converted to the new one
516
- * (Apollon77) Allow to specify custom retention duration in days
517
- * (Apollon77) Added a new message flushBuffer to flush complete buffers or for a given id
518
- * (Apollon77) Allow to specify an additional path for the InfluxDB URL, when Reverse proxies are used or such
519
- * (Apollon77) Make sure that min change delta allows numbers entered with comma (german notation) in all cases
520
- * (Apollon77) Added support to specify how to round numbers on query per datapoint
521
- * (Apollon77) Allow to specify if the last value of a state is logged on startup
522
-
523
- ### 2.6.3 (2022-03-07)
524
- * (Apollon77) Fix potential crash cases (Sentry IOBROKER-INFLUXDB-4Q)
525
-
526
- ### 2.6.2 (2022-03-03)
527
- * (Apollon77) Correctly handle db names with hyphens for InfluxDB 1
528
- * (Apollon77) Fix getHistory for non-boolean fields
529
- * (Apollon77) Adjust shard group duration to influxdb proposals
530
-
531
- ### 2.6.1 (2022-02-28)
532
- * (Excodibur) Address issue with updating retention policy for influxDB 1
533
-
534
- ### 2.6.0 (2022-02-24)
535
- * (Excodibur) Make request timeout configurable - defaults to 30s
536
- * (Apollon77) Added an option to also accept self-signed ssl certificates for InfluxDB 2.x
537
-
538
- ### 2.5.2 (2022-02-22)
539
- * (bluefox) Marked interpolated data with `i=true`
540
-
541
- ### 2.5.0 (2022-02-14)
542
- * (bluefox) Added new messages: 'update', 'delete', 'deleteRange', 'deleteAll' (only for influxdb v1)
543
- * (bluefox) Corrected aggregation of data
544
-
545
- ### 2.4.0 (2021-12-19)
546
- * (Excodibur) Added expert settings to deactivate health checks for Influx 2 db (There are no health checks for Influx 1)
547
- * (Excodibur) Hide settings not relevant when "log changes only" is not used
548
- * (Apollon77) Allow all number values for debounce again
549
- * (Apollon77) InfluxDB also does not like Infinite values, so ignore them too
550
-
551
- ### 2.3.0 (2021-12-14)
552
- * (bluefox) Support only `js.controller` >= 3.3.x
553
- * (bluefox) Used system/custom view for collecting the objects
554
- * (bluefox) Implemented option to ignore zero- or/and below zero- values
555
-
556
- ### 2.2.0 (2021-08-25)
557
- * (Excodibur) Added an option to store metadata (q, ack, from) as tags instead of fields for Influx 2.x - see README!
558
- * (Excodibur) Failure to update/set retention policy will now cause warning instead of error/restart, to support more restrictive DB setups
559
- * (Excodibur/Apollon77) Bug fixes and adjustments
560
-
561
- ### 2.1.1 (2021-08-13)
562
- * IMPORTANT: You need to re-enter the password after installing this version!
563
- * IMPORTANT: The adapter now requires Admin 5.1.15+ and js-controller 3.3+! For other admin or js-controller versions please use the former v1.9.5 of thi adapter.
564
- * (Excodibur) Added InfluxDB 2.0 support
565
- * (Excodibur) Adjust Retention handling on Database level to work for InfluxDB 1.x and 2.x
566
- * (Excodibur) Removed retention options on datapoint level because never worked and also not supported really by InfluxDB anymore
567
-
568
- ### 1.9.5 (2021-04-19)
569
- * (bluefox) Added the support of Admin5
570
-
571
- ### 1.9.4 (2021-01-17)
572
- * (Apollon77) Optimize stop handling
573
-
574
- ### 1.9.3 (2020-11-07)
575
- * (Apollon77) Crash case prevented (Sentry IOBROKER-INFLUXDB-T, IOBROKER-INFLUXDB-Y)
576
-
577
- ### 1.9.2 (2020-08-06)
578
- * (Apollon77) crash prevented (Sentry IOBROKER-INFLUXDB-G)
579
-
580
- ### 1.9.1 (2020-07-22)
581
- * (Apollon77) crash prevented (Sentry IOBROKER-INFLUXDB-E)
582
-
583
- ### 1.9.0 (2020-07-21)
584
- * (Apollon77) Optimize handling in case of write errors and host unavailabilities
585
-
586
- ### 1.8.8 (2020-07-18)
587
- * (Apollon77) Some errors prevented
588
- * (Apollon77) Set timeouts for influxdb connections to make sure connectioens do not run forever
589
-
590
- ### 1.8.7 (2020-05-14)
591
- * (bluefox) added command to read supported features
592
-
593
- ### 1.8.6 (2020-05-11)
594
- * (Apollon77) make sure disabling of data points while starting adapter do not crash adapter (Sentry IOBROKER-INFLUXDB-7)
595
- * (Apollon77) Make sure all start values are processed correctly
596
- * (Apollon77) More checks to make sure to not crash when states are disabled while data are processed (Sentry IOBROKER-INFLUXDB-8)
597
-
598
- ### 1.8.5 (2020-05-08)
599
- * (bluefox) set default history if not yet set
600
-
601
- ### 1.8.4 (2020-05-02)
602
- * (Apollon77) make sure disabling of data points do not crash adapter (Sentry IOBROKER-INFLUXDB-4)
603
-
604
- ### 1.8.3 (2020-04-29)
605
- * (Apollon77) Fix pot crash case when deleting objects while saving values (Sentry)
606
-
607
- ### 1.8.2 (2020-04-19)
608
- * __Requires js-controller >= 2.0.0__
609
- * (Apollon77) removed usage of `adapter.objects`
610
- * (Apollon77) check if objects have changed and ignore unchanged
611
- * (Apollon77) Added Sentry for Error Reporting with js-controller 3.0
612
- * (Apollon77) Make sure value undefined is ignored
613
-
614
- ### 1.4.2 (2017-03-02)
615
- * (Apollon77) Added option to define storage datatype per datapoint inclusing converting the value if needed
616
-
617
- ### 1.3.4 (2017-02-22)
618
- * (Apollon77) Small fix for older configurations
619
-
620
- ### 1.3.3 (2017-02-08)
621
- * (Apollon77) Enhance handling of DB outages with mass writes afterwards
622
- * (Apollon77) Small fix for older configurations
623
-
624
- ### 1.3.2
625
- * (Apollon77) Enhance Min-Delta logic for data points from type mixed
626
-
627
- ### 1.3.1 (2017-01-16)
628
- * (bluefox) Fix handling of float values in Adapter config and Datapoint config.
629
-
630
- ### 1.3.0 (2016-12-02)
631
- * (Apollon77) Added messages enableHistory/disableHistory
632
- * (Apollon77) Added support to log changes only if value differs a minimum value for numbers
633
-
634
- ### 1.2.1 (2016-11)
635
- * (Apollon77) small enhancements and fixes
636
-
637
- ### 1.2.0 (2016-11-05)
638
- * (Apollon77) support re-logging also for states that are not updated often (timed relog using relog-Interval)
639
- * (Apollon77) try to solve easy type conflicts and convert float <--> boolean if needed
640
- * (Apollon77) enhance `getHistory` to retrieve also boundary values better by selecting also points outside of the given time boundaries
641
-
642
- ### 1.1.1 (2016-11-03)
643
- * (Apollon77) small final change on custom dialog
644
-
645
- ### 1.1.0 (2016-10-29)
646
- * (Apollon77) optimizations and enhancements for high-traffic situations
647
- * (Apollon77) Bugfix if InfluxDB is unavailable
648
- * (Apollon77) Added functions getConflictingPoints and resetConflictingPoints
649
- * (Apollon77) Added option to re-log unchanged values to make it easier for visualization
650
-
651
- ### 1.0.1 (2016-10-18)
652
- * (Apollon77) changed storing values to asynchronous way
653
- * (Apollon77) Added support for `minmax` aggregate type on getHistory
654
-
655
- ### 1.0.0 (2016-10-10)
656
- * (Apollon77) bulk write into DB
657
- * (Apollon77) buffer values if no connection to DB
658
- * (bluefox) connection indication
659
-
660
- ### 0.5.3 (2016-09-30)
661
- * (Apollon77) enhance and correct documentation
662
- * (Apollon77) implement "step" calculation for aggregation if only "count" is set
663
-
664
- ### 0.5.2 (2016-09-25)
665
- * (Apollon77) change custom queries. Fix delete DB
666
-
667
- ### 0.5.1 (2016-09-20)
668
- * (Apollon77) Step is given as Milliseconds and not Seconds!
669
-
670
- ### 0.5.0 (2016-08-30)
671
- * (bluefox) Compatible only with new admin
672
-
673
- ### 0.4.0 (2016-08-27)
674
- * (bluefox) change name of object from "history" to "custom"
675
-
676
- ### 0.3.1 (2016-06-07)
677
- * (bluefox) better error handling
678
-
679
- ### 0.3.1 (2016-06-05)
680
- * (bluefox) no support of influxDB 0.8 (please update)
681
-
682
- ### 0.3.0 (2016-05-18)
683
- * (bluefox) make name of DB configurable
684
-
685
- ### 0.2.0 (2016-04-30)
686
- * (bluefox) support of milliseconds instead of seconds
687
-
688
- ### 0.1.2 (2015-12-19)
689
- * (bluefox) make onchange work
690
-
691
- ### 0.1.1 (2015-12-19)
692
- * (bluefox) retention policy for 0.9.x
693
-
694
- ### 0.1.0 (2015-12-19)
695
- * (bluefox) supported InfluxDB version 0.9.x and 0.8.x
696
-
697
- ### 0.0.2 (2015-12-14)
698
- * (bluefox) change supported InfluxDB version to 0.9.x
699
-
700
- ### 0.0.1 (2015-12-12)
701
- * (bluefox) initial commit
492
+ [Older changelogs can be found there](CHANGELOG_OLD.md)
702
493
 
703
494
  ## License
704
495
 
705
496
  The MIT License (MIT)
706
497
 
707
- Copyright (c) 2015-2024 bluefox, apollon77
498
+ Copyright (c) 2015-2026 bluefox, apollon77
708
499
 
709
500
  Permission is hereby granted, free of charge, to any person obtaining a copy
710
501
  of this software and associated documentation files (the "Software"), to deal
@@ -1,48 +1,49 @@
1
1
  # Understanding retention policies
2
2
 
3
- It is important to understand how **Retention Policies** and **Shard Group Durations** are related in order to determine how long data will be kept in InfluxDB.
3
+ It is important to understand how **Retention Policies** and **Shard Group Durations** are related in order to determine how long data
4
+ will be kept in InfluxDB.
4
5
 
5
-
6
6
 
7
- Influx stores all measurements within a given time range into the same **Shard** which itself is part of a **Shard Group**. The Shard Group enforces a time range defined by `Shard Group Duration` to all shards, but it is set differently depending on the Influx release.
7
+ Influx stores all measurements within a given time range into the same **Shard** which itself is part of a **Shard Group**.
8
+ The Shard Group enforces a time range defined by `Shard Group Duration` to all shards, but it is set differently depending on the Influx release.
8
9
 
9
10
  When exceeding the configured `Shard Group Duration`,
10
11
 
11
12
  - a new Shard is created which stores newer measurement data from that point onwards
12
13
  - the old Shard with all its measurement-data is still kept in the database, but will be dropped, once the retention policy for the measurement is exceeded
13
-
14
14
 
15
15
  Measurement data-points are not deleted by Influx via "looking" at their retention policies individually, but instead the Shard as a whole is subject to retention policy check and will be dropped, if the retention policy is exceeded. The check however will only be performed on old Shards, meaning Shards that are still active are not checked, as they also still can receive new measurement data points.
16
16
 
17
- *Please refer to https://docs.influxdata.com/influxdb/v1.4/concepts/schema_and_data_layout/#shard-group-duration-management for more explanation and examples.*
18
-
17
+ *Please refer to https://docs.influxdata.com/influxdb/v1.4/concepts/schema_and_data_layout/#shard-group-duration-management
18
+ for more explanation and examples.*
19
19
 
20
- The following two examples illustrate how the same retention period will be enforced differently, depeding on the configured Shard Group Duration.
20
+ The following two examples illustrate how the same retention period will be enforced differently, depending on the configured Shard Group Duration.
21
21
 
22
- | | Example 1 | Example 2 |
23
- |--|--|--|
24
- | Retention Period | 2 hours | 2 hours |
25
- | Shard Group Duration | 1 hour | 1 day |
26
- | How long will data be kept at max? | 2 hours | 1 day |
27
- | Why? | The Shard is switched every hour, hence Influx will enforce the configured RP once **every hour** and keep only data from the **last 2 hours**. | The Shard is switched once a day, and Influx will then enforce the configured RP, meaning it will only keep data from the last **2 hours**. Because of this, measurement-data inserted at the beginning of the Shard-lifetime in theory should only be kept for 2 hours, but effectively will be kept a **whole day**. |
22
+ | | Example 1 | Example 2 |
23
+ |------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
24
+ | Retention Period | 2 hours | 2 hours |
25
+ | Shard Group Duration | 1 hour | 1 day |
26
+ | How long will data be kept at max? | 2 hours | 1 day |
27
+ | Why? | The Shard is switched every hour, hence Influx will enforce the configured RP once **every hour** and keep only data from the **last 2 hours**. | The Shard is switched once a day, and Influx will then enforce the configured RP, meaning it will only keep data from the last **2 hours**. Because of this, measurement-data inserted at the beginning of the Shard-lifetime in theory should only be kept for 2 hours, but effectively will be kept a **whole day**. |
28
28
 
29
29
  ## iobroker.influxdb Adapter
30
30
  The Influx Adapter only allows you to select a **Retention Period** and itself will automatically choose the **Shard Group Duration** according to [official InfluxDB recommendations](https://docs.influxdata.com/influxdb/v2.0/reference/internals/shards/#shard-group-duration).
31
31
 
32
- | Bucket retention period | Default shard group duration |
33
- |--|--|
34
- | less than 2 days | 1h |
35
- | between 2 days and 6 months | 1d |
36
- | greater than 6 months |7d |
32
+ | Bucket retention period | Default shard group duration |
33
+ |-----------------------------|------------------------------|
34
+ | less than 2 days | 1h |
35
+ | between 2 days and 6 months | 1d |
36
+ | greater than 6 months | 7d |
37
37
 
38
38
 
39
- The Shard Group Duration can still be altered manually in the DB itself, but in order to keep the adapter configuration manageable, it can not be changed directly within ioBroker.
39
+ The Shard Group Duration can still be altered manually in the DB itself, but in order to keep the adapter configuration manageable,
40
+ it can not be changed directly within ioBroker.
40
41
 
41
- By design the adapter enforces only one global retention policy that applies to all measurements - regardless of the DB version that is used. The policy can be changed at any time, but for the reasons described earlier it might take a while for the changes to take effect.
42
+ By design, the adapter enforces only one global retention policy that applies to all measurements - regardless of the DB version that is used. The policy can be changed at any time, but for the reasons described earlier, it might take a while for the changes to take effect.
42
43
 
43
44
  ## Additional considerations
44
45
 
45
46
  - The shard group duration is often configured shorter than the retention period, in order to be enforced effectively. But it is difficult to state this as a general advice, since other factors, like performance should be considered, too. If shard group durations are configured extremely short, this might be beneficial for housekeeping, but it could negatively impact performance, like causing longer query times, or slow write speeds.
46
- - A retention policy may not be lower than 1 hour. This was a choice made by Influx devs (https://github.com/influxdata/influxdb/issues/5198#issuecomment-166629531) and can only be bypassed by building InfluxDB from latest source with changed values directly.
47
- - Retention policies are checked by default every 30 minutes. This can be changed however in [server configuration for Influx 1.x](https://docs.influxdata.com/influxdb/v1.8/administration/config/#retention-policy-settings) and [server configuration for Influx 2.x](https://docs.influxdata.com/influxdb/v2.0/reference/config-options/#storage-retention-check-interval). This does **not** bypass the principles explained earlier.
47
+ - A retention policy may not be lower than 1 hour. This was a choice made by Influx devs (https://github.com/influxdata/influxdb/issues/5198#issuecomment-166629531) and can only be bypassed by building InfluxDB from the latest source with changed values directly.
48
+ - Retention policies are checked by default every 30 minutes. This can be changed, however, in [server configuration for Influx 1.x](https://docs.influxdata.com/influxdb/v1.8/administration/config/#retention-policy-settings) and [server configuration for Influx 2.x](https://docs.influxdata.com/influxdb/v2.0/reference/config-options/#storage-retention-check-interval). This does **not** bypass the principles explained earlier.
48
49
  - **Influx 1.x**: For existing dbs the adapter is able to detect the current default retention policy and will update it. If you modified retention policies manually and now are still experiencing missing data in the adapter, it might be related to the changed default-policy. See also here for more information: https://docs.influxdata.com/influxdb/v1.7/troubleshooting/frequently-asked-questions/#why-am-i-missing-data-after-creating-a-new-default-retention-policy.
@@ -12,9 +12,12 @@
12
12
  "3 months": "3 Monate",
13
13
  "5 days": "5 Tage",
14
14
  "6 months": "6 Monate",
15
+ "Admin security password": "Administrator-Sicherheitskennwort",
15
16
  "Alias Info": "Wenn Alias-ID gesetzt ist, werden die Daten als diese ID in Datendateien protokolliert",
16
17
  "Apply lower retention": "Geringere Vorhaltezeit anwenden",
17
- "Are you sure? All data will be dropped.": "Sollen wirklich alle Daten gelöscht werden? ",
18
+ "Are you sure? All data will be dropped.": "Sollen wirklich alle Daten gelöscht werden?",
19
+ "Auto-installs plugins at startup": "Installiert Plugins automatisch beim Start",
20
+ "Auto-update InfluxDB Docker image": "Automatische Aktualisierung des InfluxDB-Docker-Images",
18
21
  "Automatic": "Automatisch",
19
22
  "Block time": "Blockzeit",
20
23
  "Boolean": "Boolean",
@@ -31,15 +34,22 @@
31
34
  "De-bounce interval(ms)": "Protokolliert den Wert nur, wenn er für X ms unverändert bleibt",
32
35
  "De-bounce time": "Entprellzeit",
33
36
  "Default settings": "Standardeinstellungen",
37
+ "Defines the root URL, useful when Grafana is behind a reverse proxy.": "Definiert die Stamm-URL, nützlich, wenn sich Grafana hinter einem Reverse-Proxy befindet.",
34
38
  "Disable charting optimized logging of skipped values": "Optimierte Protokollierung übersprungener Werte für Diagramme deaktivieren",
35
39
  "Enable enhanced debug logs for the datapoint": "Erweiterte Debug-Protokolle für den Datenpunkt aktivieren",
40
+ "Enable user sign-ups": "Benutzeranmeldungen aktivieren",
36
41
  "Encrypt": "Datenbankverbindung verschlüsseln",
37
42
  "Encrypt:": "Verschlüsseln:",
38
43
  "Enter a number or leave the field empty": "Eine Zahl angeben oder das Feld leer lassen, um die aufgezeichneten Werte nicht einzuschränken",
39
44
  "Expert Settings": "Experteneinstellungen",
45
+ "Grafana Docker": "Grafana Docker",
40
46
  "History adapter settings": "History-Adapter Einstellungen",
41
47
  "Host": "Server",
42
- "Log the last value again on startup": "Protokollieren Sie den letzten Wert erneut beim Start",
48
+ "If enabled, the latest Docker image will be pulled when the adapter starts.": "Wenn aktiviert, wird beim Start des Adapters das neueste Docker-Image abgerufen.",
49
+ "If enabled, the latest InfluxDB Docker image will be pulled when the adapter starts.": "Wenn aktiviert, wird beim Start des Adapters das neueste InfluxDB-Docker-Image abgerufen.",
50
+ "InfluxDB Docker": "InfluxDB Docker",
51
+ "InfluxDB Docker Port": "InfluxDB-Docker-Port",
52
+ "Log the last value again on startup": "Den letzten Wert erneut beim Start protokollieren ",
43
53
  "Lowering the retention period should be considered with caution: Past data exceeding the retention period will be lost.": "Eine Verkürzung der Vorhaltezeit ist mit Vorsicht zu genießen: Vergangene Daten, die die Vorhaltezeit überschreiten, gehen verloren.",
44
54
  "Milliseconds": "Millisekunden",
45
55
  "Number": "Zahl",
@@ -53,24 +63,32 @@
53
63
  "Reject on SSL errors": "Ablehnen bei SSL-Fehlern",
54
64
  "Request timeout": "Request Timeout",
55
65
  "Reset DB": "Alle Daten in Datenbank löschen",
56
- "Round real to": "Runden Sie bei der Abfrage die Zahlen auf",
66
+ "Round real to": "Bei der Abfrage die Zahlen aufrunden",
57
67
  "SQL history adapter settings": "SQL History Adapter Einstellungen",
58
68
  "Save last previous value": "Speichere vorherigen Wert",
59
69
  "Seconds": "Sekunden",
60
70
  "Send health-check pings to database": "Pings zur Verfügbarkeitsprüfung an die Datenbank senden",
71
+ "Start container on IP": "Container auf IP starten",
61
72
  "Start or enable adapter first": "Adapter muss zuerst aktiviert werden",
73
+ "Stop InfluxDB Docker container when instance stops": "Stoppen Sie den InfluxDB-Docker-Container, wenn die Instanz stoppt",
74
+ "Stop container when instance stops": "Container stoppen, wenn Instanz stoppt",
62
75
  "Storage retention": "Aufbewahrungsdauer",
63
76
  "Store as": "Speichern als",
64
77
  "String": "Text",
65
78
  "Test connection": "Verbindung testen",
79
+ "The port on which the InfluxDB Docker container will be reachable on localhost": "Der Port, über den der InfluxDB-Docker-Container auf localhost erreichbar ist",
80
+ "The port on which the container will be reachable on localhost": "Der Port, über den der Container auf localhost erreichbar ist",
66
81
  "This feature can only be used on databases that are empty, or already were setup with this feature enabled. Otherwise it will cause errors (see logs).": "Diese Funktion kann nur für Datenbanken verwendet werden, die leer sind oder bereits mit aktivierter Funktion eingerichtet wurden. Andernfalls kommt es zu Fehlern (siehe Protokolle).",
67
82
  "Token": "Token",
83
+ "Use self-hosted Grafana in Docker": "Selbst gehostetes Grafana in Docker verwenden ",
84
+ "Use self-hosted InfluxDB in Docker": "Selbst gehostetes InfluxDB in Docker verwenden",
68
85
  "Use tags to store metadata information, instead of fields": "Verwende Tags, anstelle von Feldern, um Metadateninformationen zu speichern",
69
86
  "User": "Benutzer",
70
87
  "Validate SSL certificate": "SSL-Zertifikat validieren",
71
88
  "aliasId": "Alias-ID",
72
89
  "blockTime": "Alle neuen Werte für X ms nach dem letzten protokollierten Wert ignorieren",
73
90
  "debounce": "Änderungen ignorieren, bis der Wert für X Millisekunden unverändert bleibt",
91
+ "docker_explanation": "ioBroker startet und verwaltet eine selbst gehostete InfluxDB-Instanz in einem Docker-Container. Diese Option eignet sich für Benutzer, die InfluxDB lokal ausführen möchten, ohne auf einen externen Dienst angewiesen zu sein.",
74
92
  "health-check help": "Regelmäßige Verfügbarkeits-Anfragen werden an den DB-Server gesendet, um zu überprüfen, ob er noch aktiv ist.",
75
93
  "ignore values above x": "Ignoriere Werte größer als",
76
94
  "ignore values below x": "Ignoriere Werte kleiner als",
@@ -86,4 +104,4 @@
86
104
  "retention": "Storage Vorhaltezeit",
87
105
  "use 0 to not buffer at all": "Wert 0 schreibt Werte direkt",
88
106
  "usetags help": "Weitere Informationen sind in der Dokumentation: https://github.com/ioBroker/ioBroker.influxdb/blob/master/README.md#Store-metadata-information-as-tags-instead-of-fields zu finden."
89
- }
107
+ }
@@ -12,9 +12,12 @@
12
12
  "3 months": "3 months",
13
13
  "5 days": "5 days",
14
14
  "6 months": "6 months",
15
+ "Admin security password": "Admin security password",
15
16
  "Alias Info": "if Alias-ID is set, the data will be logged as this ID in database",
16
17
  "Apply lower retention": "Apply lower retention",
17
- "Are you sure? All data will be dropped.": "All data will be dropped. Are you sure? ",
18
+ "Are you sure? All data will be dropped.": "All data will be dropped. Are you sure?",
19
+ "Auto-installs plugins at startup": "Auto-installs plugins at startup",
20
+ "Auto-update InfluxDB Docker image": "Auto-update InfluxDB Docker image",
18
21
  "Automatic": "Automatic",
19
22
  "Block time": "Blocktime",
20
23
  "Boolean": "Boolean",
@@ -31,14 +34,21 @@
31
34
  "De-bounce interval(ms)": "Only logs the value if it stays unchanged for X ms",
32
35
  "De-bounce time": "Debounce Time",
33
36
  "Default settings": "Default settings",
37
+ "Defines the root URL, useful when Grafana is behind a reverse proxy.": "Defines the root URL, useful when Grafana is behind a reverse proxy.",
34
38
  "Disable charting optimized logging of skipped values": "Disable charting optimized logging of skipped values",
35
39
  "Enable enhanced debug logs for the datapoint": "Enable enhanced debug logs for the state",
40
+ "Enable user sign-ups": "Enable user sign-ups",
36
41
  "Encrypt": "Encrypt Database connection",
37
- "Encrypt:": "",
42
+ "Encrypt:": "Encrypt:",
38
43
  "Enter a number or leave the field empty": "Enter a number or leave the field empty to not limit the recorded values",
39
44
  "Expert Settings": "Expert Settings",
45
+ "Grafana Docker": "Grafana Docker",
40
46
  "History adapter settings": "History adapter settings",
41
47
  "Host": "Host",
48
+ "If enabled, the latest Docker image will be pulled when the adapter starts.": "If enabled, the latest Docker image will be pulled when the adapter starts.",
49
+ "If enabled, the latest InfluxDB Docker image will be pulled when the adapter starts.": "If enabled, the latest InfluxDB Docker image will be pulled when the adapter starts.",
50
+ "InfluxDB Docker": "InfluxDB Docker",
51
+ "InfluxDB Docker Port": "InfluxDB Docker Port",
42
52
  "Log the last value again on startup": "Log the last value again on startup",
43
53
  "Lowering the retention period should be considered with caution: Past data exceeding the retention period will be lost.": "Lowering the retention period should be considered with caution: Past data exceeding the retention period will be lost.",
44
54
  "Milliseconds": "Milliseconds",
@@ -58,19 +68,27 @@
58
68
  "Save last previous value": "Save last previous value",
59
69
  "Seconds": "Seconds",
60
70
  "Send health-check pings to database": "Send health-check pings to database",
71
+ "Start container on IP": "Start container on IP",
61
72
  "Start or enable adapter first": "Start or enable adapter first",
73
+ "Stop InfluxDB Docker container when instance stops": "Stop InfluxDB Docker container when instance stops",
74
+ "Stop container when instance stops": "Stop container when instance stops",
62
75
  "Storage retention": "Storage retention",
63
76
  "Store as": "Store as",
64
77
  "String": "String",
65
78
  "Test connection": "Test connection",
79
+ "The port on which the InfluxDB Docker container will be reachable on localhost": "The port on which the InfluxDB Docker container will be reachable on localhost",
80
+ "The port on which the container will be reachable on localhost": "The port on which the container will be reachable on localhost",
66
81
  "This feature can only be used on databases that are empty, or already were setup with this feature enabled. Otherwise it will cause errors (see logs).": "This feature can only be used on databases that are empty, or already were setup with this feature enabled. Otherwise it will cause errors (see logs).",
67
82
  "Token": "Token",
83
+ "Use self-hosted Grafana in Docker": "Use self-hosted Grafana in Docker",
84
+ "Use self-hosted InfluxDB in Docker": "Use self-hosted InfluxDB in Docker",
68
85
  "Use tags to store metadata information, instead of fields": "Use tags to store metadata information, instead of fields",
69
86
  "User": "User",
70
87
  "Validate SSL certificate": "Validate SSL certificate",
71
88
  "aliasId": "Alias-ID",
72
89
  "blockTime": "Ignore all new values for X ms after last logged value",
73
90
  "debounce": "Ignore changes till value stays unchanged for X Milliseconds",
91
+ "docker_explanation": "ioBroker will start and manage a self-hosted InfluxDB instance within a Docker container. This option is suitable for users who prefer to have InfluxDB running locally without relying on an external service.",
74
92
  "health-check help": "Regular health checks probes are sent to the DB server to check if it is still alive.",
75
93
  "ignore values above x": "Ignore values above",
76
94
  "ignore values below x": "Ignore values below",
@@ -86,4 +104,4 @@
86
104
  "retention": "Storage retention",
87
105
  "use 0 to not buffer at all": "Use 0 to not buffer at all",
88
106
  "usetags help": "For more information, please refer to the documentation: https://github.com/ioBroker/ioBroker.influxdb/blob/master/README.md#Store-metadata-information-as-tags-instead-of-fields"
89
- }
107
+ }
@@ -12,9 +12,12 @@
12
12
  "3 months": "3 meses",
13
13
  "5 days": "5 dias",
14
14
  "6 months": "6 meses",
15
+ "Admin security password": "Contraseña de seguridad del administrador",
15
16
  "Alias Info": "si se establece Alias-ID, los datos se registrarán como este ID en la base de datos",
16
17
  "Apply lower retention": "Aplicar menor retención",
17
18
  "Are you sure? All data will be dropped.": "¿Estás seguro? Todos los datos serán eliminados.",
19
+ "Auto-installs plugins at startup": "Instala automáticamente complementos al inicio",
20
+ "Auto-update InfluxDB Docker image": "Actualización automática de la imagen de Docker de InfluxDB",
18
21
  "Automatic": "Automático",
19
22
  "Block time": "hora de bloque",
20
23
  "Boolean": "booleano",
@@ -31,14 +34,21 @@
31
34
  "De-bounce interval(ms)": "Solo registra el valor si permanece sin cambios durante X ms",
32
35
  "De-bounce time": "Tiempo de rebote",
33
36
  "Default settings": "Configuración por defecto",
37
+ "Defines the root URL, useful when Grafana is behind a reverse proxy.": "Define la URL raíz, útil cuando Grafana está detrás de un proxy inverso.",
34
38
  "Disable charting optimized logging of skipped values": "Deshabilitar el registro optimizado de gráficos de valores omitidos",
35
39
  "Enable enhanced debug logs for the datapoint": "Habilitar registros de depuración mejorados para el punto de datos",
40
+ "Enable user sign-ups": "Habilitar registros de usuarios",
36
41
  "Encrypt": "Cifrar la conexión de la base de datos",
37
42
  "Encrypt:": "Encriptar:",
38
43
  "Enter a number or leave the field empty": "Ingrese un número o deje el campo vacío para no limitar los valores registrados",
39
44
  "Expert Settings": "Configuración experta",
45
+ "Grafana Docker": "Grafana Docker",
40
46
  "History adapter settings": "Configuración del adaptador de historial",
41
47
  "Host": "Anfitrión",
48
+ "If enabled, the latest Docker image will be pulled when the adapter starts.": "Si está habilitado, se extraerá la última imagen de Docker cuando se inicie el adaptador.",
49
+ "If enabled, the latest InfluxDB Docker image will be pulled when the adapter starts.": "Si está habilitado, se extraerá la última imagen de Docker de InfluxDB cuando se inicie el adaptador.",
50
+ "InfluxDB Docker": "Docker de InfluxDB",
51
+ "InfluxDB Docker Port": "Puerto Docker de InfluxDB",
42
52
  "Log the last value again on startup": "Registre el último valor nuevamente al inicio",
43
53
  "Lowering the retention period should be considered with caution: Past data exceeding the retention period will be lost.": "Reducir el período de retención debe considerarse con precaución: los datos anteriores que excedan el período de retención se perderán.",
44
54
  "Milliseconds": "milisegundos",
@@ -58,19 +68,27 @@
58
68
  "Save last previous value": "Guarde el último valor anterior",
59
69
  "Seconds": "Segundos",
60
70
  "Send health-check pings to database": "Enviar pings de verificación de estado a la base de datos",
71
+ "Start container on IP": "Iniciar contenedor en IP",
61
72
  "Start or enable adapter first": "Comience o habilite el adaptador primero",
73
+ "Stop InfluxDB Docker container when instance stops": "Detener el contenedor Docker de InfluxDB cuando la instancia se detiene",
74
+ "Stop container when instance stops": "Detener el contenedor cuando la instancia se detiene",
62
75
  "Storage retention": "retención de almacenamiento",
63
76
  "Store as": "Guardar como",
64
77
  "String": "Cuerda",
65
78
  "Test connection": "Conexión de prueba",
79
+ "The port on which the InfluxDB Docker container will be reachable on localhost": "El puerto en el que se podrá acceder al contenedor Docker de InfluxDB en el host local",
80
+ "The port on which the container will be reachable on localhost": "El puerto en el que se podrá acceder al contenedor en localhost",
66
81
  "This feature can only be used on databases that are empty, or already were setup with this feature enabled. Otherwise it will cause errors (see logs).": "Esta función solo se puede utilizar en bases de datos que estén vacías o que ya se hayan configurado con esta función habilitada. De lo contrario, provocará errores (consulte los registros).",
67
82
  "Token": "Simbólico",
83
+ "Use self-hosted Grafana in Docker": "Utilice Grafana autoalojado en Docker",
84
+ "Use self-hosted InfluxDB in Docker": "Utilice InfluxDB autohospedado en Docker",
68
85
  "Use tags to store metadata information, instead of fields": "Utilice etiquetas para almacenar información de metadatos, en lugar de campos",
69
86
  "User": "Usuario",
70
87
  "Validate SSL certificate": "Validar certificado SSL",
71
88
  "aliasId": "ID de alias",
72
89
  "blockTime": "Ignorar todos los valores nuevos para X ms después del último valor registrado",
73
90
  "debounce": "Ignorar cambios hasta que el valor permanezca sin cambios durante X milisegundos",
91
+ "docker_explanation": "ioBroker iniciará y administrará una instancia de InfluxDB autoalojada dentro de un contenedor Docker. Esta opción es ideal para usuarios que prefieren tener InfluxDB ejecutándose localmente sin depender de un servicio externo.",
74
92
  "health-check help": "Se envían sondas de verificación de estado regulares al servidor de base de datos para verificar si todavía está vivo.",
75
93
  "ignore values above x": "Ignorar los valores anteriores",
76
94
  "ignore values below x": "Ignorar valores a continuación",
@@ -86,4 +104,4 @@
86
104
  "retention": "Retención de almacenamiento",
87
105
  "use 0 to not buffer at all": "Use 0 para no almacenar el búfer en absoluto",
88
106
  "usetags help": "Para obtener más información, consulte la documentación: https://github.com/ioBroker/ioBroker.influxdb/blob/master/README.md#Store-metadata-information-as-tags-instead-of-fields"
89
- }
107
+ }