gravitino.exceptions.handlers.error_handler.ErrorHandler¶
- class gravitino.exceptions.handlers.error_handler.ErrorHandler¶
Bases:
ABC
The ErrorHandler class is an abstract class specialized for handling ErrorResponse objects. Subclasses of ErrorHandler must implement the parseResponse method to provide custom parsing logic for different types of errors.
- __init__()¶
Methods
- abstract handle(error_response: ErrorResponse)¶
Handles the error response and raise the appropriate Exception. The implementation will use the provided error response to determine which exception to raise.
- Args:
error_response: the error response from the server
- Raises:
appropriate Exception.