Update duckdb. use more duckdb. Fix the display of stats

This commit is contained in:
Dan Milne
2025-12-25 12:03:25 +11:00
parent a0ff0edb73
commit 225d970123
11 changed files with 186 additions and 143 deletions

View File

@@ -55,6 +55,7 @@ production:
database: baffle_hub_production
username: baffle_hub
password: <%= ENV["BAFFLE_HUB_DATABASE_PASSWORD"] %>
pool: 80
cache:
<<: *sqlite_default
database: storage/production_cache.sqlite3

View File

@@ -1,5 +1,5 @@
# frozen_string_literal: true
module BaffleHub
VERSION = "0.3.0"
VERSION = "0.4.0"
end

View File

@@ -30,20 +30,30 @@ cleanup_old_events:
queue: background
schedule: every hour
# Export events from PostgreSQL to Parquet files for fast analytics
export_events_to_parquet:
class: ExportEventsToParquetJob
# Export events from PostgreSQL to DuckLake for fast analytics
export_events_to_ducklake:
class: ExportEventsToDucklakeJob
queue: default
schedule: every 1 minutes
# Consolidate completed hours into day files
consolidate_parquet_hourly:
class: ConsolidateParquetHourlyJob
queue: default
schedule: "5 * * * *" # At 5 minutes past every hour
# Merge DuckLake files and clean up immediately after
merge_ducklake_files:
class: MergeDucklakeFilesJob
queue: background
schedule: every 15 minutes
# Consolidate completed week into archive (Monday 00:05)
consolidate_parquet_weekly:
class: ConsolidateParquetWeeklyJob
queue: default
schedule: "5 0 * * 1" # Monday at 00:05
# OLD PARQUET SYSTEM (DISABLED - using DuckLake now)
# export_events_to_parquet:
# class: ExportEventsToParquetJob
# queue: default
# schedule: every 1 minutes
#
# consolidate_parquet_hourly:
# class: ConsolidateParquetHourlyJob
# queue: default
# schedule: "5 * * * *" # At 5 minutes past every hour
#
# consolidate_parquet_weekly:
# class: ConsolidateParquetWeeklyJob
# queue: default
# schedule: "5 0 * * 1" # Monday at 00:05