The best way to control Claude Code, Codex and more from any computer or phone

main
ts 37 lines 1.19 KB
Raw
1 import type * as SVC from "@distilled.cloud/aws/emr";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Cluster } from "./Cluster.ts";
5
6 /**
7 * Runtime binding for `elasticmapreduce:PutAutoScalingPolicy` — attaches a CloudWatch-driven automatic scaling policy to an instance group of the bound cluster.
8 * ### Scaling the Cluster
9 * **Example:** Scale a Task Group on YARN Memory
10 * ```typescript
11 * const putAutoScaling = yield* AWS.EMR.PutAutoScalingPolicy(cluster);
12 *
13 * yield* putAutoScaling({
14 * InstanceGroupId: taskGroupId,
15 * AutoScalingPolicy: {
16 * Constraints: { MinCapacity: 0, MaxCapacity: 8 },
17 * Rules: [], // CloudWatch alarm-driven rules
18 * },
19 * });
20 * ```
21 *
22 * @binding
23 */
24 export interface PutAutoScalingPolicy extends Binding.Service<
25 PutAutoScalingPolicy,
26 "AWS.EMR.PutAutoScalingPolicy",
27 <C extends Cluster>(
28 cluster: C,
29 ) => Effect.Effect<
30 (
31 request: Omit<SVC.PutAutoScalingPolicyInput, "ClusterId">,
32 ) => Effect.Effect<SVC.PutAutoScalingPolicyOutput, SVC.PutAutoScalingPolicyError>
33 >
34 > {}
35 export const PutAutoScalingPolicy = Binding.Service<PutAutoScalingPolicy>(
36 "AWS.EMR.PutAutoScalingPolicy",
37 );