mirror of
https://github.com/xbgmsharp/postgsail.git
synced 2025-09-17 03:07:47 +00:00
Update cron process output, add autodiscovery
This commit is contained in:
@@ -15,7 +15,12 @@ select current_database();
|
|||||||
\echo 'Check the number of process pending'
|
\echo 'Check the number of process pending'
|
||||||
-- Should be 24
|
-- Should be 24
|
||||||
SELECT count(*) as jobs from public.process_queue pq where pq.processed is null;
|
SELECT count(*) as jobs from public.process_queue pq where pq.processed is null;
|
||||||
--set role scheduler
|
-- Switch to the scheduler role
|
||||||
|
--\echo 'Switch to the scheduler role'
|
||||||
|
--SET ROLE scheduler;
|
||||||
|
-- Should be 24
|
||||||
|
SELECT count(*) as jobs from public.process_queue pq where pq.processed is null;
|
||||||
|
-- Run the cron jobs
|
||||||
SELECT public.run_cron_jobs();
|
SELECT public.run_cron_jobs();
|
||||||
-- Check any pending job
|
-- Check any pending job
|
||||||
SELECT count(*) as any_pending_jobs from public.process_queue pq where pq.processed is null;
|
SELECT count(*) as any_pending_jobs from public.process_queue pq where pq.processed is null;
|
||||||
|
@@ -9,6 +9,9 @@ Check the number of process pending
|
|||||||
-[ RECORD 1 ]
|
-[ RECORD 1 ]
|
||||||
jobs | 26
|
jobs | 26
|
||||||
|
|
||||||
|
-[ RECORD 1 ]
|
||||||
|
jobs | 26
|
||||||
|
|
||||||
-[ RECORD 1 ]-+-
|
-[ RECORD 1 ]-+-
|
||||||
run_cron_jobs |
|
run_cron_jobs |
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user