Amazon Keyspaces에서 CDC 스트림 보기 - Amazon Keyspaces(Apache Cassandra용)

기계 번역으로 제공되는 번역입니다. 제공된 번역과 원본 영어의 내용이 상충하는 경우에는 영어 버전이 우선합니다.

Amazon Keyspaces에서 CDC 스트림 보기

키스페이스의 모든 스트림을 보거나 나열하려면 CQL의 문을 사용하여 system_schema_mcs.streams 시스템 키스페이스의 테이블을 쿼리하거나 또는 콘솔에서 get-streamlist-stream 명령을 사용할 수 AWS CLI있습니다.

필요한 권한에 대해서는 Amazon Keyspaces에서 CDC 스트림으로 작업할 수 있는 권한 구성을 참조하세요.

Cassandra Query Language (CQL)
CQL을 사용하여 CDC 스트림 보기
  • 테이블의 CDC 상태를 모니터링하려면 다음 문을 사용할 수 있습니다.

    SELECT custom_properties FROM system_schema_mcs.tables WHERE keyspace_name='my_keyspace' and table_name='my_table';

    명령의 출력은 이와 비슷합니다.

    ... custom_properties ---------------------------------------------------------------------------------- {'cdc_specification':{'status': 'Enabled', 'view_type': 'NEW_IMAGE', 'latest_stream_arn': 'arn:aws:cassandra:us-east-1:111122223333:/keyspace/my_keyspace/table/my_table/stream/stream_label''}} ...
CLI
를 사용하여 CDC 스트림 보기 AWS CLI
  1. 이 예제에서는 테이블에 대한 스트림 정보를 보는 방법을 보여줍니다.

    aws keyspaces get-table \ --keyspace-name 'my_keyspace' \ --table-name 'my_table'

    명령의 출력은 다음과 같습니다.

    { "keyspaceName": "my_keyspace", "tableName": "my_table", ... Other fields ..., "latestStreamArn": "arn:aws:cassandra:us-east-1:111122223333:/keyspace/my_keyspace/table/my_table/stream/stream_label", "cdcSpecification": { "status": "ENABLED", "viewType": "NEW_AND_OLD_IMAGES" } }
  2. 지정된에서 계정의 모든 스트림을 나열할 수 있습니다 AWS 리전. 다음 CLI 명령은 그 예입니다.

    aws keyspacesstreams list-streams --region us-east-1

    명령의 출력은 이와 비슷할 수 있습니다.

    { "Streams": [ { "StreamArn": "arn:aws:cassandra:us-east-1:111122223333:/keyspace/ks_1/table/t1/stream/2023-05-11T21:21:33.291", "StreamLabel": "2023-05-11T21:21:33.291", "KeyspaceName": "ks_1" "TableName": "t1", }, { "StreamArn": "arn:aws:cassandra:us-east-1:111122223333:/keyspace/ks_1/table/t2/stream/2023-05-11T21:21:33.291", "StreamLabel": "2023-05-11T21:21:33.291", "KeyspaceName": "ks_1"Create a keyspace with the name catalog. Note that streams are not supported in multi-Region keyspaces. "TableName": "t2", }, { "StreamArn": "arn:aws:cassandra:us-east-1:111122223333:/keyspace/ks_2/table/t1/stream/2023-05-11T21:21:33.291", "StreamLabel": "2023-05-11T21:21:33.291", "KeyspaceName": "ks_3" "TableName": "t1", } ] }
  3. 다음 파라미터를 사용하여 지정된 키스페이스에 대한 CDC 스트림을 나열할 수도 있습니다.

    aws keyspacesstreams list-streams --keyspace-name ks_1 --region us-east-1

    명령의 출력은 이와 비슷합니다.

    { "Streams": [ { "StreamArn": "arn:aws:cassandra:us-east-1:111122223333:/keyspace/ks_1/table/t1/stream/2023-05-11T21:21:33.291", "StreamLabel": "2023-05-11T21:21:33.291", "KeyspaceName": "ks_1" "TableName": "t1", }, { "StreamArn": "arn:aws:cassandra:us-east-1:111122223333:/keyspace/ks_1/table/t2/stream/2023-05-11T21:21:33.291", "StreamLabel": "2023-05-11T21:21:33.291", "KeyspaceName": "ks_1" "TableName": "t2", } ] }
  4. 다음 파라미터를 사용하여 지정된 테이블에 대한 CDC 스트림을 나열할 수도 있습니다.

    aws keyspacesstreams list-streams --keyspace-name ks_1 --table-name t2 --region us-east-1

    명령의 출력은 이와 비슷합니다.

    { "Streams": [ { "StreamArn": "arn:aws:cassandra:us-east-1:111122223333:/keyspace/ks_1/table/t2/stream/2023-05-11T21:21:33.291", "StreamLabel": "2023-05-11T21:21:33.291", "KeyspaceName": "ks_1" "TableName": "t2", } ] }
Console
Amazon Keyspaces 콘솔에서 CDC 스트림 보기
  1. 에 로그인 AWS Management Console하고 https://console.aws.amazon.com/keyspaces/home Amazon Keyspaces 콘솔을 엽니다.

  2. 탐색 창에서 테이블을 선택한 다음 목록에서 테이블을 선택합니다.

  3. 스트림 탭을 선택하여 스트림 세부 정보를 검토합니다.