Dwi Siswanto 1fe2ce2532
feat: cache the bin (#8)
* feat: cache the bin

Signed-off-by: Dwi Siswanto <me@dw1.io>

* feat: print error while get cache

Signed-off-by: Dwi Siswanto <me@dw1.io>

---------

Signed-off-by: Dwi Siswanto <me@dw1.io>
2024-03-22 00:19:33 +07:00

9 lines
933 B
TypeScript

import { HttpClientResponse } from '@actions/http-client';
import { ITypedResponseWithError } from './contracts';
export declare function isSuccessStatusCode(statusCode?: number): boolean;
export declare function isServerErrorStatusCode(statusCode?: number): boolean;
export declare function isRetryableStatusCode(statusCode?: number): boolean;
export declare function retry<T>(name: string, method: () => Promise<T>, getStatusCode: (arg0: T) => number | undefined, maxAttempts?: number, delay?: number, onError?: ((arg0: Error) => T | undefined) | undefined): Promise<T>;
export declare function retryTypedResponse<T>(name: string, method: () => Promise<ITypedResponseWithError<T>>, maxAttempts?: number, delay?: number): Promise<ITypedResponseWithError<T>>;
export declare function retryHttpClientResponse(name: string, method: () => Promise<HttpClientResponse>, maxAttempts?: number, delay?: number): Promise<HttpClientResponse>;