gracefully surface FetchErrors
Signed-off-by: Jamie Klassen <jklassen@vmware.com>
This commit is contained in:
@@ -184,14 +184,7 @@ export type KubernetesErrorTypes =
|
||||
| 'UNKNOWN_ERROR';
|
||||
|
||||
// @public (undocumented)
|
||||
export interface KubernetesFetchError {
|
||||
// (undocumented)
|
||||
errorType: KubernetesErrorTypes;
|
||||
// (undocumented)
|
||||
resourcePath?: string;
|
||||
// (undocumented)
|
||||
statusCode?: number;
|
||||
}
|
||||
export type KubernetesFetchError = StatusError | RawFetchError;
|
||||
|
||||
// @public (undocumented)
|
||||
export interface KubernetesRequestAuth {
|
||||
@@ -241,6 +234,14 @@ export interface PodStatusFetchResponse {
|
||||
type: 'podstatus';
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export interface RawFetchError {
|
||||
// (undocumented)
|
||||
errorType: 'FETCH_ERROR';
|
||||
// (undocumented)
|
||||
message: string;
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export interface ReplicaSetsFetchResponse {
|
||||
// (undocumented)
|
||||
@@ -265,6 +266,16 @@ export interface StatefulSetsFetchResponse {
|
||||
type: 'statefulsets';
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export interface StatusError {
|
||||
// (undocumented)
|
||||
errorType: KubernetesErrorTypes;
|
||||
// (undocumented)
|
||||
resourcePath?: string;
|
||||
// (undocumented)
|
||||
statusCode?: number;
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export interface WorkloadsByEntityRequest {
|
||||
// (undocumented)
|
||||
|
||||
@@ -223,12 +223,21 @@ export interface PodStatusFetchResponse {
|
||||
}
|
||||
|
||||
/** @public */
|
||||
export interface KubernetesFetchError {
|
||||
export type KubernetesFetchError = StatusError | RawFetchError;
|
||||
|
||||
/** @public */
|
||||
export interface StatusError {
|
||||
errorType: KubernetesErrorTypes;
|
||||
statusCode?: number;
|
||||
resourcePath?: string;
|
||||
}
|
||||
|
||||
/** @public */
|
||||
export interface RawFetchError {
|
||||
errorType: 'FETCH_ERROR';
|
||||
message: string;
|
||||
}
|
||||
|
||||
/** @public */
|
||||
export type KubernetesErrorTypes =
|
||||
| 'BAD_REQUEST'
|
||||
|
||||
Reference in New Issue
Block a user