Skip to content

Scheduled view refreshes should use application-layer scheduling instead of pg_cron #576

Description

@kbighorse

Problem

pg_cron is required by db/initialization.py, core/initializers.py, and the pygeoapi migration (d5e6f7a8b9c0). It hard-fails when unavailable, blocking local development and test runs on standard PostgreSQL installs that don't ship pg_cron.

Proposal

  • Move scheduled tasks (materialized view refreshes) to the application layer (e.g. APScheduler, Celery beat, or a simple cron job)
  • Remove pg_cron as a database dependency
  • Make db/initialization.py and core/initializers.py gracefully skip pg_cron in the interim

Current workaround

Skip the hard-fail checks locally by patching initialization.py and initializers.py to treat pg_cron as optional.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions