Appearance
Detector catalog / Speed
SKEW
Task skew
One slow task holds a whole stage back while the rest of the cluster waits.
- Outcome
- Speed
- Scope
- Judged per stage
- Usual fix
- A change in the job code
- CI gate
- Budget flag
--max-skew
An example finding
Where you see it
Dashboard
The SKEW tag marks it in the action region of the dashboard, among the widgets that rank a fix. Every affected stage is flagged, not only the worst.How to read it in the findings guide.
Agent (MCP)
An assistant can read this entry with the list_detectors tool and its background with get_finding_documentation. The call and the response below come from a real run of the MCP server.
Call
{
"tool": "list_detectors",
"arguments": {
"type": "skew"
}
}Response
{
"count": 1,
"detectors": [
{
"type": "skew",
"name": "task skew",
"tag": "SKEW",
"tagSharedWith": [],
"family": "speed",
"pitch": "One slow task holds a whole stage back while the rest of the cluster waits.",
"region": "action",
"scope": "stage",
"fixEffort": "code",
"thresholdSummary": "P95 task time over 3× the median (the longest task on stages under 20 tasks), and the slow tasks read correspondingly more data",
"detectors": [
{
"detector": "skew",
"version": 1,
"thresholds": {
"ratioWarn": 3,
"minTasksForP95": 20,
"dataShareMin": 0.5,
"floorPctWarn": 0.005
}
}
],
"pages": {
"catalog": "docs/detectors/skew.html",
"guide": "docs/user-guide/understanding-findings.html#skew"
},
"tuning": {
"kind": "page",
"anchor": "#bottleneck-skew",
"path": "docs/tuning-reference/bottleneck-skew.html#bottleneck-skew"
},
"gate": {
"cliFlag": "--max-skew",
"airflowParam": "max_skew_ratio"
}
}
]
}get_finding_documentation call
{
"tool": "get_finding_documentation",
"arguments": {
"type": "skew"
}
}Its response, with each Markdown body replaced by its length
{
"type": "skew",
"name": "Task Skew",
"detectionDoc": {
"tag": "SKEW",
"title": "Task skew",
"content": "<5681 characters of Markdown>"
},
"tuningDoc": {
"anchor": "#bottleneck-skew",
"title": "Task Skew",
"content": "<7179 characters of Markdown>"
}
}CI (CLI)
List this entry from the command line. The output below is a real run of the command. Budgets and exit codes are in the CI guide.
sparkforensics-analyze detectors --type skew --format md# Detectors (1)
## Speed
| Tag | Type | Scope | Fix | Gate | What it finds |
| --- | --- | --- | --- | --- | --- |
| SKEW | `skew` | stage | code | `--max-skew` | One slow task holds a whole stage back while the rest of the cluster waits. |
Report only this finding type for a run with --type:
sparkforensics-analyze <event-log> --type skew --impact critical,warning,infoFail the build when the run breaches a budget for it:
sparkforensics-analyze <event-log> --max-skew <n>Airflow
The operator takes the budget as the max_skew_ratio parameter.
check_spark_job = SparkForensicsOperator(
task_id="check_spark_job",
log_source=...,
backend=SubprocessAnalyzeHook(),
max_skew_ratio=..., # your budget
)The operator works per run, and its summary counts findings per impact band. See the operator for its parameters.
How it is measured
Thresholds
P95 task time over 3× the median (the longest task on stages under 20 tasks), and the slow tasks read correspondingly more data.
skew version 1
| Threshold | Default |
|---|---|
ratioWarn | 3 |
minTasksForP95 | 20 |
dataShareMin | 0.5 |
floorPctWarn | 0.005 |
Each rule's impact bands and fixed fallbacks are in the threshold tables.
Override a default per run with --thresholds; see Tuning detector thresholds.
Docs
- This finding has its own tuning page: Spark tuning reference.
- Findings guide: SKEW in Understanding findings.