Job Monitoring
How to monitor background job execution, worker health, and task throughput.
The Job Monitoring dashboard gives staff visibility into background task execution — email sending, trial processing, data syncing, and other async operations.
#Accessing Job Monitoring
Navigate to Admin Dashboard → Jobs. The page shows task statistics, throughput charts, and a filterable task list.
#Worker Health
A status pill in the top-right corner shows the current worker health:
- Green "Worker Healthy" — the worker process is running and responsive
- Red "Worker Unhealthy" — the worker is unreachable or has stopped processing
The health status polls every 30 seconds automatically. Hover over the pill to see the last heartbeat timestamp or error reason.
#Stats Cards
Four stat cards show task execution metrics for the selected time period:
| Card | Description |
|---|---|
| Total Executed | Number of tasks that ran in the period |
| Success | Tasks that completed successfully |
| Failed | Tasks that failed (includes retry attempts) |
| Avg Duration | Average task execution time |
#Period Selector
Use the period selector to change the stats window:
| Period | Description |
|---|---|
| 1h | Last hour |
| 6h | Last 6 hours |
| 24h | Last 24 hours (default) |
| 7d | Last 7 days |
| 30d | Last 30 days |
The period only affects the stats cards and throughput chart, not the task list.
#Throughput Chart
An area chart below the stats shows task execution over time with two series:
- Success (green line with gradient fill) — successful task completions
- Failed (red line with gradient fill) — failed task executions
Hover over any data point to see the exact counts for that time bucket.
#Task Name Breakdown
A table shows execution counts per task type (e.g., send_claim_verification_email, check_trial_reminders, process_trial_expirations, process_document). Each row shows the task name and its total execution count for the selected period.
#Task List
The bottom section shows a filterable, paginated list of individual task executions.
#Filters
| Filter | Description |
|---|---|
| Task Name | Free-text filter by task name |
| Status | Filter by status: All, Success, Failed, Running, Pending |
| From Date | Show tasks on or after this date |
| To Date | Show tasks on or before this date |
Click Clear to reset all filters at once.
#Task Table
Each row shows:
| Column | Breakpoint | Description |
|---|---|---|
| Task Name | Always | The task function name |
| Status | Always | Success, Failed, Running, or Pending badge |
| Duration | sm+ | How long the task took to execute |
| Started | md+ | Start timestamp |
| Finished | lg+ | Completion timestamp |
Click any row to open the Task Detail Drawer.
#Task Detail Drawer
The detail drawer shows comprehensive information about a single task execution:
#Timing
- Started at — when the task began
- Finished at — when it completed
- Duration — total execution time
#Labels
Key-value metadata associated with the task (e.g., event type, user ID, email address).
#Result
For successful tasks, the result JSON is displayed in a formatted code block.
#Error
For failed tasks, the error message and full traceback are shown in a scrollable code block. Use this to diagnose failures.
#Document AI Processing Pipeline
When an expert uploads a document (CV, certificate, etc.), the platform automatically extracts its text content and indexes it for attorney search. This pipeline runs as background tasks visible in Job Monitoring.
#Pipeline Steps
process_document— Downloads the file from S3 (or local storage in dev), extracts plain text using pypdf (PDF) or python-docx (DOCX/DOC), and stores the extracted text on theexpert_documentsrecord.index_document_chunks— Aggregates extracted text from all of an expert's ready documents and re-indexes the expert in Elasticsearch, so the document content becomes searchable by attorneys.
#Document Processing Statuses
Each document in the expert_documents table tracks its processing state:
| Status | Meaning |
|---|---|
| pending | Uploaded but not yet picked up by the worker |
| processing | Currently being extracted |
| ready | Text extracted and indexed successfully |
| failed | Extraction failed (unsupported format, corrupt file, or empty text) |
#Troubleshooting
- Failed extractions — filter the task list by
process_documentand status "Failed". Open the task detail drawer to see the error traceback. Common causes: corrupt PDF, password-protected file, or unsupported format. - Missing search results — if an expert's documents aren't appearing in search, check that their documents show
processing_status = 'ready'and thatindex_document_chunksran successfully after extraction. - Supported formats — PDF (
.pdf), Word (.docx,.doc). Other formats are logged as unsupported and skipped.
#Pagination
The task list shows 50 items per page with Previous / Next controls.