iobroker.influxdb 4.0.2 → 5.0.2

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 (67) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +39 -245
  3. package/RetentionPolicies.md +23 -22
  4. package/admin/custom/assets/Components-B31xFgHA.js +1 -0
  5. package/admin/custom/assets/DataBrowser-BjC3hA47.js +1 -0
  6. package/admin/custom/assets/_virtual_mf-localSharedImportMap___mfe_internal__InfluxDBComponentsSet__mf_owner__1-B9Ylge1m.js +1 -0
  7. package/admin/custom/assets/_virtual_mf___mfe_internal__InfluxDBComponentsSet__mf_owner__1__loadShare___mf_0_iobroker_mf_1_gui_mf_2_components__loadShare__.js-B1eVfdnr.js +1243 -0
  8. package/admin/custom/assets/_virtual_mf___mfe_internal__InfluxDBComponentsSet__mf_owner__1__loadShare___mf_0_iobroker_mf_1_json_mf_2_config__loadShare__.js-CxiY1CI5.js +1494 -0
  9. package/admin/custom/assets/_virtual_mf___mfe_internal__InfluxDBComponentsSet__mf_owner__1__loadShare__react_mf_2_dom_mf_1_client__loadShare__.js-DySAygl2.js +9 -0
  10. package/admin/custom/assets/hostInit-6uyyXgUg.js +1 -0
  11. package/admin/custom/assets/index-Bqsp0Vtz.js +1 -0
  12. package/admin/custom/assets/lib-BQ9Iy9vH.js +3 -0
  13. package/admin/custom/assets/mf-entry-bootstrap-0-1d56ce7a.js +41 -0
  14. package/admin/custom/assets/rolldown-runtime-C0FnF6B9.js +1 -0
  15. package/admin/custom/assets/virtualExposes-BDloXo0b.js +1 -0
  16. package/admin/custom/assets/virtual_mf-REMOTE_ENTRY_ID___mfe_internal__InfluxDBComponentsSet__customComponents_js-C-UWbkzd.js +1 -0
  17. package/admin/custom/assets/virtual_mf-exposes___mfe_internal__InfluxDBComponentsSet__customComponents_js-DCQ_KAEk.js +2 -0
  18. package/admin/custom/assets/vite-preload-helper-B7qeedMF.js +1 -0
  19. package/admin/custom/customComponents.js +12 -0
  20. package/admin/custom/i18n/de.json +30 -0
  21. package/admin/custom/i18n/en.json +30 -0
  22. package/admin/custom/i18n/es.json +30 -0
  23. package/admin/custom/i18n/fr.json +30 -0
  24. package/admin/custom/i18n/it.json +30 -0
  25. package/admin/custom/i18n/nl.json +30 -0
  26. package/admin/custom/i18n/pl.json +30 -0
  27. package/admin/custom/i18n/pt.json +30 -0
  28. package/admin/custom/i18n/ru.json +30 -0
  29. package/admin/custom/i18n/uk.json +30 -0
  30. package/admin/custom/i18n/zh-cn.json +30 -0
  31. package/admin/custom/mf-manifest.json +1 -0
  32. package/admin/i18n/{de/translations.json → de.json} +23 -4
  33. package/admin/i18n/{en/translations.json → en.json} +22 -3
  34. package/admin/i18n/{es/translations.json → es.json} +20 -1
  35. package/admin/i18n/fr.json +108 -0
  36. package/admin/i18n/it.json +108 -0
  37. package/admin/i18n/{nl/translations.json → nl.json} +19 -0
  38. package/admin/i18n/pl.json +108 -0
  39. package/admin/i18n/pt.json +108 -0
  40. package/admin/i18n/ru.json +108 -0
  41. package/admin/i18n/uk.json +108 -0
  42. package/admin/i18n/zh-cn.json +108 -0
  43. package/admin/jsonConfig.json +488 -359
  44. package/admin/jsonCustom.json +1 -1
  45. package/admin/words.js +87 -87
  46. package/build/lib/Database.js +76 -0
  47. package/build/lib/Database.js.map +1 -0
  48. package/build/lib/DatabaseInfluxDB1x.js +194 -0
  49. package/build/lib/DatabaseInfluxDB1x.js.map +1 -0
  50. package/build/lib/DatabaseInfluxDB2x.js +252 -0
  51. package/build/lib/DatabaseInfluxDB2x.js.map +1 -0
  52. package/build/main.js +3219 -0
  53. package/build/main.js.map +1 -0
  54. package/docker-compose.yaml +63 -0
  55. package/io-package.json +90 -54
  56. package/package.json +31 -19
  57. package/admin/i18n/fr/translations.json +0 -89
  58. package/admin/i18n/it/translations.json +0 -89
  59. package/admin/i18n/pl/translations.json +0 -89
  60. package/admin/i18n/pt/translations.json +0 -89
  61. package/admin/i18n/ru/translations.json +0 -89
  62. package/admin/i18n/zh-cn/translations.json +0 -89
  63. package/lib/Database.js +0 -30
  64. package/lib/DatabaseInfluxDB1x.js +0 -136
  65. package/lib/DatabaseInfluxDB2x.js +0 -370
  66. package/lib/aggregate.js +0 -1000
  67. package/main.js +0 -2787
