{ "suite": "lab5-pipeline-idempotency", "started_at": "2026-11-06T06:32:05.201079Z", "source_sha": "e9ce6d0afacadc16f1666f4bb7d54d3d7377a269", "config": { "base_url": "http://127.0.0.1:18085", "level": 4, "only": "", "expect_variants": "thumbnail,crop,optimized", "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": 33 } }, { "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": 33 } }, { "id": "monotonic_publication", "statement": "published_version only moves forward", "result": "PASS", "details": { "sampled": 8 } }, { "id": "bytes_match_metadata", "statement": "sha256, size and real dimensions match served bytes", "result": "PASS", "details": { "verified": 28 } }, { "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": [ 3, 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": 33 } } ], "scenarios": [ { "name": "smoke_pipeline", "level": 3, "window": "upload, ready, variants match metadata", "seconds": 1.3, "result": "PASS", "observed": { "attachment_id": "01a1af8e-c731-7496-9b9c-3ba203dc2044", "variants": [ "crop", "optimized", "thumbnail" ] } }, { "name": "worker_down_broker_restart", "level": 3, "window": "worker down, API and broker restart", "seconds": 17.9, "result": "PASS", "observed": { "attachment_id": "01a1af8e-ce96-717e-ae7a-3697c35584a1", "timeline": [ { "at": "2026-11-06T06:32:14.222987Z", "step": "worker stopped", "containers": [ "mtusi2026lab5-worker-1 ae030b9f2a03 exited Exited (0) Less than a second ago" ] }, { "at": "2026-11-06T06:32:14.242129Z", "step": "upload 202 queued", "attachment_id": "01a1af8e-ce96-717e-ae7a-3697c35584a1" }, { "at": "2026-11-06T06:32:14.250444Z", "step": "content 409 while queued" }, { "at": "2026-11-06T06:32:14.267670Z", "step": "message with attachment 201, other messages work", "message_id": "01a1af8e-ceab-72eb-a93d-814d75f8e89c" }, { "at": "2026-11-06T06:32:17.729590Z", "step": "job is in the broker queue", "queues": { "attachments.process": [ 1, 0 ], "attachments.process.dlq": [ 2, 0 ] } }, { "at": "2026-11-06T06:32:23.261545Z", "step": "API replicas and relay restarted" }, { "at": "2026-11-06T06:32:28.594571Z", "step": "broker restarted with its volume, job survived", "queues": { "attachments.process": [ 1, 0 ], "attachments.process.dlq": [ 2, 0 ] } }, { "at": "2026-11-06T06:32:31.363642Z", "step": "worker started" }, { "at": "2026-11-06T06:32:31.561755Z", "step": "ready", "variants": [ "crop", "optimized", "thumbnail" ] } ] } }, { "name": "duplicate_after_ready", "level": 3, "window": "redelivery of a finished job", "seconds": 9.6, "result": "PASS", "observed": { "attachment_id": "01a1af8f-124f-73f5-b597-712b6fa2a653", "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": 11.7, "result": "PASS", "observed": { "attachment_id": "01a1af8f-398b-75d1-b01d-bc3c2181c62f", "jobs": [ { "job_id": "01a1af8f-3991-7162-9a1d-af82b69fc7a6", "pipeline_version": 1, "status": "done", "attempt": 2 } ] } }, { "name": "retry_exhausted", "level": 3, "window": "transient error until JOB_MAX_ATTEMPTS", "seconds": 21.6, "result": "PASS", "observed": { "attachment_id": "01a1af8f-740f-706e-9bff-9299abc71639", "jobs": [ { "job_id": "01a1af8f-7420-7585-afcc-2c1145abf968", "pipeline_version": 1, "status": "failed", "attempt": 5 } ] } }, { "name": "image_matrix", "level": 4, "window": "limits and variants", "seconds": 11.6, "result": "PASS", "observed": { "images": [ { "file": "png-rgb-320x200.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-rgba-300x300.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-palette-trns-200x100.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-gray-17x1000.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-gray-alpha-640x480.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-gray16-300x200.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-rgba16-64x64.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-1x1.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-wide-3000x2.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-small-50x30.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "jpeg-rgb-1000x750.jpg", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "jpeg-gray-801x601.jpg", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "jpeg-cmyk-400x300.jpg", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "jpeg-exif6-400x200.jpg", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "jpeg-exif3-300x200.jpg", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "jpeg-rgb-4000x3000.jpg", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-exactly-10mib.png", "http": 202, "status": "ready", "error_code": null, "variants": [ "crop", "optimized", "thumbnail" ] }, { "file": "png-over-10mib.png", "http": "rejected" }, { "file": "png-over-pixels-8001x5000.png", "http": "rejected" }, { "file": "jpeg-over-pixels-10000x5000.jpg", "http": "rejected" }, { "file": "png-truncated.png", "http": "rejected" }, { "file": "png-corrupt-idat.png", "http": "rejected" }, { "file": "jpeg-truncated.jpg", "http": "rejected" }, { "file": "png-zero-width.png", "http": "rejected" }, { "file": "not-an-image.png", "http": "rejected" }, { "file": "gif-declared-as-png.png", "http": "rejected" } ] } }, { "name": "crash_commit_publish", "level": 4, "window": "after COMMIT, before publish", "seconds": 9.6, "result": "PASS", "observed": { "attachment_id": "01a1af8f-f5a0-77a3-b9de-5f042375ee62", "exit_code": 137, "after_crash": { "outbox_published": false, "status": "queued", "containers": [ "mtusi2026lab5-relay-1 9e463d46fefb exited Exited (137) 1 second ago" ] }, "variants": [ { "pipeline_version": 1, "name": "crop", "sha256": "97bf1400b30a28c19420a30161c944f57b5e7d613533b76afe6ab2531cba0143", "size_bytes": 1820, "object_key": "variants/01a1af8f-f5a0-77a3-b9de-5f042375ee62/1/crop-97bf1400b30a28c1.jpg" }, { "pipeline_version": 1, "name": "optimized", "sha256": "1090d84ed8411226010ae498b08e1b9e6d81c8eee02ee77143a0dc327b894beb", "size_bytes": 2462, "object_key": "variants/01a1af8f-f5a0-77a3-b9de-5f042375ee62/1/optimized-1090d84ed8411226.webp" }, { "pipeline_version": 1, "name": "thumbnail", "sha256": "7bc40bf315c8e18e907889b23514d978be213a44223d64b737290188ee808594", "size_bytes": 4679, "object_key": "variants/01a1af8f-f5a0-77a3-b9de-5f042375ee62/1/thumbnail-7bc40bf315c8e18e.jpg" } ] } }, { "name": "crash_publish_confirm", "level": 4, "window": "after publish, before confirm", "seconds": 9.4, "result": "PASS", "observed": { "attachment_id": "01a1af90-1b12-778c-95ca-51919e8527eb", "exit_code": 137, "after_crash": { "outbox_published": [ false ], "queues": { "attachments.process": [ 0, 0 ], "attachments.process.dlq": [ 2, 0 ] }, "containers": [ "mtusi2026lab5-relay-1 d356228ef442 exited Exited (137) 1 second ago" ] }, "variants": [ { "pipeline_version": 1, "name": "crop", "sha256": "97bf1400b30a28c19420a30161c944f57b5e7d613533b76afe6ab2531cba0143", "size_bytes": 1820, "object_key": "variants/01a1af90-1b12-778c-95ca-51919e8527eb/1/crop-97bf1400b30a28c1.jpg" }, { "pipeline_version": 1, "name": "optimized", "sha256": "1090d84ed8411226010ae498b08e1b9e6d81c8eee02ee77143a0dc327b894beb", "size_bytes": 2462, "object_key": "variants/01a1af90-1b12-778c-95ca-51919e8527eb/1/optimized-1090d84ed8411226.webp" }, { "pipeline_version": 1, "name": "thumbnail", "sha256": "7bc40bf315c8e18e907889b23514d978be213a44223d64b737290188ee808594", "size_bytes": 4679, "object_key": "variants/01a1af90-1b12-778c-95ca-51919e8527eb/1/thumbnail-7bc40bf315c8e18e.jpg" } ], "events": [ "enqueued", "claimed", "done", "duplicate_noop" ] } }, { "name": "crash_after_s3_before_commit", "level": 4, "window": "after S3 write, before COMMIT", "seconds": 11.6, "result": "PASS", "observed": { "attachment_id": "01a1af90-3f75-7321-8fcc-dcfcb79fe63f", "exit_code": 137, "after_crash": { "status": "processing", "variant_rows": 0, "containers": [ "mtusi2026lab5-worker-1 6ab14be0b64a exited Exited (137) Less than a second ago" ] }, "variants": [ { "pipeline_version": 1, "name": "crop", "sha256": "97bf1400b30a28c19420a30161c944f57b5e7d613533b76afe6ab2531cba0143", "size_bytes": 1820, "object_key": "variants/01a1af90-3f75-7321-8fcc-dcfcb79fe63f/1/crop-97bf1400b30a28c1.jpg" }, { "pipeline_version": 1, "name": "optimized", "sha256": "1090d84ed8411226010ae498b08e1b9e6d81c8eee02ee77143a0dc327b894beb", "size_bytes": 2462, "object_key": "variants/01a1af90-3f75-7321-8fcc-dcfcb79fe63f/1/optimized-1090d84ed8411226.webp" }, { "pipeline_version": 1, "name": "thumbnail", "sha256": "7bc40bf315c8e18e907889b23514d978be213a44223d64b737290188ee808594", "size_bytes": 4679, "object_key": "variants/01a1af90-3f75-7321-8fcc-dcfcb79fe63f/1/thumbnail-7bc40bf315c8e18e.jpg" } ] } }, { "name": "crash_after_commit_before_ack", "level": 4, "window": "after COMMIT, before ack", "seconds": 10.7, "result": "PASS", "observed": { "attachment_id": "01a1af90-6ce1-71d3-bbcf-9f22d40268ea", "exit_code": 137, "after_crash": { "status": "ready", "variants": [ { "pipeline_version": 1, "name": "crop", "sha256": "97bf1400b30a28c19420a30161c944f57b5e7d613533b76afe6ab2531cba0143", "size_bytes": 1820, "object_key": "variants/01a1af90-6ce1-71d3-bbcf-9f22d40268ea/1/crop-97bf1400b30a28c1.jpg" }, { "pipeline_version": 1, "name": "optimized", "sha256": "1090d84ed8411226010ae498b08e1b9e6d81c8eee02ee77143a0dc327b894beb", "size_bytes": 2462, "object_key": "variants/01a1af90-6ce1-71d3-bbcf-9f22d40268ea/1/optimized-1090d84ed8411226.webp" }, { "pipeline_version": 1, "name": "thumbnail", "sha256": "7bc40bf315c8e18e907889b23514d978be213a44223d64b737290188ee808594", "size_bytes": 4679, "object_key": "variants/01a1af90-6ce1-71d3-bbcf-9f22d40268ea/1/thumbnail-7bc40bf315c8e18e.jpg" } ], "queues": { "attachments.process": [ 1, 0 ], "attachments.process.dlq": [ 2, 0 ] }, "containers": [ "mtusi2026lab5-worker-1 e200bf97bb1a exited Exited (137) 2 seconds ago" ] }, "variants": [ { "pipeline_version": 1, "name": "crop", "sha256": "97bf1400b30a28c19420a30161c944f57b5e7d613533b76afe6ab2531cba0143", "size_bytes": 1820, "object_key": "variants/01a1af90-6ce1-71d3-bbcf-9f22d40268ea/1/crop-97bf1400b30a28c1.jpg" }, { "pipeline_version": 1, "name": "optimized", "sha256": "1090d84ed8411226010ae498b08e1b9e6d81c8eee02ee77143a0dc327b894beb", "size_bytes": 2462, "object_key": "variants/01a1af90-6ce1-71d3-bbcf-9f22d40268ea/1/optimized-1090d84ed8411226.webp" }, { "pipeline_version": 1, "name": "thumbnail", "sha256": "7bc40bf315c8e18e907889b23514d978be213a44223d64b737290188ee808594", "size_bytes": 4679, "object_key": "variants/01a1af90-6ce1-71d3-bbcf-9f22d40268ea/1/thumbnail-7bc40bf315c8e18e.jpg" } ] } }, { "name": "lease_expiry_fencing", "level": 4, "window": "stalled worker, lease expiry", "seconds": 32.9, "result": "PASS", "observed": { "attachment_id": "01a1af90-96cc-70cf-981a-6fa959f4ba60", "jobs": [ { "job_id": "01a1af90-96d1-7586-935a-e6432c5b8d8f", "pipeline_version": 1, "status": "done", "attempt": 2 } ], "events": [ { "kind": "enqueued", "attempt": 1 }, { "kind": "claimed", "attempt": 1 }, { "kind": "lease_expired", "attempt": 2 }, { "kind": "claimed", "attempt": 2 }, { "kind": "done", "attempt": 2 }, { "kind": "fenced", "attempt": 1 } ] } }, { "name": "replay_failed", "level": 4, "window": "operator replay", "seconds": 22.9, "result": "PASS", "observed": { "attachment_id": "01a1af91-1737-725c-97b2-5ee24b21e583", "replay": { "result": "replayed", "attachment_id": "01a1af91-1737-725c-97b2-5ee24b21e583", "operator": "cli" }, "replay_of_ready": { "result": "noop", "attachment_id": "01a1af91-1737-725c-97b2-5ee24b21e583", "operator": "cli" }, "events": [ { "kind": "enqueued", "attempt": 1 }, { "kind": "claimed", "attempt": 1 }, { "kind": "retry_scheduled", "attempt": 2 }, { "kind": "claimed", "attempt": 2 }, { "kind": "retry_scheduled", "attempt": 3 }, { "kind": "claimed", "attempt": 3 }, { "kind": "retry_scheduled", "attempt": 4 }, { "kind": "claimed", "attempt": 4 }, { "kind": "retry_scheduled", "attempt": 5 }, { "kind": "claimed", "attempt": 5 }, { "kind": "failed", "attempt": 5 }, { "kind": "replayed", "attempt": 1 }, { "kind": "claimed", "attempt": 1 }, { "kind": "done", "attempt": 1 }, { "kind": "replay_noop", "attempt": 1 } ] } }, { "name": "malformed_message_dead_lettered", "level": 4, "window": "message that is not a job goes to the DLQ", "seconds": 4.5, "result": "PASS", "observed": { "dead_letters": 1 } }, { "name": "worker_limits", "level": 4, "window": "render time and memory limits, 40 Mpx in the worker limit", "seconds": 15.2, "result": "PASS", "observed": { "image": { "file": "png-at-pixel-limit-8000x5000.png", "bytes": 116714, "pixels": 40000000 }, "render_timeout": { "seconds": 0.5, "attachment_id": "01a1af91-8333-7076-a13d-2c2554675dec", "error_code": "processing_failed", "worker": "running" }, "render_memory": { "mib": 200, "attachment_id": "01a1af91-959f-74b5-a91f-8faeb29ff5cb", "error_code": "processing_failed", "worker": "running" }, "default_limits": { "attachment_id": "01a1af91-a7b5-75b5-9c9a-d9bd93471cbd", "variants": [ "crop", "optimized", "thumbnail" ], "memory_peak_mib": 423.0, "memory_max_mib": 1024.0 } } }, { "name": "retry_backoff_jitter", "level": 4, "window": "backoff with equal jitter between attempts", "seconds": 23.3, "result": "PASS", "observed": { "attachment_id": "01a1af91-d0a0-729b-bde2-9297b7a08432", "delays": [ { "attempt": 2, "delay": 0.504226 }, { "attempt": 3, "delay": 1.141266 }, { "attempt": 4, "delay": 2.690642 }, { "attempt": 5, "delay": 4.626198 } ], "share_of_ceiling": [ 0.504, 0.571, 0.673, 0.578 ], "jobs": [ { "job_id": "01a1af91-d0a8-7541-acac-547a45ac3ab3", "pipeline_version": 1, "status": "failed", "attempt": 5 } ] } }, { "name": "failed_retention", "level": 4, "window": "failed staging kept until retention, then replay expires", "seconds": 20.8, "result": "PASS", "observed": { "attachment_id": "01a1af92-1887-72c6-9c2d-4f0e41975501", "staging_before": "kept", "retention_seconds": 86400, "aged_only": "01a1af92-1887-72c6-9c2d-4f0e41975501", "replay": { "result": "expired", "attachment_id": "01a1af92-1887-72c6-9c2d-4f0e41975501", "operator": "cli" } } } ], "result": "PASS", "finished_at": "2026-11-06T06:36:13.028956Z" }