mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-23 16:26:42 +02:00
feat: integrate uload and picture, unify package naming
- Add uload project with apps/web structure
- Reorganize from flat to monorepo structure
- Remove PocketBase binary and local data
- Update to pnpm and @uload/web namespace
- Add picture project to monorepo
- Remove embedded git repository
- Unify all package names to @{project}/{app} schema:
- @maerchenzauber/* (was @storyteller/*)
- @manacore/* (was manacore-*, manacore)
- @manadeck/* (was web, backend, manadeck)
- @memoro/* (was memoro-web, landing, memoro)
- @picture/* (already unified)
- @uload/web
- Add convenient dev scripts for all apps:
- pnpm dev:{project}:web
- pnpm dev:{project}:landing
- pnpm dev:{project}:mobile
- pnpm dev:{project}:backend
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
c6c4c5a552
commit
c712a2504a
1031 changed files with 189301 additions and 290 deletions
66
picture/setup-cron-job.sql
Normal file
66
picture/setup-cron-job.sql
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
-- ============================================================================
|
||||
-- SETUP pg_cron WORKER for Job Queue Processing
|
||||
-- ============================================================================
|
||||
--
|
||||
-- Führe dieses SQL-Statement im Supabase Dashboard SQL Editor aus:
|
||||
-- https://supabase.com/dashboard/project/mjuvnnjxwfwlmxjsgkqu/sql
|
||||
--
|
||||
-- Dieses Statement erstellt einen Cron-Job, der jede Minute die
|
||||
-- process-jobs Edge Function aufruft, um Jobs aus der Queue zu verarbeiten.
|
||||
-- ============================================================================
|
||||
|
||||
-- Schedule process-jobs to run every minute
|
||||
SELECT cron.schedule(
|
||||
'process-job-queue',
|
||||
'* * * * *', -- Every minute
|
||||
$$
|
||||
SELECT net.http_post(
|
||||
url := 'https://mjuvnnjxwfwlmxjsgkqu.supabase.co/functions/v1/process-jobs',
|
||||
headers := jsonb_build_object(
|
||||
'Content-Type', 'application/json',
|
||||
'Authorization', 'Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6Im1qdXZubmp4d2Z3bG14anNna3F1Iiwicm9sZSI6InNlcnZpY2Vfcm9sZSIsImlhdCI6MTc1NjI1ODk1NSwiZXhwIjoyMDcxODM0OTU1fQ.c_30KdU1wD94r-w9Y_Vgg_FYRHJiPT8Peiv3SQJbhZg'
|
||||
),
|
||||
body := '{}'::jsonb
|
||||
);
|
||||
$$
|
||||
);
|
||||
|
||||
-- ============================================================================
|
||||
-- VERIFICATION
|
||||
-- ============================================================================
|
||||
-- Nach dem Ausführen, prüfe ob der Cron-Job erfolgreich erstellt wurde:
|
||||
|
||||
-- 1. Check if cron job exists
|
||||
SELECT
|
||||
jobid,
|
||||
jobname,
|
||||
schedule,
|
||||
active,
|
||||
nodename
|
||||
FROM cron.job
|
||||
WHERE jobname = 'process-job-queue';
|
||||
|
||||
-- 2. Wait 1-2 minutes, then check execution history
|
||||
SELECT
|
||||
jobid,
|
||||
runid,
|
||||
job_pid,
|
||||
status,
|
||||
return_message,
|
||||
start_time,
|
||||
end_time
|
||||
FROM cron.job_run_details
|
||||
WHERE jobid = (SELECT jobid FROM cron.job WHERE jobname = 'process-job-queue')
|
||||
ORDER BY start_time DESC
|
||||
LIMIT 10;
|
||||
|
||||
-- ============================================================================
|
||||
-- TROUBLESHOOTING
|
||||
-- ============================================================================
|
||||
|
||||
-- If you need to delete and recreate the cron job:
|
||||
-- SELECT cron.unschedule('process-job-queue');
|
||||
-- Then run the schedule command again
|
||||
|
||||
-- If the job is failing, check the Edge Function logs:
|
||||
-- https://supabase.com/dashboard/project/mjuvnnjxwfwlmxjsgkqu/logs/edge-functions
|
||||
Loading…
Add table
Add a link
Reference in a new issue