1import type * as emr from "@distilled.cloud/aws/emr-serverless";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { Application } from "./Application.ts";
5
6/**
7 * Request accepted by the {@link ListJobRunAttempts} runtime callable. The
8 * `applicationId` is injected from the bound {@link Application}.
9 */
10export type ListJobRunAttemptsInput = Omit<
11 emr.ListJobRunAttemptsRequest,
12 "applicationId"
13>;
14
15/**
16 * Runtime binding for `emr-serverless:ListJobRunAttempts`.
17 *
18 * Enumerates the attempts of a retried job run on the bound
19 * {@link Application} — how many times the retry policy re-ran the job and
20 * how each attempt ended. Provide the implementation with
21 * `Effect.provide(AWS.EMRServerless.ListJobRunAttemptsHttp)`.
22 * ### Running Jobs
23 * **Example:** Inspect A Job's Attempts
24 * ```typescript
25 * // init
26 * const listJobRunAttempts = yield* AWS.EMRServerless.ListJobRunAttempts(app);
27 *
28 * // runtime
29 * const { jobRunAttempts } = yield* listJobRunAttempts({ jobRunId });
30 * ```
31 *
32 * @binding
33 */
34export interface ListJobRunAttempts extends Binding.Service<
35 ListJobRunAttempts,
36 "AWS.EMRServerless.ListJobRunAttempts",
37 (
38 application: Application,
39 ) => Effect.Effect<
40 (
41 request: ListJobRunAttemptsInput,
42 ) => Effect.Effect<
43 emr.ListJobRunAttemptsResponse,
44 emr.ListJobRunAttemptsError
45 >
46 >
47> {}
48export const ListJobRunAttempts = Binding.Service<ListJobRunAttempts>(
49 "AWS.EMRServerless.ListJobRunAttempts",
50);