S3PutObjectActionProps
- class aws_cdk.aws_iot_actions.S3PutObjectActionProps(*, role=None, access_control=None, key=None)
Bases:
CommonActionProps
(experimental) Configuration properties of an action for s3.
- Parameters:
role (
Optional
[IRole
]) – (experimental) The IAM role that allows access to AWS service. Default: a new role will be createdaccess_control (
Optional
[BucketAccessControl
]) – (experimental) The Amazon S3 canned ACL that controls access to the object identified by the object key. Default: Nonekey (
Optional
[str
]) – (experimental) The path to the file where the data is written. Supports substitution templates. Default: ‘${topic()}/${timestamp()}’
- Stability:
experimental
- ExampleMetadata:
infused
Example:
bucket = s3.Bucket(self, "MyBucket") iot.TopicRule(self, "TopicRule", sql=iot.IotSql.from_string_as_ver20160323("SELECT topic(2) as device_id, year, month, day FROM 'device/+/data'"), actions=[ actions.S3PutObjectAction(bucket, key="${year}/${month}/${day}/${topic(2)}" ) ] )
Attributes
- access_control
(experimental) The Amazon S3 canned ACL that controls access to the object identified by the object key.
- Default:
None
- See:
- Stability:
experimental
- key
(experimental) The path to the file where the data is written.
Supports substitution templates.
- Default:
‘${topic()}/${timestamp()}’
- See:
- Stability:
experimental
- role
(experimental) The IAM role that allows access to AWS service.
- Default:
a new role will be created
- Stability:
experimental