Daniel Sosinskiy
← Back to Engineering Stories Production troubleshooting / Conbo

Tracing request errors

I traced production requests that timed out with 504 Gateway Timeout errors or were rejected with 413 Payload Too Large errors. I resolved the failure paths through PostgreSQL indexing and partition-aware query rewrites, server-side aggregation, connection-pool tuning, HTTP keep-alive, and splitting large requests into smaller chunks.

At a glance

My role · I investigated and resolved these failure paths across service boundaries. The work was part of a larger product and team environment.

Context · Professional work, with company details generalized.

Context

The platform combines multiple microservices and data flows within them. A failing request could surface at a boundary far from its underlying cause.

The Problem

Production paths returned timeouts, payload errors, bad requests and other 4xx/5xx responses. The failures needed to be traced through database queries, connection handling, and request size.

Technical Approach

  • Inspected application logs from services running in Kubernetes and used OpenTelemetry data to investigate where requests were failing across service boundaries.
  • Changed PostgreSQL indexes and rewrote partition-aware queries.
  • Moved aggregation to the server where appropriate and adjusted connection-pool behavior.
  • Applied HTTP keep-alive and chunked larger requests, including handling per-chunk 413 responses.

Generalized process

  1. Failing request
  2. Trace service path
  3. Inspect query and payload
  4. Change bottleneck
  5. Verify failure path

Decisions and Tradeoffs

Fix the path causing the symptom

The work addressed query scans, connections, and request handling rather than treating the HTTP status alone.

Bound payload size

Chunking prevented one oversized aggregation request from being the only delivery path.

Alternative to revisit

Different pagination or asynchronous processing models could be considered for a changed workload. Those alternatives are not presented as completed work.

Outcome

The documented failures were resolved. Exact latency gains and business outcomes are not confirmed.

Reflection

I would keep the request boundaries, query plans, and production signals visible so similar failures are easier to isolate.

Technologies

  • PostgreSQL
  • TypeORM
  • HTTP
  • NestJS

Links

No public repository or live demo is available for this professional work.

© 2026 Daniel SosinskiyIsrael