TimeoutError
org.llm4s.error.TimeoutError
final case class TimeoutError(message: String, timeoutDuration: Duration, operation: String, cause: Option[Throwable], context: Map[String, String]) extends LLMError, RecoverableError
Raised when an operation exceeds its specified time limit.
Represents operations that timed out. As a RecoverableError, these can potentially succeed with a different timeout, or by retrying with exponential backoff strategies, assuming the service was temporarily slow.
Value parameters
- cause
-
optional underlying exception
- context
-
additional key-value context for debugging
- message
-
human-readable error description
- operation
-
the operation that timed out (e.g., "api-call", "completion")
- timeoutDuration
-
the timeout duration that was exceeded
Attributes
- Example
-
import scala.concurrent.duration._ val error = TimeoutError("Request timed out", 30.seconds, "api-call") .withContext("endpoint", "https://api.openai.com") - Graph
-
- Supertypes
-
trait RecoverableErrortrait LLMErrortrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any
Members list
In this article