Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ConnectionError = errorType(errors.New("connection error")) ReadError = errorType(errors.New("read error")) ExecutionError = errorType(errors.New("execution error")) InvalidInputError = errorType(errors.New("invalid input")) InvalidPlanError = errorType(errors.New("invalid plan")) RetriesExceeded = errorType(errors.New("retries exceeded")) InvalidServerSideSessionError = errorType(errors.New("invalid server side session")) TestSetupError = errorType(errors.New("test setup error")) WriteError = errorType(errors.New("write error")) NotImplementedError = errorType(errors.New("not implemented")) InvalidArgumentError = errorType(errors.New("invalid argument")) )
Functions ¶
func WithString ¶
Types ¶
type InvalidServerSideSessionDetailsError ¶
func (InvalidServerSideSessionDetailsError) Error ¶
func (e InvalidServerSideSessionDetailsError) Error() string
type SparkError ¶
type SparkError struct { // SqlState is the SQL state of the error. SqlState string // ErrorClass is the class of the error. ErrorClass string // If set is typically the classname throwing the error on the Spark side. Reason string // Message is the human-readable message of the error. Message string // Code is the gRPC status code of the error. Code codes.Code // ErrorId is the unique id of the error. It can be used to fetch more details about // the error using an additional RPC from the server. ErrorId string // Parameters are the parameters that are used to format the error message. Parameters map[string]string // contains filtered or unexported fields }
SparkError represents an error that is returned from Spark itself. It captures details of the error that allows better understanding about the error. This allows us to check if the error can be retried or not.
func FromRPCError ¶
func FromRPCError(e error) *SparkError
FromRPCError converts a gRPC error to a SparkError. If the error is not a gRPC error, it will create a plain "UNKNOWN" GRPC status type. If no error was observed returns nil.
func (SparkError) Error ¶
func (e SparkError) Error() string
type UnsupportedResponseTypeError ¶
type UnsupportedResponseTypeError struct {
ResponseType interface{}
}
func (UnsupportedResponseTypeError) Error ¶
func (e UnsupportedResponseTypeError) Error() string
Click to show internal directories.
Click to hide internal directories.