-
Notifications
You must be signed in to change notification settings - Fork 885
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix crash in 1-step integer policy creation #5912
Conversation
8a7604a
to
ffc9d8c
Compare
Codecov Report
@@ Coverage Diff @@
## main #5912 +/- ##
==========================================
+ Coverage 79.49% 87.06% +7.56%
==========================================
Files 243 243
Lines 49131 55817 +6686
Branches 12318 12355 +37
==========================================
+ Hits 39059 48595 +9536
- Misses 4226 4885 +659
+ Partials 5846 2337 -3509
... and 222 files with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
6c32d92
to
fd0c735
Compare
@sb230132, @shhnwz: please review this pull request.
|
I'd request to put more details in the commit message explaining what went wrong and how it is fixed. |
tsl/src/bgw_policy/policies_v2.c
Outdated
ereport(ERROR, | ||
(errcode(ERRCODE_INTERNAL_ERROR), | ||
errmsg("could not find %s in config for job", | ||
POL_RETENTION_CONF_KEY_DROP_AFTER))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add some comments explaining why this is required.
tsl/test/sql/cagg_policy.sql
Outdated
@@ -630,3 +630,18 @@ SELECT * FROM deals_best_daily ORDER BY bucket LIMIT 2; | |||
-- expect to get an up-to-date notice | |||
CALL refresh_continuous_aggregate('deals_best_weekly', '2022-04-24', '2022-05-05'); | |||
SELECT * FROM deals_best_weekly; | |||
|
|||
-- github issue 5907 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
instead of mentioning issue number, it will be better if we mention what is being tested here exactly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added a line about what this test is meant to check
725c4bb
to
ffaae7a
Compare
Previously when a retention policy existed on the underlying hypertable, we would get a segmentation fault when trying to add a Cagg refresh policy, due to passing a bool instead of pointer to bool argument to function `ts_jsonb_get_int64_field` in a particular code path. Fixed by passing the expected pointer type. Fixes timescale#5907
ffaae7a
to
bdba699
Compare
This release contains bug fixes since the 2.11.0 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5909 CREATE INDEX ONLY ON hypertable creates index on chunks * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5909 CREATE INDEX ONLY ON hypertable creates index on chunks * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5909 CREATE INDEX ONLY ON hypertable creates index on chunks * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5909 CREATE INDEX ONLY ON hypertable creates index on chunks * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5909 CREATE INDEX ONLY ON hypertable creates index on chunks * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5909 CREATE INDEX ONLY ON hypertable creates index on chunks * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * #5923 Feature flags for TimescaleDB features **Bugfixes** * #5680 Fix DISTINCT query with JOIN on multiple segmentby columns * #5774 Fixed two bugs in decompression sorted merge code * #5786 Ensure pg_config --cppflags are passed * #5906 Fix quoting owners in sql scripts. * #5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * timescale#5923 Feature flags for TimescaleDB features **Bugfixes** * timescale#5680 Fix DISTINCT query with JOIN on multiple segmentby columns * timescale#5774 Fixed two bugs in decompression sorted merge code * timescale#5786 Ensure pg_config --cppflags are passed * timescale#5906 Fix quoting owners in sql scripts. * timescale#5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * #5923 Feature flags for TimescaleDB features **Bugfixes** * #5680 Fix DISTINCT query with JOIN on multiple segmentby columns * #5774 Fixed two bugs in decompression sorted merge code * #5786 Ensure pg_config --cppflags are passed * #5906 Fix quoting owners in sql scripts. * #5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * #5923 Feature flags for TimescaleDB features **Bugfixes** * #5680 Fix DISTINCT query with JOIN on multiple segmentby columns * #5774 Fixed two bugs in decompression sorted merge code * #5786 Ensure pg_config --cppflags are passed * #5906 Fix quoting owners in sql scripts. * #5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
This release contains bug fixes since the 2.11.1 release. We recommend that you upgrade at the next available opportunity. **Features** * #5923 Feature flags for TimescaleDB features **Bugfixes** * #5680 Fix DISTINCT query with JOIN on multiple segmentby columns * #5774 Fixed two bugs in decompression sorted merge code * #5786 Ensure pg_config --cppflags are passed * #5906 Fix quoting owners in sql scripts. * #5912 Fix crash in 1-step integer policy creation **Thanks** * @mrksngl for submitting a PR to fix extension upgrade scripts * @ericdevries for reporting an issue with DISTINCT queries using segmentby columns of compressed hypertable
Previously when a retention policy existed on the underlying hypertable,
we would get a segmentation fault when trying to add a Cagg refresh
policy, due to passing a bool instead of pointer to bool argument to
function
ts_jsonb_get_int64_field
in a particular code path.Fixed by passing the expected pointer type.
Fixes #5907