Skip to content
This repository was archived by the owner on Apr 2, 2024. It is now read-only.

Commit ca87ecd

Browse files
Implement apply_downsample_config and add E2E tests.
Signed-off-by: Harkishen-Singh <[email protected]>
1 parent 633a6fd commit ca87ecd

15 files changed

+195
-190
lines changed

docs/sql-api.md

+18-18
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,10 @@ function interval **prom_api.get_default_metric_retention_period**()
6262
```
6363
function boolean **prom_api.get_downsample_old_data**()
6464
```
65-
### prom_api.get_downsampling_state
65+
### prom_api.get_global_downsampling_state
6666
Get automatic downsample state
6767
```
68-
function boolean **prom_api.get_downsampling_state**()
68+
function boolean **prom_api.get_global_downsampling_state**()
6969
```
7070
### prom_api.get_metric_chunk_interval
7171
Get the chunk interval for a specific metric, or the default chunk interval if not explicitly set
@@ -192,10 +192,10 @@ function boolean **prom_api.set_default_retention_period**(retention_period inte
192192
```
193193
function void **prom_api.set_downsample_old_data**(_state boolean)
194194
```
195-
### prom_api.set_downsampling_state
195+
### prom_api.set_global_downsampling_state
196196
Set automatic-downsampling state for metrics. Downsampled data will be created only if this returns true
197197
```
198-
function void **prom_api.set_downsampling_state**(_state boolean)
198+
function void **prom_api.set_global_downsampling_state**(_state boolean)
199199
```
200200
### prom_api.set_metric_chunk_interval
201201
set a chunk interval for a specific metric (this overrides the default)
@@ -512,11 +512,21 @@ the specified span_id.
512512
```
513513
function TABLE(trace_id trace_id, parent_span_id bigint, span_id bigint, dist integer, path bigint[]) **ps_trace.upstream_spans**(_trace_id trace_id, _span_id bigint, _max_dist integer DEFAULT NULL::integer)
514514
```
515+
### _prom_catalog.add_compression_clause_to_downsample_view
516+
517+
```
518+
procedure void **_prom_catalog.add_compression_clause_to_downsample_view**(IN _schema text, IN _table_name text)
519+
```
515520
### _prom_catalog.add_job
516521
A wrapper around public.add_job that introduces jitter to job start times and schedules.
517522
```
518523
function integer **_prom_catalog.add_job**(proc regproc, schedule_interval interval, config jsonb DEFAULT NULL::jsonb)
519524
```
525+
### _prom_catalog.apply_downsample_config
526+
527+
```
528+
function void **_prom_catalog.apply_downsample_config**(config jsonb)
529+
```
520530
### _prom_catalog.attach_series_partition
521531

522532
```
@@ -581,7 +591,7 @@ function record **_prom_catalog.create_label_key**(new_key text, OUT id integer,
581591
### _prom_catalog.create_metric_downsampling_view
582592

583593
```
584-
function boolean **_prom_catalog.create_metric_downsampling_view**(_schema text, _metric_name text, _table_name text, _resolution interval)
594+
function boolean **_prom_catalog.create_metric_downsampling_view**(_schema text, _metric_name text, _table_name text, _interval interval)
585595
```
586596
### _prom_catalog.create_metric_table
587597

@@ -593,11 +603,6 @@ function record **_prom_catalog.create_metric_table**(metric_name_arg text, OUT
593603
```
594604
function boolean **_prom_catalog.create_metric_view**(metric_name text)
595605
```
596-
### _prom_catalog.create_or_update_downsampling
597-
598-
```
599-
procedure void **_prom_catalog.create_or_update_downsampling**(IN _schema_name text, IN _resolution interval, IN _retention interval)
600-
```
601606
### _prom_catalog.create_series
602607

603608
```
@@ -651,17 +656,17 @@ procedure void **_prom_catalog.do_decompress_chunks_after**(IN metric_table text
651656
### _prom_catalog.downsample_counter
652657

653658
```
654-
procedure void **_prom_catalog.downsample_counter**(IN _schema text, IN _table_name text, IN _resolution interval)
659+
procedure void **_prom_catalog.downsample_counter**(IN _schema text, IN _table_name text, IN _interval interval)
655660
```
656661
### _prom_catalog.downsample_gauge
657662

658663
```
659-
procedure void **_prom_catalog.downsample_gauge**(IN _schema text, IN _table_name text, IN _resolution interval)
664+
procedure void **_prom_catalog.downsample_gauge**(IN _schema text, IN _table_name text, IN _interval interval)
660665
```
661666
### _prom_catalog.downsample_summary
662667

663668
```
664-
procedure void **_prom_catalog.downsample_summary**(IN _schema text, IN _table_name text, IN _resolution interval)
669+
procedure void **_prom_catalog.downsample_summary**(IN _schema text, IN _table_name text, IN _interval interval)
665670
```
666671
### _prom_catalog.drop_metric_chunk_data
667672
drop chunks from schema_name.metric_name containing data older than older_than.
@@ -1126,11 +1131,6 @@ function void **_prom_catalog.unlock_for_vacuum_engine**()
11261131
```
11271132
function void **_prom_catalog.unlock_metric_for_maintenance**(metric_id integer)
11281133
```
1129-
### _prom_catalog.update_downsampling_state
1130-
1131-
```
1132-
function void **_prom_catalog.update_downsampling_state**(_schema_name text, _should_refresh boolean)
1133-
```
11341134
### _prom_catalog.update_execute_everywhere_entry
11351135

11361136
```

migration/idempotent/010-telemetry.sql

+4-4
Original file line numberDiff line numberDiff line change
@@ -101,11 +101,11 @@ $$
101101
PERFORM _ps_catalog.apply_telemetry('metrics_default_chunk_interval', result);
102102

103103
-- Metric downsampling.
104-
SELECT prom_api.get_automatic_downsample()::TEXT INTO result;
105-
PERFORM _ps_catalog.apply_telemetry('metrics_automatic_downsampling_enabled', result);
104+
SELECT prom_api.get_global_downsampling_state()::TEXT INTO result;
105+
PERFORM _ps_catalog.apply_telemetry('metrics_downsampling_enabled', result);
106106

107-
SELECT array_agg(resolution || ':' || retention)::TEXT INTO result FROM _prom_catalog.rollup; -- Example: {00:05:00:720:00:00,01:00:00:8760:00:00} => {HH:MM:SS}
108-
PERFORM _ps_catalog.apply_telemetry('metrics_automatic_downsampling_resolutions', result);
107+
SELECT array_agg(ds_interval || ':' || retention)::TEXT INTO result FROM _prom_catalog.downsample; -- Example: {00:05:00:720:00:00,01:00:00:8760:00:00} => {HH:MM:SS}
108+
PERFORM _ps_catalog.apply_telemetry('metrics_downsampling_configs', result);
109109

110110
IF ( SELECT count(*)>0 FROM _prom_catalog.metric WHERE metric_name = 'prometheus_tsdb_head_series' ) THEN
111111
-- Calculate active series in Promscale. This is done by taking the help of the Prometheus metric 'prometheus_tsdb_head_series'.

migration/idempotent/017-metric-downsampling.sql

+25-38
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
-- Metric downsampling by metric type
2-
CREATE OR REPLACE PROCEDURE _prom_catalog.downsample_gauge(_schema TEXT, _table_name TEXT, _resolution INTERVAL)
2+
CREATE OR REPLACE PROCEDURE _prom_catalog.downsample_gauge(_schema TEXT, _table_name TEXT, _interval INTERVAL)
33
SET search_path = pg_catalog, pg_temp
44
AS
55
$$
@@ -18,12 +18,12 @@ BEGIN
1818
max(value) as max
1919
FROM prom_data.%2$I
2020
GROUP BY public.time_bucket(%4$L, time), series_id WITH NO DATA
21-
', _schema, _table_name, 'UTC', _resolution::text);
21+
', _schema, _table_name, 'UTC', _interval::text);
2222
END;
2323
$$
2424
LANGUAGE plpgsql;
2525

26-
CREATE OR REPLACE PROCEDURE _prom_catalog.downsample_counter(_schema TEXT, _table_name TEXT, _resolution INTERVAL)
26+
CREATE OR REPLACE PROCEDURE _prom_catalog.downsample_counter(_schema TEXT, _table_name TEXT, _interval INTERVAL)
2727
SET search_path = pg_catalog, pg_temp
2828
AS
2929
$$
@@ -41,12 +41,12 @@ BEGIN
4141
_prom_catalog.irate(array_agg(value)) irate
4242
FROM prom_data.%2$I
4343
GROUP BY public.time_bucket(%4$L, time), series_id WITH NO DATA
44-
', _schema, _table_name, 'UTC', _resolution::text);
44+
', _schema, _table_name, 'UTC', _interval::text);
4545
END;
4646
$$
4747
LANGUAGE PLPGSQL;
4848

49-
CREATE OR REPLACE PROCEDURE _prom_catalog.downsample_summary(_schema TEXT, _table_name TEXT, _resolution INTERVAL)
49+
CREATE OR REPLACE PROCEDURE _prom_catalog.downsample_summary(_schema TEXT, _table_name TEXT, _interval INTERVAL)
5050
SET search_path = pg_catalog, pg_temp
5151
AS
5252
$$
@@ -63,7 +63,7 @@ BEGIN
6363
count(value) as count
6464
FROM prom_data.%2$I
6565
GROUP BY public.time_bucket(%4$L, time), series_id WITH NO DATA
66-
', _schema, _table_name, 'UTC', _resolution::text);
66+
', _schema, _table_name, 'UTC', _interval::text);
6767
END;
6868
$$
6969
LANGUAGE PLPGSQL;
@@ -104,7 +104,7 @@ LANGUAGE PLPGSQL;
104104

105105
-- create_metric_downsampling_view decides which query should be used for downsampling the given metric depending of metric type
106106
-- and calls the respective creation function. It returns true if metric downsampling view was created.
107-
CREATE OR REPLACE FUNCTION _prom_catalog.create_metric_downsampling_view(_schema TEXT, _metric_name TEXT, _table_name TEXT, _resolution INTERVAL)
107+
CREATE OR REPLACE FUNCTION _prom_catalog.create_metric_downsampling_view(_schema TEXT, _metric_name TEXT, _table_name TEXT, _interval INTERVAL)
108108
RETURNS BOOLEAN
109109
SET search_path = pg_catalog, pg_temp
110110
AS
@@ -129,12 +129,12 @@ BEGIN
129129

130130
CASE
131131
WHEN _metric_type = 'GAUGE' THEN
132-
CALL _prom_catalog.downsample_gauge(_schema, _table_name, _resolution);
132+
CALL _prom_catalog.downsample_gauge(_schema, _table_name, _interval);
133133
WHEN _metric_type = 'COUNTER' OR _metric_type = 'HISTOGRAM' THEN
134-
CALL _prom_catalog.downsample_counter(_schema, _table_name, _resolution);
134+
CALL _prom_catalog.downsample_counter(_schema, _table_name, _interval);
135135
_default_query_column := 'last';
136136
WHEN _metric_type = 'SUMMARY' THEN
137-
CALL _prom_catalog.downsample_summary(_schema, _table_name, _resolution);
137+
CALL _prom_catalog.downsample_summary(_schema, _table_name, _interval);
138138
ELSE
139139
RAISE WARNING '[Downsampling] Skipping creation of metric downsampling for %. REASON: invalid metric_type. Wanted {GAUGE, COUNTER, HISTOGRAM, SUMMARY}, received %', _metric_name, _metric_type;
140140
RETURN FALSE;
@@ -146,7 +146,7 @@ END;
146146
$$
147147
LANGUAGE PLPGSQL;
148148

149-
-- scan_for_new_downsampling_views is called in regular intervals to scan for either new metrics or for new downsampling resolutions
149+
-- scan_for_new_downsampling_views is called in regular intervals to scan for either new metrics or for new downsampling configs
150150
-- and create metric downsampling for them.
151151
CREATE OR REPLACE PROCEDURE _prom_catalog.scan_for_new_downsampling_views(job_id int, config jsonb)
152152
AS
@@ -162,7 +162,7 @@ BEGIN
162162
-- Note: We cannot use SET in the procedure declaration because we do transaction control
163163
-- and we can _only_ use SET LOCAL in a procedure which _does_ transaction control
164164
SET LOCAL search_path = pg_catalog, pg_temp;
165-
IF ( SELECT prom_api.get_downsampling_state()::BOOLEAN IS FALSE ) THEN
165+
IF ( SELECT prom_api.get_global_downsampling_state()::BOOLEAN IS FALSE ) THEN
166166
RETURN;
167167
END IF;
168168

@@ -176,7 +176,7 @@ BEGIN
176176
SELECT 1 FROM _prom_catalog.metric_downsample md WHERE md.downsample_id = d.id AND md.metric_id = mt.id
177177
) ORDER BY mt.id -- Get metric names that have a pending downsampling creation.
178178
LOOP
179-
SELECT INTO downsampling_view_created _prom_catalog.create_metric_downsampling_view(d.schema_name, m.metric_name, m.table_name, d.resolution);
179+
SELECT INTO downsampling_view_created _prom_catalog.create_metric_downsampling_view(d.schema_name, m.metric_name, m.table_name, d.ds_interval);
180180
IF downsampling_view_created THEN
181181
INSERT INTO _prom_catalog.metric_downsample(downsample_id, metric_id, refresh_pending) VALUES (d.id, m.id, TRUE);
182182
downsampling_view_count := downsampling_view_count + 1;
@@ -199,7 +199,7 @@ BEGIN
199199
md.id as metric_downsample_id,
200200
dwn.schema_name as schema_name,
201201
mt.table_name as table_name,
202-
dwn.resolution as resolution,
202+
dwn.ds_interval as ds_interval,
203203
dwn.id as downsample_id
204204
FROM _prom_catalog.metric_downsample md
205205
INNER JOIN _prom_catalog.downsample dwn ON (md.downsample_id = dwn.id)
@@ -219,7 +219,7 @@ BEGIN
219219
-- 2. In case of non-graceful shutdown, we will successfully register the non-registered downsampling viws the
220220
-- next time this procedure is called. Earlier, this was done using temp table, which did not
221221
-- provide this guarantee
222-
PERFORM prom_api.register_metric_view(d.schema_name, d.table_name, d.resolution, false, d.downsample_id);
222+
PERFORM prom_api.register_metric_view(d.schema_name, d.table_name, d.ds_interval, false, d.downsample_id);
223223
COMMIT;
224224
SET LOCAL search_path = pg_catalog, pg_temp;
225225
END LOOP;
@@ -230,6 +230,7 @@ LANGUAGE PLPGSQL;
230230
-- apply_downsample_config does 2 things:
231231
-- 1. Create new downsampling configurations based on the given config
232232
-- 2. Update the existing downsampling config in terms of retention, enabling/disabling downsampling config
233+
-- The given config must be an array of <schema_name, ds_interval, retention>
233234
CREATE OR REPLACE FUNCTION _prom_catalog.apply_downsample_config(config jsonb)
234235
RETURNS VOID
235236
SET search_path = pg_catalog, pg_temp
@@ -251,8 +252,8 @@ BEGIN
251252
END LOOP;
252253

253254
-- Insert or update the retention duration and enable the downsampling if disabled.
254-
INSERT INTO _prom_catalog.downsample (schema_name, resolution, retention, should_refresh)
255-
SELECT a.schema_name, a.resolution, a.retention, TRUE FROM unnest(_input) a
255+
INSERT INTO _prom_catalog.downsample (schema_name, ds_interval, retention, should_refresh)
256+
SELECT a.schema_name, a.ds_interval, a.retention, TRUE FROM unnest(_input) a
256257
ON CONFLICT (schema_name) DO UPDATE
257258
SET
258259
retention = excluded.retention,
@@ -265,6 +266,7 @@ BEGIN
265266
END;
266267
$$
267268
LANGUAGE PLPGSQL;
269+
GRANT EXECUTE ON FUNCTION _prom_catalog.apply_downsample_config(jsonb) TO prom_writer;
268270

269271
-- delete_downsampling deletes everything related to the given downsampling schema name. It does the following in order:
270272
-- 1. Delete the entries in _prom_catalog.downsample
@@ -291,42 +293,27 @@ $$
291293
LANGUAGE PLPGSQL;
292294
GRANT EXECUTE ON PROCEDURE _prom_catalog.delete_downsampling(text) TO prom_writer;
293295

294-
CREATE OR REPLACE FUNCTION _prom_catalog.update_downsampling_state(_schema_name TEXT, _should_refresh BOOLEAN)
295-
RETURNS VOID
296-
SET search_path = pg_catalog, pg_temp
297-
AS
298-
$$
299-
BEGIN
300-
UPDATE _prom_catalog.downsample SET should_refresh = _should_refresh WHERE schema_name = _schema_name;
301-
IF NOT FOUND THEN
302-
RAISE EXCEPTION 'No entry found for schema %', _schema_name;
303-
END IF;
304-
END;
305-
$$
306-
LANGUAGE PLPGSQL;
307-
GRANT EXECUTE ON FUNCTION _prom_catalog.update_downsampling_state(TEXT, BOOLEAN) TO prom_admin;
308-
309-
CREATE OR REPLACE FUNCTION prom_api.set_downsampling_state(_state BOOLEAN)
296+
CREATE OR REPLACE FUNCTION prom_api.set_global_downsampling_state(_state BOOLEAN)
310297
RETURNS VOID
311298
SET search_path = pg_catalog, pg_temp
312299
AS $$
313300
SELECT _prom_catalog.set_default_value('downsample', _state::text);
314301
$$
315302
LANGUAGE SQL;
316-
COMMENT ON FUNCTION prom_api.set_downsampling_state(BOOLEAN)
303+
COMMENT ON FUNCTION prom_api.set_global_downsampling_state(BOOLEAN)
317304
IS 'Set automatic-downsampling state for metrics. Downsampled data will be created only if this returns true';
318-
GRANT EXECUTE ON FUNCTION prom_api.set_downsampling_state(BOOLEAN) TO prom_admin;
305+
GRANT EXECUTE ON FUNCTION prom_api.set_global_downsampling_state(BOOLEAN) TO prom_admin;
319306

320-
CREATE OR REPLACE FUNCTION prom_api.get_downsampling_state()
307+
CREATE OR REPLACE FUNCTION prom_api.get_global_downsampling_state()
321308
RETURNS BOOLEAN
322309
SET search_path = pg_catalog, pg_temp
323310
AS $$
324311
SELECT _prom_catalog.get_default_value('downsample')::boolean;
325312
$$
326313
LANGUAGE SQL;
327-
COMMENT ON FUNCTION prom_api.get_downsampling_state()
314+
COMMENT ON FUNCTION prom_api.get_global_downsampling_state()
328315
IS 'Get automatic downsample state';
329-
GRANT EXECUTE ON FUNCTION prom_api.get_downsampling_state() TO prom_admin;
316+
GRANT EXECUTE ON FUNCTION prom_api.get_global_downsampling_state() TO prom_admin;
330317

331318
CREATE OR REPLACE FUNCTION prom_api.set_downsample_old_data(_state BOOLEAN)
332319
RETURNS VOID

migration/idempotent/018-metric-downsampling-maintenance.sql

+8-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DECLARE
55
_refresh_interval INTERVAL;
66
_active_chunk_interval INTERVAL;
77
_ignore_downsampling_clause TEXT := '';
8-
_refresh_downsampled_data BOOLEAN := (SELECT prom_api.get_downsampling_state()::BOOLEAN);
8+
_refresh_downsampled_data BOOLEAN := (SELECT prom_api.get_global_downsampling_state()::BOOLEAN);
99
_should_refresh_clause TEXT := 'AND (SELECT should_refresh FROM _prom_catalog.downsample WHERE id = m.downsample_id) = TRUE';
1010
_safety_refresh_start_buffer INTERVAL := INTERVAL '0 minutes';
1111
r RECORD;
@@ -16,7 +16,7 @@ BEGIN
1616
_active_chunk_interval := (SELECT _prom_catalog.get_default_chunk_interval()::INTERVAL * 2);
1717
_refresh_interval := (config ->> 'refresh_interval')::INTERVAL;
1818
IF _refresh_interval IS NULL THEN
19-
RAISE EXCEPTION 'refresh_interval cannot be null';
19+
RAISE EXCEPTION 'Caggs refresh policy: refresh_interval cannot be null';
2020
END IF;
2121

2222
IF ( SELECT _refresh_interval < INTERVAL '30 minutes' ) THEN
@@ -25,7 +25,7 @@ BEGIN
2525
-- of refreshing data, a system with a lot of metrics and series might take > 10 minutes to refresh a 5 minute downsampling.
2626
-- This will lead to data loss. Hence, we give a refresh buffer of 30 minutes early to start.
2727
--
28-
-- This problem is not seen in large downsampling resolutions like 1 hour, since the 2 buckets duration gives 2 hours
28+
-- This problem is not seen in large downsampling intervals like 1 hour, since the 2 buckets duration gives 2 hours
2929
-- of time to complete refresh, which is usually sufficient.
3030
_safety_refresh_start_buffer := INTERVAL '30 minutes';
3131
END IF;
@@ -99,6 +99,11 @@ DECLARE
9999
r RECORD;
100100

101101
BEGIN
102+
IF NOT (SELECT prom_api.get_global_downsampling_state()::BOOLEAN) THEN
103+
-- Do not compress any Cagg if downsampling state is false.
104+
RETURN;
105+
END IF;
106+
102107
FOR r IN
103108
SELECT
104109
format('%I.%I', m.table_schema, m.table_name) AS compressible_cagg,

migration/incremental/036-metric-downsample.sql

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
CREATE TABLE _prom_catalog.downsample (
22
id SERIAL PRIMARY KEY,
33
schema_name TEXT NOT NULL,
4-
resolution INTERVAL NOT NULL,
4+
ds_interval INTERVAL NOT NULL,
55
retention INTERVAL NOT NULL,
66
should_refresh BOOLEAN DEFAULT FALSE,
77
UNIQUE(schema_name),
8-
UNIQUE(resolution) -- To avoid ds_1m and ds_60s, though technically, both are the same.
8+
UNIQUE(ds_interval) -- To avoid ds_1m and ds_60s, as technically, both are the same.
99
);
1010
GRANT SELECT ON TABLE _prom_catalog.downsample TO prom_reader;
1111
GRANT SELECT, INSERT, UPDATE, DELETE ON TABLE _prom_catalog.downsample TO prom_writer;

sql-tests/testdata/custom_downsample.sql

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ SELECT register_metric_view('custom', 'test', INTERVAL '30 minutes');
2929
SELECT ok(count(*) = 337, 'samples in custom downsample') FROM custom.test;
3030

3131

32-
-- # Test compressing metric-rollups.
32+
-- # Test compressing metric downsampling.
3333

3434
\i 'testdata/scripts/test-helpers.sql'
3535

@@ -46,7 +46,7 @@ ALTER MATERIALIZED VIEW custom.test SET (timescaledb.compress = true);
4646
CALL _prom_catalog.execute_caggs_compression_policy(2, '{}'::jsonb);
4747
SELECT ok(compressed_chunks_exist('custom.test') = true);
4848

49-
-- # Test retaining metric-rollups.
49+
-- # Test retaining metric downsampling.
5050

5151
SELECT ok(count(*) > 0) FROM (SELECT show_chunks('custom.test')) a;
5252

sql-tests/testdata/custom_downsample_refresh.sql

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ FROM generate_series(
4545
-- # TEST refreshing custom downsample.
4646

4747
-- Check samples before calling the refresh func.
48-
SELECT ok(count(*) = 344, 'samples in custom downsample before refresh') FROM custom.test; -- Samples increased even before calling refresh func. My guess is that this is due to timescaledb.materalized behaviour.
48+
SELECT ok(count(*) = 344, 'samples in custom downsample before refresh') FROM custom.test; -- Samples increased even before calling refresh func. My guess is that this is due to timescaledb.materialized behaviour.
4949

5050
CALL _prom_catalog.execute_caggs_refresh_policy(1, json_build_object('refresh_interval', interval '30 minutes')::jsonb);
5151

sql-tests/testdata/maintenance_jobs_separation.sql

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ WHERE proc_schema = '_prom_catalog'
5252
AND NOT (proc_name = 'scan_for_new_downsampling_views' OR proc_name = 'execute_caggs_compression_policy' OR proc_name = 'execute_caggs_retention_policy')
5353
AND NOT coalesce(config, '{}'::jsonb) ?& ARRAY ['signal', 'type'];
5454

55-
SELECT ok(COUNT(*) = 3, 'Only the new-style configurations should be present')
55+
SELECT ok(COUNT(*) = 6, 'Only the new-style configurations should be present')
5656
FROM timescaledb_information.jobs
5757
WHERE proc_schema = '_prom_catalog'
5858
AND (schedule_interval >= '10 min' OR schedule_interval < '15 min');

0 commit comments

Comments
 (0)