Get the latest tech news
The time keepers: pg_cron and pg_timetable
Deep dive into SQL & PostgreSQL to build reliable, rock-solid solutions with tips and tricks that keep business online. Data is everything. Explore, learn and innnovate to get them where you need faster and more efficiently.
While cron-like syntax is beneficial for adoption, it is where pg_cron falls short, as it does not support advanced cases like task chaining, dependencies, and triggers. And yes, if you have been paying attention, pg_timetable architecture allows for running tasks across multiple PostgreSQL clusters, making it an advanced orchestration tool. Featurepg_cronpg_timetableDistributionPostgreSQL extensionStandalone executableSchedulingLimited (cron-like)Extensive (intervals, calendar, custom)Job TypesSQLSQL, Built-in, ShellJob ChainingNoYesError HandlingBasicIntermediateLoggingBasicIntermediateDependenciesNoYesEase of UseEasyModerateConfigurationEasyModerateOrchestrationSingle ClusterAdvanced (multiple clusters) If your requirements are straightforward, such as running maintenance tasks, refreshing materialised views, or generating periodic reports using simple SQL commands, pg_cron is an excellent choice.
Or read this on Hacker News