-
Notifications
You must be signed in to change notification settings - Fork 895
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
[Bug]: Continuous aggregate performance with time_bucket and timezone #4825
Comments
@hardikm10 currently we support pushdown only for |
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
Added the ability to chunk exclusion happen when using time_bucket(width, ts, tzname, origin, offset) variation. Fixes timescale#4825
@fabriziomello Thanks for looking into this. We are facing the same issue. Are there any plans to put this on the roadmap? Thanks a lot in advance! |
@fabriziomello Sorry to ask again, is this still being looked after? Thanks for your effort. |
@fabriziomello wanted to check on this issue as well, as I'm running into the same issue, which makes timezones in cagg unusable at the moment, my cagg policy runs for ~4.5 minutes with only about 4gb of data in the hypertable. Any way I can support on fixing it? |
Hey, there are an ongoing (and kinda of abandoned due to other priorities) PR to add support of time_bucket with timezone on caggs (#4854), but still require some more work: #4854 (review). I don't have an ETA for it yet due to a lot of changes internally in the company, but this is something that is on my radar. |
Hey @fabriziomello, Thanks for the update! I'll keep an eye on the PR then. |
Since the optional time_bucket arguments like offset, origin and timezone shift the output by at most bucket width we can optimize these similar to how we optimize the other time_bucket constraints. Fixes timescale#4825
Since the optional time_bucket arguments like offset, origin and timezone shift the output by at most bucket width we can optimize these similar to how we optimize the other time_bucket constraints. Fixes timescale#4825
Since the optional time_bucket arguments like offset, origin and timezone shift the output by at most bucket width we can optimize these similar to how we optimize the other time_bucket constraints. Fixes timescale#4825
Since the optional time_bucket arguments like offset, origin and timezone shift the output by at most bucket width we can optimize these similar to how we optimize the other time_bucket constraints. Fixes timescale#4825
Since the optional time_bucket arguments like offset, origin and timezone shift the output by at most bucket width we can optimize these similar to how we optimize the other time_bucket constraints. Fixes #4825
What type of bug is this?
Performance issue
What subsystems and features are affected?
Continuous aggregate, Query planner
What happened?
While investigating for the slow and cpu heavy refresh of a C-Agg, we observed that querying the underlying partial_view is scanning the entire hypertable. A partial view which is present inside the _timescaledb_internal schema is used to read the data from the main-hypertable during the C-Agg refresh. We are using time_bucket() function with timezone as well. If we remove the timezone argument, the underlying query explain looks robust, but with any timezone, the produced plan looks like scanning all the chunks. We think this might be the reason of slowness but would really appreciate any thoughts.
TimescaleDB version affected
2.8.1
PostgreSQL version used
14.5
What operating system did you use?
MST
What installation method did you use?
Other
What platform did you run on?
Managed Service for TimescaleDB (MST/Aiven)
Relevant log output and stack trace
How can we reproduce the bug?
Setup
Create the cagg using the timezone information in the time_bucket function
However, if I remove the Timezone information from the defn of C-Agg:
The text was updated successfully, but these errors were encountered: