custom_plugins
Creates, updates, deletes or gets a custom_plugin resource or lists custom_plugins in a region
Overview
| Name | custom_plugins |
| Type | Resource |
| Description | An example resource schema demonstrating some basic constructs and validation rules. |
| Id | awscc.kafkaconnect.custom_plugins |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
name | string | The name of the custom plugin. |
description | string | A summary description of the custom plugin. |
custom_plugin_arn | string | The Amazon Resource Name (ARN) of the custom plugin to use. |
content_type | string | The type of the plugin file. |
file_description | object | Details about the custom plugin file. |
location | object | Information about the location of a custom plugin. |
revision | integer | The revision of the custom plugin. |
tags | array | An array of key-value pairs to apply to this resource. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
custom_plugin_arn | string | The Amazon Resource Name (ARN) of the custom plugin to use. |
region | string | AWS region. |
For more information, see AWS::KafkaConnect::CustomPlugin.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | custom_plugins | INSERT | Name, ContentType, Location, region |
delete_resource | custom_plugins | DELETE | Identifier, region |
update_resource | custom_plugins | UPDATE | Identifier, PatchDocument, region |
list_resources | custom_plugins_list_only | SELECT | region |
get_resource | custom_plugins | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual custom_plugin.
SELECT
region,
name,
description,
custom_plugin_arn,
content_type,
file_description,
location,
revision,
tags
FROM awscc.kafkaconnect.custom_plugins
WHERE
region = '{{ region }}' AND
Identifier = '{{ custom_plugin_arn }}';
Lists all custom_plugins in a region.
SELECT
region,
custom_plugin_arn
FROM awscc.kafkaconnect.custom_plugins_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new custom_plugin resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.kafkaconnect.custom_plugins (
Name,
ContentType,
Location,
region
)
SELECT
'{{ name }}',
'{{ content_type }}',
'{{ location }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.kafkaconnect.custom_plugins (
Name,
Description,
ContentType,
Location,
Tags,
region
)
SELECT
'{{ name }}',
'{{ description }}',
'{{ content_type }}',
'{{ location }}',
'{{ tags }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: custom_plugin
props:
- name: name
value: '{{ name }}'
- name: description
value: '{{ description }}'
- name: content_type
value: '{{ content_type }}'
- name: location
value:
s3_location:
bucket_arn: '{{ bucket_arn }}'
file_key: '{{ file_key }}'
object_version: '{{ object_version }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
UPDATE example
Use the following StackQL query and manifest file to update a custom_plugin resource, using stack-deploy.
/*+ update */
UPDATE awscc.kafkaconnect.custom_plugins
SET PatchDocument = string('{{ {
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ custom_plugin_arn }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.kafkaconnect.custom_plugins
WHERE
Identifier = '{{ custom_plugin_arn }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the custom_plugins resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
kafkaconnect:DescribeCustomPlugin,
kafkaconnect:ListTagsForResource,
kafkaconnect:CreateCustomPlugin,
kafkaconnect:TagResource,
s3:GetObject,
s3:GetObjectVersion,
s3:GetObjectAttributes,
s3:GetObjectVersionAttributes
kafkaconnect:DescribeCustomPlugin,
kafkaconnect:ListTagsForResource
kafkaconnect:DescribeCustomPlugin,
kafkaconnect:ListTagsForResource,
kafkaconnect:TagResource,
kafkaconnect:UntagResource
kafkaconnect:DeleteCustomPlugin,
kafkaconnect:DescribeCustomPlugin
kafkaconnect:ListCustomPlugins