| 1 | import type * as codeconnections from "@distilled.cloud/aws/codeconnections"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { SyncConfiguration } from "./SyncConfiguration.ts"; |
| 5 | |
| 6 | /** |
| 7 | * Runtime binding for `codeconnections:GetSyncBlockerSummary`. |
| 8 | * |
| 9 | * Bind this operation to a {@link SyncConfiguration} to read the latest |
| 10 | * sync blockers — errors that stop Git sync from converging the resource — |
| 11 | * from inside a function runtime. Pair with {@link UpdateSyncBlocker} to |
| 12 | * resolve them. Provide the implementation with |
| 13 | * `Effect.provide(AWS.CodeConnections.GetSyncBlockerSummaryHttp)`. |
| 14 | * ### Monitoring Git Sync |
| 15 | * **Example:** Read the Latest Sync Blockers |
| 16 | * ```typescript |
| 17 | * // init — bind the operation to the sync configuration |
| 18 | * const getSyncBlockerSummary = |
| 19 | * yield* AWS.CodeConnections.GetSyncBlockerSummary(sync); |
| 20 | * |
| 21 | * // runtime |
| 22 | * const { SyncBlockerSummary } = yield* getSyncBlockerSummary(); |
| 23 | * const blockers = SyncBlockerSummary.LatestBlockers ?? []; |
| 24 | * ``` |
| 25 | * |
| 26 | * @binding |
| 27 | */ |
| 28 | export interface GetSyncBlockerSummary extends Binding.Service< |
| 29 | GetSyncBlockerSummary, |
| 30 | "AWS.CodeConnections.GetSyncBlockerSummary", |
| 31 | ( |
| 32 | syncConfiguration: SyncConfiguration, |
| 33 | ) => Effect.Effect< |
| 34 | () => Effect.Effect< |
| 35 | codeconnections.GetSyncBlockerSummaryOutput, |
| 36 | codeconnections.GetSyncBlockerSummaryError |
| 37 | > |
| 38 | > |
| 39 | > {} |
| 40 | |
| 41 | export const GetSyncBlockerSummary = Binding.Service<GetSyncBlockerSummary>( |
| 42 | "AWS.CodeConnections.GetSyncBlockerSummary", |
| 43 | ); |