6public static class ExceptionFactory
10 var msg = $
"{f.StatusCode} ({f.ErrorCode}): {f.Message}{(f.Summary is { Length: > 0 } ? "\n---\n
" + f.Summary : "")}";
12 return f.ErrorCode
switch
20 "invalid_function_definition" or
21 "invalid_identifier" or
36 public static Exception FromRawResponse(
string body, HttpResponseMessage r)
38 if (r.StatusCode is >= HttpStatusCode.OK and <= (HttpStatusCode)299)
44 return r.StatusCode
switch
46 HttpStatusCode.TooManyRequests =>
new ThrottlingException($
"{r.StatusCode}: {r.ReasonPhrase ?? "Too many requests.
"}"),
Represents an exception that occurs when the FQL abort function is called. This exception captures th...
Represents an exception thrown for a bad gateway. Corresponds to the 'bad_gateway' error code in Faun...
Represents an exception that occurs when a transaction is aborted due to concurrent modification....
Represents the base exception class for all exceptions specific to Fauna interactions.
Represents an exception thrown when access to a resource is not allowed. Corresponds to the 'forbidde...
Represents exceptions caused by invalid requests to Fauna.
Represents exceptions when a response does not match the wire protocol.
Represents exceptions thrown when the query has syntax errors.
Represents exceptions thrown when the query fails at runtime.
Represents exceptions thrown when the query execution time exceeds the specified or default timeout p...
Represents an exception related to Fauna service errors, particularly for query failures.
Represents an exception that indicates some capacity limit was exceeded and thus the request could no...
Represents exceptions thrown when the query execution time exceeds the specified or default timeout p...
Represents an exception thrown when there is an authorization error in Fauna. Corresponds to the 'una...
Represents a failed query response.