Class: Timescaledb::Scenic::Adapter
- Inherits:
-
Scenic::Adapters::Postgres
- Object
- Scenic::Adapters::Postgres
- Timescaledb::Scenic::Adapter
- Defined in:
- lib/timescaledb/scenic/adapter.rb
Instance Method Summary collapse
-
#views ⇒ Object
Timescale does some funky stuff under the hood with continuous aggregates.
Instance Method Details
#views ⇒ Object
Timescale does some funky stuff under the hood with continuous aggregates. A continuous aggregate is made up of:
-
A hypertable to store the materialized data
-
An entry in the jobs table to refresh the data
-
A view definition that union’s the hypertable and any recent data not included in the hypertable
That doesn’t dump well, even to structure.sql (we lose the job definition, since it’s not part of the DDL).
Our schema dumper implementation will handle dumping the continuous aggregate definitions, but we need to override Scenic’s schema dumping to exclude those continuous aggregates.
50 51 52 |
# File 'lib/timescaledb/scenic/adapter.rb', line 50 def views Views.new(connection).all end |