Skip to content

Use TTL for matviews regardless of --enterprise#6

Open
javier wants to merge 1 commit into
mainfrom
jv/matviews_remove_storage_policies
Open

Use TTL for matviews regardless of --enterprise#6
javier wants to merge 1 commit into
mainfrom
jv/matviews_remove_storage_policies

Conversation

@javier
Copy link
Copy Markdown
Owner

@javier javier commented May 28, 2026

Summary

  • QuestDB does not yet support STORAGE POLICY on materialized views, so matviews always use TTL (in both OSS and enterprise mode).
  • Tables continue to use STORAGE POLICY when --enterprise=true and --short_ttl=true.
  • New helper mv_retention_clause() mirrors retention_clause() but ignores the enterprise_policy argument. Keeping the matching signature means the 11 matview CREATE statements stay untouched.
  • The previous binding is kept as a commented line at the rc lambda so reverting is a one-line swap once matview storage policies land.

Test plan

  • Run with --short_ttl=true --enterprise=false: matviews get TTL, tables get TTL.
  • Run with --short_ttl=true --enterprise=true: matviews get TTL, tables get STORAGE POLICY.
  • Run with --short_ttl=false: neither tables nor matviews get a retention clause.

QuestDB does not yet support STORAGE POLICY on materialized views, so
matviews always fall back to TTL semantics. Tables continue to use
storage policies in enterprise mode. The previous behavior is kept as
a commented line for easy revert once matview storage policies land.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant