January 2019
Intermediate to advanced
490 pages
15h 37m
English
You can add data to a KDS from the CLI using the aws kinesis put-record command, as follows:
aws kinesis put-record \ --stream-name my-first-kinesis-stream \ --partition-key 12345 \ --data sampledata01 \ --profile admin
This will return the shard ID and the sequence number of the record, as shown in the following screenshot:

Similarly, you can add one more data item with a payload of sampledata02.
Retrieving data from a KDS is a two-step process:
aws kinesis get-shard-iterator \ --shard-id shardId-000000000000 \ --shard-iterator-type TRIM_HORIZON \ --stream-name my-first-kinesis-stream ...
Read now
Unlock full access