Verify lab 5 grade 3 on the SQLAlchemy stack
This commit is contained in:
@@ -0,0 +1,262 @@
|
||||
{
|
||||
"suite": "lab5-pipeline-idempotency",
|
||||
"started_at": "2026-11-06T06:23:25.494818Z",
|
||||
"source_sha": "24a51744f521aa585e50a931d0a0219d2e960197",
|
||||
"config": {
|
||||
"base_url": "http://127.0.0.1:18085",
|
||||
"level": 3,
|
||||
"only": "",
|
||||
"expect_variants": "thumbnail",
|
||||
"max_attempts": 5,
|
||||
"stall_seconds": 15.0,
|
||||
"compose": "docker compose",
|
||||
"compose_faults": "docker compose -f compose.yaml -f infra/compose.faults.yaml"
|
||||
},
|
||||
"invariants": [
|
||||
{
|
||||
"id": "terminal",
|
||||
"statement": "every 202 reaches its expected terminal state",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"accepted": 5
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "single_effect",
|
||||
"statement": "one variant set per (attachment_id, pipeline_version, variant)",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"rows": 0
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "no_ready_rollback",
|
||||
"statement": "ready never returns to queued or processing",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"traced": 5
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "monotonic_publication",
|
||||
"statement": "published_version only moves forward",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"sampled": 2
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "bytes_match_metadata",
|
||||
"statement": "sha256, size and real dimensions match served bytes",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"verified": 4
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "bounded_attempts",
|
||||
"statement": "attempt <= JOB_MAX_ATTEMPTS",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"rows": 0
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "no_orphans",
|
||||
"statement": "no pending outbox, messages, dead letters, staging, objects",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"queues": {
|
||||
"attachments.process": [
|
||||
0,
|
||||
0
|
||||
],
|
||||
"attachments.process.dlq": [
|
||||
2,
|
||||
0
|
||||
]
|
||||
},
|
||||
"s3": "SKIP: --s3-list is not set"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "no_lost_202",
|
||||
"statement": "every 202 is present in PostgreSQL and the API",
|
||||
"result": "PASS",
|
||||
"details": {
|
||||
"accepted": 5
|
||||
}
|
||||
}
|
||||
],
|
||||
"scenarios": [
|
||||
{
|
||||
"name": "smoke_pipeline",
|
||||
"level": 3,
|
||||
"window": "upload, ready, variants match metadata",
|
||||
"seconds": 1.1,
|
||||
"result": "PASS",
|
||||
"observed": {
|
||||
"attachment_id": "01a1af86-d946-7430-b880-50e83365cc3b",
|
||||
"variants": [
|
||||
"crop",
|
||||
"optimized",
|
||||
"thumbnail"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "worker_down_broker_restart",
|
||||
"level": 3,
|
||||
"window": "worker down, API and broker restart",
|
||||
"seconds": 18.1,
|
||||
"result": "PASS",
|
||||
"observed": {
|
||||
"attachment_id": "01a1af86-df76-7373-bfc9-a61cab48c057",
|
||||
"timeline": [
|
||||
{
|
||||
"at": "2026-11-06T06:23:34.259578Z",
|
||||
"step": "worker stopped",
|
||||
"containers": [
|
||||
"mtusi2026lab5-worker-1 7abe06a90131 exited Exited (0) Less than a second ago"
|
||||
]
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:34.272201Z",
|
||||
"step": "upload 202 queued",
|
||||
"attachment_id": "01a1af86-df76-7373-bfc9-a61cab48c057"
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:34.275625Z",
|
||||
"step": "content 409 while queued"
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:34.298319Z",
|
||||
"step": "message with attachment 201, other messages work",
|
||||
"message_id": "01a1af86-df86-7291-81ae-a2466e7bb0e0"
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:37.853670Z",
|
||||
"step": "job is in the broker queue",
|
||||
"queues": {
|
||||
"attachments.process": [
|
||||
1,
|
||||
0
|
||||
],
|
||||
"attachments.process.dlq": [
|
||||
2,
|
||||
0
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:43.392966Z",
|
||||
"step": "API replicas and relay restarted"
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:48.742701Z",
|
||||
"step": "broker restarted with its volume, job survived",
|
||||
"queues": {
|
||||
"attachments.process": [
|
||||
1,
|
||||
0
|
||||
],
|
||||
"attachments.process.dlq": [
|
||||
2,
|
||||
0
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:51.511587Z",
|
||||
"step": "worker started"
|
||||
},
|
||||
{
|
||||
"at": "2026-11-06T06:23:51.742234Z",
|
||||
"step": "ready",
|
||||
"variants": [
|
||||
"crop",
|
||||
"optimized",
|
||||
"thumbnail"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "duplicate_after_ready",
|
||||
"level": 3,
|
||||
"window": "redelivery of a finished job",
|
||||
"seconds": 4.5,
|
||||
"result": "PASS",
|
||||
"observed": {
|
||||
"attachment_id": "01a1af87-23c5-7039-a066-c398a93ffd44",
|
||||
"events": [
|
||||
{
|
||||
"kind": "enqueued",
|
||||
"attempt": 1
|
||||
},
|
||||
{
|
||||
"kind": "claimed",
|
||||
"attempt": 1
|
||||
},
|
||||
{
|
||||
"kind": "done",
|
||||
"attempt": 1
|
||||
},
|
||||
{
|
||||
"kind": "duplicate_noop",
|
||||
"attempt": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "poison_image",
|
||||
"level": 3,
|
||||
"window": "permanent error without retries",
|
||||
"seconds": 0.0,
|
||||
"result": "PASS",
|
||||
"observed": {
|
||||
"rejected_by_api": 415
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "s3_outage_recovers",
|
||||
"level": 3,
|
||||
"window": "transient error with retry",
|
||||
"seconds": 10.8,
|
||||
"result": "PASS",
|
||||
"observed": {
|
||||
"attachment_id": "01a1af87-36c1-7796-895d-14b5a173aa3c",
|
||||
"jobs": [
|
||||
{
|
||||
"job_id": "01a1af87-36ca-75b7-9fdd-5aecff44e910",
|
||||
"pipeline_version": 1,
|
||||
"status": "done",
|
||||
"attempt": 2
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "retry_exhausted",
|
||||
"level": 3,
|
||||
"window": "transient error until JOB_MAX_ATTEMPTS",
|
||||
"seconds": 17.5,
|
||||
"result": "PASS",
|
||||
"observed": {
|
||||
"attachment_id": "01a1af87-6e4f-7545-b41c-d24276837287",
|
||||
"jobs": [
|
||||
{
|
||||
"job_id": "01a1af87-6e5b-72ee-bb7a-a4a6d632c34b",
|
||||
"pipeline_version": 1,
|
||||
"status": "failed",
|
||||
"attempt": 5
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"result": "PASS",
|
||||
"finished_at": "2026-11-06T06:24:30.137680Z"
|
||||
}
|
||||
Reference in New Issue
Block a user