A Python workflow writes output to a log file while also uploading artifacts to a bucket. If the upload occasionally hangs, which design most directly improves observability and prevents indefinite blocking?

Answer

Use timeouts for network operations, structured logging (including correlation IDs), and emit progress/heartbeat metrics

Explanation

Timeouts bound failure modes, while structured logging and correlation IDs make it possible to trace the exact stage that hung. Heartbeats and progress metrics reveal liveness during long operations.

Last reviewed: October 2026

Reviewed by FirstInTest Editorial Team

Report an error

Related questions

QuestionBack to list