Package org.a2aproject.sdk.spec
Class InternalError
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.a2aproject.sdk.spec.A2AError
org.a2aproject.sdk.spec.InternalError
- All Implemented Interfaces:
Serializable,Event
JSON-RPC error indicating an internal error occurred on the server.
This error represents unexpected server-side failures such as unhandled exceptions, resource exhaustion, or other internal issues that prevent the server from processing a request. This is a catch-all error for server problems not covered by more specific error types.
Corresponds to JSON-RPC 2.0 error code -32603.
Usage example:
try {
// Server processing
} catch (Exception e) {
throw new InternalError("Failed to process request: " + e.getMessage());
}
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionInternalError(@Nullable Integer code, @Nullable String message, @Nullable Map<String, Object> details) Constructs an internal error with full parameters.InternalError(@Nullable String message) Constructs an internal error with a message. -
Method Summary
Methods inherited from class org.a2aproject.sdk.spec.A2AError
getCode, getDetailsMethods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
InternalError
public InternalError(@Nullable Integer code, @Nullable String message, @Nullable Map<String, Object> details) Constructs an internal error with full parameters.- Parameters:
code- the error codemessage- the error messagedetails- additional error details
-
InternalError
Constructs an internal error with a message.- Parameters:
message- the error message
-