indices
Creates, updates, deletes or gets an index resource or lists indices in a region
Overview
| Name | indices |
| Type | Resource |
| Description | Definition of AWS::QBusiness::Index Resource Type |
| Id | awscc.qbusiness.indices |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
application_id | string | |
capacity_configuration | object | |
created_at | string | |
description | string | |
display_name | string | |
document_attribute_configurations | array | |
index_arn | string | |
index_id | string | |
index_statistics | object | |
type | string | |
status | string | |
tags | array | |
updated_at | string | |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
application_id | string | |
index_id | string | |
region | string | AWS region. |
For more information, see AWS::QBusiness::Index.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | indices | INSERT | ApplicationId, DisplayName, region |
delete_resource | indices | DELETE | Identifier, region |
update_resource | indices | UPDATE | Identifier, PatchDocument, region |
list_resources | indices_list_only | SELECT | region |
get_resource | indices | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual index.
SELECT
region,
application_id,
capacity_configuration,
created_at,
description,
display_name,
document_attribute_configurations,
index_arn,
index_id,
index_statistics,
type,
status,
tags,
updated_at
FROM awscc.qbusiness.indices
WHERE
region = 'us-east-1' AND
Identifier = '{{ application_id }}|{{ index_id }}';
Lists all indices in a region.
SELECT
region,
application_id,
index_id
FROM awscc.qbusiness.indices_list_only
WHERE
region = 'us-east-1';
INSERT example
Use the following StackQL query and manifest file to create a new index resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.qbusiness.indices (
ApplicationId,
DisplayName,
region
)
SELECT
'{{ application_id }}',
'{{ display_name }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.qbusiness.indices (
ApplicationId,
CapacityConfiguration,
Description,
DisplayName,
DocumentAttributeConfigurations,
Type,
Tags,
region
)
SELECT
'{{ application_id }}',
'{{ capacity_configuration }}',
'{{ description }}',
'{{ display_name }}',
'{{ document_attribute_configurations }}',
'{{ type }}',
'{{ tags }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: index
props:
- name: application_id
value: '{{ application_id }}'
- name: capacity_configuration
value:
units: null
- name: description
value: '{{ description }}'
- name: display_name
value: '{{ display_name }}'
- name: document_attribute_configurations
value:
- name: '{{ name }}'
type: '{{ type }}'
search: '{{ search }}'
- name: type
value: '{{ type }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
UPDATE example
Use the following StackQL query and manifest file to update a index resource, using stack-deploy.
/*+ update */
UPDATE awscc.qbusiness.indices
SET PatchDocument = string('{{ {
"CapacityConfiguration": capacity_configuration,
"Description": description,
"DisplayName": display_name,
"DocumentAttributeConfigurations": document_attribute_configurations,
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ application_id }}|{{ index_id }}';
DELETE example
/*+ delete */
DELETE FROM awscc.qbusiness.indices
WHERE
Identifier = '{{ application_id }}|{{ index_id }}' AND
region = 'us-east-1';
Permissions
To operate on the indices resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
qbusiness:CreateIndex,
qbusiness:GetIndex,
qbusiness:ListTagsForResource,
qbusiness:TagResource,
qbusiness:UpdateIndex
qbusiness:GetIndex,
qbusiness:ListTagsForResource
qbusiness:GetIndex,
qbusiness:ListTagsForResource,
qbusiness:TagResource,
qbusiness:UntagResource,
qbusiness:UpdateIndex
qbusiness:DeleteIndex,
qbusiness:GetIndex
qbusiness:ListIndices