Skip to content

DescribeComponent

Source: src/AWS/GreengrassV2/DescribeComponent.ts

Runtime binding for greengrass:DescribeComponent.

Reads the bound ComponentVersion’s cloud metadata — publisher, description, lifecycle status (DEPLOYABLE, FAILED, DEPRECATED), platforms, and tags — so a function can audit component health before rolling out a deployment. The component version ARN is injected from the binding. Provide the implementation with Effect.provide(AWS.GreengrassV2.DescribeComponentHttp).

// init — bind the operation to the component version
const describeComponent = yield* AWS.GreengrassV2.DescribeComponent(component);
// runtime
const metadata = yield* describeComponent();
if (metadata.status?.componentState === "DEPRECATED") {
yield* Effect.logWarning(`${metadata.componentName} is deprecated`);
}