# DeploymentComponentUpdatePolicyProperty

Contains information about a deployment's policy that defines when components are safe to update.

Each component on a device can report whether or not it's ready to update. After a component and its dependencies are ready, they can apply the update in the deployment. You can configure whether or not the deployment notifies components of an update and waits for a response. You specify the amount of time each component has to respond to the update notification.

- Source: Generated at build time
- Type last changed: v2.93.0 · 23 Aug 2023

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_greengrassv2 as greengrassv2 } from 'aws-cdk-lib';
const deploymentComponentUpdatePolicyProperty: greengrassv2.CfnDeployment.DeploymentComponentUpdatePolicyProperty = {
  action: 'action',
  timeoutInSeconds: 123,
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_greengrassv2 as greengrassv2

deployment_component_update_policy_property = greengrassv2.CfnDeployment.DeploymentComponentUpdatePolicyProperty(
    action="action",
    timeout_in_seconds=123
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.greengrassv2.*;

DeploymentComponentUpdatePolicyProperty deploymentComponentUpdatePolicyProperty = DeploymentComponentUpdatePolicyProperty.builder()
        .action("action")
        .timeoutInSeconds(123)
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.GreengrassV2;

var deploymentComponentUpdatePolicyProperty = new DeploymentComponentUpdatePolicyProperty {
    Action = "action",
    TimeoutInSeconds = 123
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

deploymentComponentUpdatePolicyProperty := &DeploymentComponentUpdatePolicyProperty{
	Action: jsii.String("action"),
	TimeoutInSeconds: jsii.Number(123),
}
```

## Properties

- `action`: string — Whether or not to notify components and wait for components to become safe to update.

  Choose from the following options:

  - `NOTIFY_COMPONENTS` – The deployment notifies each component before it stops and updates that component. Components can use the [SubscribeToComponentUpdates](https://docs.aws.amazon.com/greengrass/v2/developerguide/interprocess-communication.html#ipc-operation-subscribetocomponentupdates) IPC operation to receive these notifications. Then, components can respond with the [DeferComponentUpdate](https://docs.aws.amazon.com/greengrass/v2/developerguide/interprocess-communication.html#ipc-operation-defercomponentupdate) IPC operation. For more information, see the [Create deployments](https://docs.aws.amazon.com/greengrass/v2/developerguide/create-deployments.html) in the *AWS IoT Greengrass V2 Developer Guide* .
  - `SKIP_NOTIFY_COMPONENTS` – The deployment doesn't notify components or wait for them to be safe to update.

  Default: `NOTIFY_COMPONENTS`

- `timeoutInSeconds`: number — The amount of time in seconds that each component on a device has to report that it's safe to update.

  If the component waits for longer than this timeout, then the deployment proceeds on the device.

  Default: `60`
