Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type APIError ¶
type APIError struct {
ErrorCode string
Message string
StatusCode int
Details []ErrorDetail
}
APIError is a generic struct for an api error on databricks
func GenericIOError ¶ added in v0.18.0
func GetAPIError ¶ added in v0.18.0
GetAPIError inspects HTTP errors from the Databricks API for known transient errors.
func TooManyRequests ¶ added in v0.18.0
func TooManyRequests() *APIError
func (*APIError) IsRetriable ¶
isRetriable returns true if error is retriable
func (*APIError) IsTooManyRequests ¶
IsTooManyRequests shows rate exceeded limits
type APIErrorBody ¶
type APIErrorBody struct {
ErrorCode string `json:"error_code,omitempty"`
Message string `json:"message,omitempty"`
Details []ErrorDetail `json:"details,omitempty"`
// The following two are for scim api only
// for RFC 7644 Section 3.7.3 https://tools.ietf.org/html/rfc7644#section-3.7.3
ScimDetail string `json:"detail,omitempty"`
ScimStatus string `json:"status,omitempty"`
ScimType string `json:"scimType,omitempty"`
API12Error string `json:"error,omitempty"`
}
APIErrorBody maps "proper" databricks rest api errors to a struct
type ErrorDetail ¶ added in v0.20.0
type ErrorDetail struct {
Type string `json:"@type,omitempty"`
Reason string `json:"reason,omitempty"`
Domain string `json:"domain,omitempty"`
Metadata map[string]string `json:"metadata,omitempty"`
}
func GetErrorInfo ¶ added in v0.20.0
func GetErrorInfo(err error) []ErrorDetail
GetErrorInfo returns all entries in the list of error details of type `ErrorInfo`.
Click to show internal directories.
Click to hide internal directories.