@@ -1,371 +1,500 @@
1
1
  {
2
- "type": "tabs",
3
- "i18n": true,
4
- "items": {
5
- "dbTab": {
6
- "type": "panel",
7
- "label": "DB settings",
8
- "items": {
9
- "dbversion": {
10
- "type": "select",
11
- "label": "DB-Version",
12
- "noTranslation": true,
13
- "default": "1.x",
14
- "options": [
15
- {"label": "1.x", "value": "1.x"},
16
- {"label": "2.x", "value": "2.x"}
17
- ],
18
- "sm": 12,
19
- "md": 8
20
- },
21
- "protocol": {
22
- "newLine": true,
23
- "type": "select",
24
- "noTranslation": true,
25
- "options": [
26
- {"label": "http", "value": "http"},
27
- {"label": "https", "value": "https"}
28
- ],
29
- "label": "Protocol",
30
- "sm": 12,
31
- "md": 2
32
- },
33
- "host": {
34
- "type": "text",
35
- "label": "Host",
36
- "sm": 12,
37
- "md": 8
38
- },
39
- "port": {
40
- "type": "number",
41
- "label": "Port",
42
- "min": 1,
43
- "max": 65565,
44
- "sm": 12,
45
- "md": 2
46
- },
47
- "path": {
48
- "type": "text",
49
- "label": "Path",
50
- "help": "only enter when e.g. a reverse proxy is used",
51
- "hidden": "data.dbversion === '1.x'",
52
- "disabled": "data.dbversion === '1.x'",
53
- "sm": 12,
54
- "md": 4
55
- },
56
- "user": {
57
- "newLine": true,
58
- "type": "text",
59
- "label": "User",
60
- "hidden": "data.dbversion === '2.x'",
61
- "disabled": "data.dbversion === '2.x'",
62
- "sm": 12,
63
- "md": 4
64
- },
65
- "password": {
66
- "type": "password",
67
- "label": "Password",
68
- "hidden": "data.dbversion === '2.x'",
69
- "disabled": "data.dbversion === '2.x'",
70
- "repeat": true,
71
- "sm": 12,
72
- "md": 8
73
- },
74
- "organization": {
75
- "newLine": true,
76
- "type": "text",
77
- "label": "Organization",
78
- "hidden": "data.dbversion === '1.x'",
79
- "disabled": "data.dbversion === '1.x'",
80
- "sm": 12,
81
- "md": 4
82
- },
83
- "token": {
84
- "type": "text",
85
- "label": "Token",
86
- "hidden": "data.dbversion === '1.x'",
87
- "disabled": "data.dbversion === '1.x'",
88
- "sm": 12,
89
- "md": 8
90
- },
91
- "dbname": {
92
- "newLine": true,
93
- "type": "text",
94
- "label": "DB Name",
95
- "sm": 12,
96
- "md": 8
97
- },
98
- "requestTimeout": {
99
- "newLine": true,
100
- "type": "number",
101
- "label": "Request timeout",
102
- "help": "Milliseconds",
103
- "sm": 12,
104
- "md": 2
105
- },
106
- "validateSSL": {
107
- "newLine": false,
108
- "type": "checkbox",
109
- "label": "Validate SSL certificate",
110
- "hidden": "data.dbversion === '1.x'",
111
- "disabled": "data.dbversion === '1.x'",
112
- "sm": 12,
113
- "md": 4
114
- },
115
- "round": {
116
- "newLine": true,
117
- "type": "number",
118
- "label": "Round real to",
119
- "sm": 12,
120
- "md": 4
121
- },
122
- "relogLastValueOnStart": {
123
- "type": "checkbox",
124
- "label": "Log the last value again on startup",
125
- "sm": 12,
126
- "md": 4
127
- },
128
- "seriesBufferMax": {
129
- "newLine": true,
130
- "type": "number",
131
- "label": "Buffer Datapoints",
132
- "help": "use 0 to not buffer at all",
133
- "sm": 12,
134
- "md": 4
135
- },
136
- "seriesBufferFlushInterval": {
137
- "type": "number",
138
- "label": "Buffer Flush Interval",
139
- "help": "Seconds",
140
- "sm": 12,
141
- "md": 4,
142
- "lg": 3
143
- },
2
+ "type": "tabs",
3
+ "i18n": true,
4
+ "items": {
5
+ "dbTab": {
6
+ "type": "panel",
7
+ "label": "DB settings",
8
+ "items": {
9
+ "dockerInflux.enabled": {
10
+ "newLine": true,
11
+ "type": "checkDocker",
12
+ "label": "Use self-hosted InfluxDB in Docker",
13
+ "help": "docker_explanation",
14
+ "xs": 12
15
+ },
16
+ "dockerGrafana.enabled": {
17
+ "newLine": true,
18
+ "type": "checkDocker",
19
+ "hideVersion": true,
20
+ "hidden": "!data.dockerInflux?.enabled",
21
+ "label": "Use self-hosted Grafana in Docker",
22
+ "xs": 12
23
+ },
24
+ "dbversion": {
25
+ "newLine": true,
26
+ "type": "select",
27
+ "label": "DB-Version",
28
+ "noTranslation": true,
29
+ "default": "1.x",
30
+ "options": [
31
+ { "label": "1.x", "value": "1.x" },
32
+ { "label": "2.x", "value": "2.x" }
33
+ ],
34
+ "hidden": "!!data.dockerInflux?.enabled",
35
+ "sm": 12,
36
+ "md": 8
37
+ },
38
+ "protocol": {
39
+ "newLine": true,
40
+ "type": "select",
41
+ "noTranslation": true,
42
+ "options": [
43
+ { "label": "http", "value": "http" },
44
+ { "label": "https", "value": "https" }
45
+ ],
46
+ "hidden": "!!data.dockerInflux?.enabled",
47
+ "label": "Protocol",
48
+ "sm": 12,
49
+ "md": 2
50
+ },
51
+ "host": {
52
+ "type": "text",
53
+ "hidden": "!!data.dockerInflux?.enabled",
54
+ "label": "Host",
55
+ "sm": 12,
56
+ "md": 8
57
+ },
58
+ "port": {
59
+ "type": "number",
60
+ "label": "Port",
61
+ "hidden": "!!data.dockerInflux?.enabled",
62
+ "min": 1,
63
+ "max": 65565,
64
+ "sm": 12,
65
+ "md": 2
66
+ },
67
+ "path": {
68
+ "type": "text",
69
+ "label": "Path",
70
+ "help": "only enter when e.g. a reverse proxy is used",
71
+ "hidden": "data.dbversion === '1.x' || !!data.dockerInflux?.enabled",
72
+ "sm": 12,
73
+ "md": 4
74
+ },
75
+ "user": {
76
+ "newLine": true,
77
+ "type": "text",
78
+ "label": "User",
79
+ "hidden": "data.dbversion === '2.x' || !!data.dockerInflux?.enabled",
80
+ "sm": 12,
81
+ "md": 4
82
+ },
83
+ "password": {
84
+ "type": "password",
85
+ "label": "Password",
86
+ "hidden": "data.dbversion === '2.x' || !!data.dockerInflux?.enabled",
87
+ "repeat": true,
88
+ "sm": 12,
89
+ "md": 8
90
+ },
91
+ "organization": {
92
+ "newLine": true,
93
+ "type": "text",
94
+ "label": "Organization",
95
+ "hidden": "data.dbversion === '1.x' || !!data.dockerInflux?.enabled",
96
+ "sm": 12,
97
+ "md": 4
98
+ },
99
+ "token": {
100
+ "type": "text",
101
+ "label": "Token",
102
+ "hidden": "data.dbversion === '1.x'",
103
+ "sm": 12,
104
+ "md": 8
105
+ },
106
+ "dbname": {
107
+ "newLine": true,
108
+ "type": "text",
109
+ "label": "DB Name",
110
+ "hidden": "!!data.dockerInflux?.enabled",
111
+ "sm": 12,
112
+ "md": 8
113
+ },
114
+ "requestTimeout": {
115
+ "newLine": true,
116
+ "type": "number",
117
+ "label": "Request timeout",
118
+ "help": "Milliseconds",
119
+ "sm": 12,
120
+ "md": 2
121
+ },
122
+ "validateSSL": {
123
+ "newLine": false,
124
+ "type": "checkbox",
125
+ "label": "Validate SSL certificate",
126
+ "hidden": "data.dbversion === '1.x' || !!data.dockerInflux?.enabled",
127
+ "sm": 12,
128
+ "md": 4
129
+ },
130
+ "round": {
131
+ "newLine": true,
132
+ "type": "number",
133
+ "label": "Round real to",
134
+ "sm": 12,
135
+ "md": 4
136
+ },
137
+ "relogLastValueOnStart": {
138
+ "type": "checkbox",
139
+ "label": "Log the last value again on startup",
140
+ "sm": 12,
141
+ "md": 4
142
+ },
143
+ "seriesBufferMax": {
144
+ "newLine": true,
145
+ "type": "number",
146
+ "label": "Buffer Datapoints",
147
+ "help": "use 0 to not buffer at all",
148
+ "sm": 12,
149
+ "md": 4
150
+ },
151
+ "seriesBufferFlushInterval": {
152
+ "type": "number",
153
+ "label": "Buffer Flush Interval",
154
+ "help": "Seconds",
155
+ "sm": 12,
156
+ "md": 4,
157
+ "lg": 3
158
+ },
144
159
 
145
- "_testConnection": {
146
- "newLine": true,
147
- "variant": "contained",
148
- "color": "primary",
149
- "disabled": "!_alive",
150
- "type": "sendTo",
151
- "error": {
152
- "connect timeout": "Connection timeout"
153
- },
154
- "icon": "data:image/svg+xml;base64,PHN2ZyBoZWlnaHQ9IjUxMiIgdml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4wMzkuMDEyLS4wNTlhNiA2IDAgMSAxIDUuODIzIDcuNDMyeiIvPg0KICAgIDxwYXRoIGZpbGw9ImN1cnJlbnRDb2xvciIgZD0ibTE5LjYzOSAyMS45YTEgMSAwIDAgMCAxLjQxOCAxLjQxMSAyLjYyOCAyLjYyOCAwIDAgMSAzLjcyNSAwIDEgMSAwIDAgMCAxLjQxOC0xLjQxMSA0LjYyOCA0LjYyOCAwIDAgMCAtNi41NjEgMHoiLz4NCiAgICA8ZWxsaXBzZSBmaWxsPSJjdXJyZW50Q29sb3IiIGN4PSIyMi45ODUiIGN5PSIyNC44NDMiIHJ4PSIxLjY2NyIgcnk9IjEuNjc0Ii8+DQogICAgPHBhdGggZmlsbD0iY3VycmVudENvbG9yIiBkPSJtMjcuOTc5IDE5Ljc2OGE3LjA0NSA3LjA0NSAwIDAgMCAtOS45ODggMCAxIDEgMCAxIDAgMS40MTcgMS40MTIgNS4wNDUgNS4wNDUgMCAwIDEgNy4xNTQgMCAxIDEgMCAxIDAgMS40MTctMS40MTJ6Ii8+DQo8L3N2Zz4=",
155
- "command": "test",
156
- "jsonData": "{\"config\": {\"dbversion\": \"${data.dbversion}\", \"protocol\": \"${data.protocol}\", \"port\": \"${data.port}\", \"host\": \"${data.host}\", \"user\": \"${data.user}\", \"organization\": \"${data.organization}\", \"dbname\": \"${data.dbname}\", \"requestTimeout\": \"${data.requestTimeout}\", \"validateSSL\": ${data.validateSSL}, \"password\": \"${encodeURIComponent(data.password || '')}\", \"token\": \"${data.token}\", \"path\": \"${data.path}\"}}",
157
- "label": "Test connection"
158
- },
160
+ "_testConnection": {
161
+ "newLine": true,
162
+ "variant": "contained",
163
+ "color": "primary",
164
+ "disabled": "!_alive",
165
+ "type": "sendTo",
166
+ "error": {
167
+ "connect timeout": "Connection timeout"
168
+ },
169
+ "icon": "data:image/svg+xml;base64,PHN2ZyBoZWlnaHQ9IjUxMiIgdmlld0JveD0iMCAwIDMyIDMyIiB3aWR0aD0iNTEyIiB4b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uNDMyeiIvPg0KICAgIDxwYXRoIGZpbGw9ImN1cnJlbnRDb2xvciIgZD0ibTE5LjYzOSAyMS45YTEgMSAwIDAgMCAxLjQxOCAxLjQxMSAyLjYyOCAyLjYyOCAwIDAgMSAzLjcyNSAwIDEgMSAwIDAgMCAxLjQxOC0xLjQxMSA0LjYyOCA0LjYyOCAwIDAgMCAtNi41NjEgMHoiLz4NCiAgICA8ZWxsaXBzZSBmaWxsPSJjdXJyZW50Q29sb3IiIGN4PSIyMi45ODUiIGN5PSIyNC44NDMiIHJ4PSIxLjY2NyIgcnk9IjEuNjc0Ii8+DQogICAgPHBhdGggZmlsbD0iY3VycmVudENvbG9yIiBkPSJtMjcuOTc5IDE5Ljc2OGE3LjA0NSA3LjA0NSAwIDAgMCAtOS45ODggMCAxIDEgMCAxIDAgMS40MTcgMS40MTIgNS4wNDUgNS4wNDUgMCAwIDEgNy4xNTQgMCAxIDEgMCAxIDAgMS40MTctMS40MTJ6Ii8+DQo8L3N2Zz4=",
170
+ "command": "test",
171
+ "jsonData": "{\"config\": {\"dockerInflux\": {\"enabled\": ${!!data.dockerInflux?.enabled}, \"port\": ${data.dockerInflux?.port || 8086}}, \"dbversion\": \"${data.dbversion}\", \"protocol\": \"${data.protocol}\", \"port\": \"${data.port}\", \"host\": \"${data.host}\", \"user\": \"${data.user}\", \"organization\": \"${data.organization}\", \"dbname\": \"${data.dbname}\", \"requestTimeout\": \"${data.requestTimeout}\", \"validateSSL\": ${data.validateSSL}, \"password\": \"${encodeURIComponent(data.password || '')}\", \"token\": \"${data.token}\", \"path\": \"${data.path}\"}}",
172
+ "label": "Test connection"
173
+ },
159
174
 
160
- "_resetDB": {
161
- "type": "sendTo",
162
- "variant": "outlined",
163
- "color": "primary",
164
- "icon": "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBmaWxsPSIjODAxMTExIiBkPSJNNiAxOWMwIDEuMS45IDIgMiAyaDhjMS4xIDAgMi0uOSAyLTJWN0g2djEyek0xOSA0aC0zLjVsLTEtMWgtNWwtMSAxSDV2MmgxNFY0eiIvPjwvc3ZnPgkJCQkJCQkJ",
165
- "disabled": "!_alive",
166
- "result": {
167
- "deleted": "Deleted! Restarting..."
168
- },
169
- "confirm": {
170
- "text": "Are you sure? All data will be dropped.",
171
- "title": "Please confirm",
172
- "ok": "Delete",
173
- "cancel": "Cancel"
174
- },
175
- "command": "destroy",
176
- "label": "Reset DB"
177
- }
178
- }
179
- },
180
- "defaultTab": {
181
- "type": "panel",
182
- "label": "Default settings",
183
- "items": {
184
- "debounceTime": {
185
- "newLine": true,
186
- "type": "number",
187
- "sm": 12,
188
- "md": 4,
189
- "min": 0,
190
- "max": 86400000,
191
- "label": "De-bounce time",
192
- "help": "De-bounce interval(ms)"
193
- },
194
- "blockTime": {
195
- "type": "number",
196
- "sm": 12,
197
- "md": 4,
198
- "min": 0,
199
- "max": 86400000,
200
- "label": "Block time",
201
- "defaultFunc": "(data.debounce || data.debounce === '0' || data.debounce === 0) ? parseInt(data.debounce, 10) : 0",
202
- "help": "blockTime"
203
- },
204
- "changesRelogInterval": {
205
- "newLine": true,
206
- "type": "number",
207
- "label": "log changes interval(s)",
208
- "help": "0 = disable",
209
- "sm": 12,
210
- "md": 6,
211
- "lg": 4
212
- },
213
- "changesMinDelta": {
214
- "type": "number",
215
- "label": "log changes minimal delta",
216
- "help": "0 = disable delta check",
217
- "sm": 12,
218
- "md": 6,
219
- "lg": 4
220
- },
221
- "retention": {
222
- "newLine": true,
223
- "type": "select",
224
- "label": "retention",
225
- "options": [
226
- {
227
- "value": 0,
228
- "label": "keep forever"
229
- },
230
- {
231
- "value": 63072000,
232
- "label": "2 years"
233
- },
234
- {
235
- "value": 31536000,
236
- "label": "1 year"
237
- },
238
- {
239
- "value": 15811200,
240
- "label": "6 months"
241
- },
242
- {
243
- "value": 7948800,
244
- "label": "3 months"
245
- },
246
- {
247
- "value": 2678400,
248
- "label": "1 months"
249
- },
250
- {
251
- "value": 1209600,
252
- "label": "2 weeks"
253
- },
254
- {
255
- "value": 604800,
256
- "label": "1 week"
257
- },
258
- {
259
- "value": 432000,
260
- "label": "5 days"
261
- },
262
- {
263
- "value": 259200,
264
- "label": "3 days"
265
- },
266
- {
267
- "value": 86400,
268
- "label": "1 day"
269
- },
270
- {
271
- "value": -1,
272
- "label": "Custom timeframe"
175
+ "_resetDB": {
176
+ "type": "sendTo",
177
+ "variant": "outlined",
178
+ "color": "primary",
179
+ "icon": "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBmaWxsPSIjODAxMTExIiBkPSJNNiAxOWMwIDEuMS45IDIgMiAyaDhjMS4xIDAgMi0uOSAyLTJWN0g2djEyek0xOSA0aC0zLjVsLTEtMWgtNWwtMSAxSDV2MmgxNFY0eiIvPjwvc3ZnPgkJCQkJCQkJ",
180
+ "disabled": "!_alive",
181
+ "result": {
182
+ "deleted": "Deleted! Restarting..."
183
+ },
184
+ "confirm": {
185
+ "text": "Are you sure? All data will be dropped.",
186
+ "title": "Please confirm",
187
+ "ok": "Delete",
188
+ "cancel": "Cancel"
189
+ },
190
+ "command": "destroy",
191
+ "label": "Reset DB"
192
+ }
273
193
  }
274
- ],
275
- "sm": 12,
276
- "md": 6
277
194
  },
278
- "customRetentionDuration": {
279
- "type": "number",
280
- "label": "Custom retention duration (days)",
281
- "min": 1,
282
- "sm": 12,
283
- "md": 4,
284
- "hidden": "(data.retention !== -1)",
285
- "help": "Number of days to keep the data."
286
- },
287
- "retentionConfirm": {
288
- "newLine": true,
289
- "type": "checkbox",
290
- "label": "Apply lower retention",
291
- "hidden": "((originalData.retention >= 0 && data.retention >= 0 && ((data.retention >= originalData.retention && originalData.retention != 0) || data.retention == 0)) || (originalData.retention === -1 && data.retention >= 0 && ((data.retention >= parseInt(originalData.customRetentionDuration, 10) * 24 * 60) || data.retention == 0)) || (originalData.retention > 0 && data.retention === -1 && (parseInt(data.customRetentionDuration, 10) * 24 * 60 >= originalData.retention)) || (originalData.retention === -1 && data.retention === -1 && data.customRetentionDuration >= originalData.customRetentionDuration))",
292
- "disabled": "((originalData.retention >= 0 && data.retention >= 0 && ((data.retention >= originalData.retention && originalData.retention != 0) || data.retention == 0)) || (originalData.retention === -1 && data.retention >= 0 && ((data.retention >= parseInt(originalData.customRetentionDuration, 10) * 24 * 60) || data.retention == 0)) || (originalData.retention > 0 && data.retention === -1 && (parseInt(data.customRetentionDuration, 10) * 24 * 60 >= originalData.retention)) || (originalData.retention === -1 && data.retention === -1 && data.customRetentionDuration >= originalData.customRetentionDuration))",
293
- "confirm": {
294
- "text": "Lowering the retention period should be considered with caution: Past data exceeding the retention period will be lost.",
295
- "condition": "data.retentionConfirm && data.retentionConfirm != originalData.retentionConfirm",
296
- "title": "Please confirm!",
297
- "type": "warning"
298
- },
299
- "validator": "data.retentionConfirm",
300
- "validatorErrorText": "Confirmation required.",
301
- "validatorNoSaveOnError" : true,
302
- "doNotSave": true
195
+ "defaultTab": {
196
+ "type": "panel",
197
+ "label": "Default settings",
198
+ "items": {
199
+ "debounceTime": {
200
+ "newLine": true,
201
+ "type": "number",
202
+ "sm": 12,
203
+ "md": 4,
204
+ "min": 0,
205
+ "max": 86400000,
206
+ "label": "De-bounce time",
207
+ "help": "De-bounce interval(ms)"
208
+ },
209
+ "blockTime": {
210
+ "type": "number",
211
+ "sm": 12,
212
+ "md": 4,
213
+ "min": 0,
214
+ "max": 86400000,
215
+ "label": "Block time",
216
+ "defaultFunc": "(data.debounce || data.debounce === '0' || data.debounce === 0) ? parseInt(data.debounce, 10) : 0",
217
+ "help": "blockTime"
218
+ },
219
+ "changesRelogInterval": {
220
+ "newLine": true,
221
+ "type": "number",
222
+ "label": "log changes interval(s)",
223
+ "help": "0 = disable",
224
+ "sm": 12,
225
+ "md": 6,
226
+ "lg": 4,
227
+ "min": 0,
228
+ "max": 2147483
229
+ },
230
+ "changesMinDelta": {
231
+ "type": "number",
232
+ "label": "log changes minimal delta",
233
+ "help": "0 = disable delta check",
234
+ "sm": 12,
235
+ "md": 6,
236
+ "lg": 4
237
+ },
238
+ "retention": {
239
+ "newLine": true,
240
+ "type": "select",
241
+ "label": "retention",
242
+ "options": [
243
+ {
244
+ "value": 0,
245
+ "label": "keep forever"
246
+ },
247
+ {
248
+ "value": 63072000,
249
+ "label": "2 years"
250
+ },
251
+ {
252
+ "value": 31536000,
253
+ "label": "1 year"
254
+ },
255
+ {
256
+ "value": 15811200,
257
+ "label": "6 months"
258
+ },
259
+ {
260
+ "value": 7948800,
261
+ "label": "3 months"
262
+ },
263
+ {
264
+ "value": 2678400,
265
+ "label": "1 months"
266
+ },
267
+ {
268
+ "value": 1209600,
269
+ "label": "2 weeks"
270
+ },
271
+ {
272
+ "value": 604800,
273
+ "label": "1 week"
274
+ },
275
+ {
276
+ "value": 432000,
277
+ "label": "5 days"
278
+ },
279
+ {
280
+ "value": 259200,
281
+ "label": "3 days"
282
+ },
283
+ {
284
+ "value": 86400,
285
+ "label": "1 day"
286
+ },
287
+ {
288
+ "value": -1,
289
+ "label": "Custom timeframe"
290
+ }
291
+ ],
292
+ "sm": 12,
293
+ "md": 6
294
+ },
295
+ "customRetentionDuration": {
296
+ "type": "number",
297
+ "label": "Custom retention duration (days)",
298
+ "min": 1,
299
+ "sm": 12,
300
+ "md": 4,
301
+ "hidden": "(data.retention !== -1)",
302
+ "help": "Number of days to keep the data."
303
+ },
304
+ "retentionConfirm": {
305
+ "newLine": true,
306
+ "type": "checkbox",
307
+ "label": "Apply lower retention",
308
+ "hidden": "((originalData.retention >= 0 && data.retention >= 0 && ((data.retention >= originalData.retention && originalData.retention != 0) || data.retention == 0)) || (originalData.retention === -1 && data.retention >= 0 && ((data.retention >= parseInt(originalData.customRetentionDuration, 10) * 24 * 60) || data.retention == 0)) || (originalData.retention > 0 && data.retention === -1 && (parseInt(data.customRetentionDuration, 10) * 24 * 60 >= originalData.retention)) || (originalData.retention === -1 && data.retention === -1 && data.customRetentionDuration >= originalData.customRetentionDuration))",
309
+ "disabled": "((originalData.retention >= 0 && data.retention >= 0 && ((data.retention >= originalData.retention && originalData.retention != 0) || data.retention == 0)) || (originalData.retention === -1 && data.retention >= 0 && ((data.retention >= parseInt(originalData.customRetentionDuration, 10) * 24 * 60) || data.retention == 0)) || (originalData.retention > 0 && data.retention === -1 && (parseInt(data.customRetentionDuration, 10) * 24 * 60 >= originalData.retention)) || (originalData.retention === -1 && data.retention === -1 && data.customRetentionDuration >= originalData.customRetentionDuration))",
310
+ "confirm": {
311
+ "text": "Lowering the retention period should be considered with caution: Past data exceeding the retention period will be lost.",
312
+ "condition": "data.retentionConfirm && data.retentionConfirm != originalData.retentionConfirm",
313
+ "title": "Please confirm!",
314
+ "type": "warning"
315
+ },
316
+ "validator": "data.retentionConfirm",
317
+ "validatorErrorText": "Confirmation required.",
318
+ "validatorNoSaveOnError": true,
319
+ "doNotSave": true
320
+ },
321
+ "round": {
322
+ "newLine": true,
323
+ "type": "text",
324
+ "label": "Round real to",
325
+ "sm": 12,
326
+ "md": 4,
327
+ "lg": 3,
328
+ "validator": "((data.round || '').toString().length === 0) || isFinite(data.round)",
329
+ "validatorErrorText": "Enter a number or leave the field empty",
330
+ "validatorNoSaveOnError": true
331
+ },
332
+ "disableSkippedValueLogging": {
333
+ "newLine": true,
334
+ "label": "Disable charting optimized logging of skipped values",
335
+ "type": "checkbox",
336
+ "sm": 12,
337
+ "md": 4
338
+ },
339
+ "enableDebugLogs": {
340
+ "newLine": true,
341
+ "label": "Enable enhanced debug logs for the datapoint",
342
+ "type": "checkbox",
343
+ "sm": 12,
344
+ "md": 4
345
+ },
346
+ "debounce": {
347
+ "type": "number",
348
+ "sm": 12,
349
+ "md": 4,
350
+ "min": 0,
351
+ "label": "De-bounce time",
352
+ "help": "debounce",
353
+ "hidden": "true"
354
+ }
355
+ }
303
356
  },
304
- "round": {
305
- "newLine": true,
306
- "type": "text",
307
- "label": "Round real to",
308
- "sm": 12,
309
- "md": 4,
310
- "lg": 3,
311
- "validator": "((data.round || '').toString().length === 0) || isFinite(data.round)",
312
- "validatorErrorText": "Enter a number or leave the field empty",
313
- "validatorNoSaveOnError": true
357
+ "advancedTab": {
358
+ "type": "panel",
359
+ "label": "Expert Settings",
360
+ "hidden": "data.dbversion === '1.x'",
361
+ "items": {
362
+ "usetags": {
363
+ "type": "checkbox",
364
+ "sm": 12,
365
+ "md": 6,
366
+ "label": "Use tags to store metadata information, instead of fields",
367
+ "help": "usetags help",
368
+ "confirm": {
369
+ "text": "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).",
370
+ "condition": "data.usetags && data.usetags != originalData.usetags",
371
+ "title": "Please confirm!",
372
+ "type": "warning"
373
+ }
374
+ },
375
+ "pingserver": {
376
+ "type": "checkbox",
377
+ "sm": 12,
378
+ "md": 6,
379
+ "label": "Send health-check pings to database",
380
+ "help": "health-check help"
381
+ }
382
+ }
314
383
  },
315
- "disableSkippedValueLogging": {
316
- "newLine": true,
317
- "label": "Disable charting optimized logging of skipped values",
318
- "type": "checkbox",
319
- "sm": 12,
320
- "md": 4
384
+ "dataTab": {
385
+ "type": "panel",
386
+ "label": "Data browser",
387
+ "items": {
388
+ "_dataBrowser": {
389
+ "type": "custom",
390
+ "i18n": true,
391
+ "url": "custom/customComponents.js",
392
+ "name": "InfluxDBComponentsSet/Components/DataBrowser",
393
+ "guiApi": 2,
394
+ "sm": 12
395
+ }
396
+ }
321
397
  },
322
- "enableDebugLogs": {
323
- "newLine": true,
324
- "label": "Enable enhanced debug logs for the datapoint",
325
- "type": "checkbox",
326
- "sm": 12,
327
- "md": 4
398
+ "dockerInflux": {
399
+ "type": "panel",
400
+ "label": "InfluxDB Docker",
401
+ "hidden": "!data.dockerInflux?.enabled",
402
+ "items": {
403
+ "dockerInflux.bind": {
404
+ "newLine": true,
405
+ "listenOnAllPorts": true,
406
+ "type": "ip",
407
+ "label": "Start container on IP",
408
+ "sm": 12,
409
+ "md": 8
410
+ },
411
+ "dockerInflux.port": {
412
+ "type": "port",
413
+ "label": "Port",
414
+ "help": "The port on which the container will be reachable on localhost",
415
+ "default": 8086,
416
+ "sm": 12,
417
+ "md": 4
418
+ },
419
+ "dockerInflux.stopIfInstanceStopped": {
420
+ "newLine": true,
421
+ "type": "checkbox",
422
+ "label": "Stop container when instance stops",
423
+ "sm": 12,
424
+ "md": 6
425
+ },
426
+ "dockerInflux.autoImageUpdate": {
427
+ "type": "checkbox",
428
+ "label": "Auto-update Docker image",
429
+ "help": "If enabled, the latest Docker image will be pulled when the adapter starts.",
430
+ "sm": 12,
431
+ "md": 6
432
+ }
433
+ }
328
434
  },
329
- "debounce": {
330
- "type": "number",
331
- "sm": 12,
332
- "md": 4,
333
- "min": 0,
334
- "label": "De-bounce time",
335
- "help": "debounce",
336
- "hidden": "true"
435
+ "dockerGrafana": {
436
+ "type": "panel",
437
+ "label": "Grafana Docker",
438
+ "hidden": "!data.dockerGrafana?.enabled || !data.dockerInflux?.enabled",
439
+ "items": {
440
+ "dockerGrafana.bind": {
441
+ "type": "ip",
442
+ "label": "Start container on IP",
443
+ "listenOnAllPorts": true,
444
+ "sm": 12,
445
+ "md": 8
446
+ },
447
+ "dockerGrafana.port": {
448
+ "type": "port",
449
+ "label": "Port",
450
+ "help": "The port on which the container will be reachable on localhost",
451
+ "default": 3000,
452
+ "sm": 12,
453
+ "md": 4
454
+ },
455
+ "dockerGrafana.stopIfInstanceStopped": {
456
+ "newLine": true,
457
+ "type": "checkbox",
458
+ "hidden": "!!data.dockerInflux?.stopIfInstanceStopped",
459
+ "label": "Stop container when instance stops",
460
+ "sm": 12,
461
+ "md": 6
462
+ },
463
+ "dockerGrafana.autoImageUpdate": {
464
+ "type": "checkbox",
465
+ "label": "Auto-update Docker image",
466
+ "help": "If enabled, the latest Docker image will be pulled when the adapter starts.",
467
+ "sm": 12,
468
+ "md": 6
469
+ },
470
+ "dockerGrafana.adminSecurityPassword": {
471
+ "newLine": true,
472
+ "type": "password",
473
+ "label": "Admin security password",
474
+ "help": "Only by first start",
475
+ "xs": 12
476
+ },
477
+ "dockerGrafana.serverRootUrl": {
478
+ "newLine": true,
479
+ "type": "text",
480
+ "label": "Server root URL",
481
+ "help": "Defines the root URL, useful when Grafana is behind a reverse proxy.",
482
+ "xs": 12
483
+ },
484
+ "dockerGrafana.plugins": {
485
+ "newLine": true,
486
+ "type": "chips",
487
+ "label": "Plugins",
488
+ "help": "Auto-installs plugins at startup",
489
+ "xs": 12
490
+ },
491
+ "dockerGrafana.usersAllowSignUp": {
492
+ "newLine": true,
493
+ "type": "checkbox",
494
+ "label": "Enable user sign-ups",
495
+ "xs": 12
496
+ }
497
+ }
337
498
  }
338
- }
339
- },
340
- "advancedTab": {
341
- "type": "panel",
342
- "label": "Expert Settings",
343
- "items": {
344
- "usetags": {
345
- "type": "checkbox",
346
- "sm": 12,
347
- "md": 6,
348
- "label": "Use tags to store metadata information, instead of fields",
349
- "help": "usetags help",
350
- "hidden": "data.dbversion === '1.x'",
351
- "disabled": "data.dbversion === '1.x'",
352
- "confirm": {
353
- "text": "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).",
354
- "condition": "data.usetags && data.usetags != originalData.usetags",
355
- "title": "Please confirm!",
356
- "type": "warning"
357
- }
358
- },
359
- "pingserver": {
360
- "type": "checkbox",
361
- "sm": 12,
362
- "md": 6,
363
- "label": "Send health-check pings to database",
364
- "help": "health-check help",
365
- "hidden": "data.dbversion === '1.x'",
366
- "disabled": "data.dbversion === '1.x'"
367
- }
368
- }
369
499
  }
370
- }
371
500
  }