Skip to main content
Building reliable applications requires handling network conditions, transient errors, and long-running requests. This guide covers recommended patterns for production use.

Timeout configuration

Set timeouts based on your workload type:

Python SDK

Raw HTTP

Retry logic

Which errors are retryable

Exponential backoff with jitter

OpenAI SDK built-in retry

Handling 429 rate limits

On serverless: Limits scale automatically with sustained usage. For immediate capacity, contact support or switch to a dedicated deployment. On dedicated deployments: Increase concurrency by raising replica counts (for example with firectl deployment update and autoscaling settings). See Autoscaling.

Long-running training jobs

For RL / RFT trainer jobs, use reconnect_and_wait on the job manager to recover from preemption or transient failures. See Trainer job manager for parameters and examples. To preserve optimizer state across interruptions, set dcp_save_interval in your training config. See RFT parameters reference.

The analytics dashboard vs. client-side failures

The Fireworks analytics and usage views count server-acknowledged requests. They do not capture connection errors that occur before a request reaches the server — those appear as failures on the client but may show as zero or reduced traffic in the console. If your client shows failures but the dashboard looks clean, the issue is likely client-side: timeout before connection, DNS resolution failure, or network path problems. Use Exporting metrics for per-deployment Prometheus metrics that reflect what Fireworks infrastructure observed for dedicated deployments.