libZSservicesZSamazonka-dynamodb-streamsZSamazonka-dynamodb-streams
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.DynamoDBStreams.GetRecords

Description

Retrieves the stream records from a given shard.

Specify a shard iterator using the ShardIterator parameter. The shard iterator specifies the position in the shard from which you want to start reading stream records sequentially. If there are no stream records available in the portion of the shard that the iterator points to, GetRecords returns an empty list. Note that it might take multiple calls to get to a portion of the shard that contains stream records.

GetRecords can retrieve a maximum of 1 MB of data or 1000 stream records, whichever comes first.

Synopsis

Creating a Request

data GetRecords Source #

Represents the input of a GetRecords operation.

See: newGetRecords smart constructor.

Constructors

GetRecords' 

Fields

  • limit :: Maybe Natural

    The maximum number of records to return from the shard. The upper limit is 1000.

  • shardIterator :: Text

    A shard iterator that was retrieved from a previous GetShardIterator operation. This iterator can be used to access the stream records in this shard.

Instances

Instances details
Eq GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Read GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Show GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Generic GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Associated Types

type Rep GetRecords :: Type -> Type #

NFData GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Methods

rnf :: GetRecords -> () #

Hashable GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

ToJSON GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

AWSRequest GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Associated Types

type AWSResponse GetRecords #

ToHeaders GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Methods

toHeaders :: GetRecords -> [Header] #

ToPath GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

ToQuery GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

type Rep GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

type Rep GetRecords = D1 ('MetaData "GetRecords" "Amazonka.DynamoDBStreams.GetRecords" "libZSservicesZSamazonka-dynamodb-streamsZSamazonka-dynamodb-streams" 'False) (C1 ('MetaCons "GetRecords'" 'PrefixI 'True) (S1 ('MetaSel ('Just "limit") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Natural)) :*: S1 ('MetaSel ('Just "shardIterator") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text)))
type AWSResponse GetRecords Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

newGetRecords Source #

Create a value of GetRecords with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:limit:GetRecords', getRecords_limit - The maximum number of records to return from the shard. The upper limit is 1000.

$sel:shardIterator:GetRecords', getRecords_shardIterator - A shard iterator that was retrieved from a previous GetShardIterator operation. This iterator can be used to access the stream records in this shard.

Request Lenses

getRecords_limit :: Lens' GetRecords (Maybe Natural) Source #

The maximum number of records to return from the shard. The upper limit is 1000.

getRecords_shardIterator :: Lens' GetRecords Text Source #

A shard iterator that was retrieved from a previous GetShardIterator operation. This iterator can be used to access the stream records in this shard.

Destructuring the Response

data GetRecordsResponse Source #

Represents the output of a GetRecords operation.

See: newGetRecordsResponse smart constructor.

Constructors

GetRecordsResponse' 

Fields

  • records :: Maybe [Record]

    The stream records from the shard, which were retrieved using the shard iterator.

  • nextShardIterator :: Maybe Text

    The next position in the shard from which to start sequentially reading stream records. If set to null, the shard has been closed and the requested iterator will not return any more data.

  • httpStatus :: Int

    The response's http status code.

Instances

Instances details
Eq GetRecordsResponse Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Read GetRecordsResponse Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Show GetRecordsResponse Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Generic GetRecordsResponse Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Associated Types

type Rep GetRecordsResponse :: Type -> Type #

NFData GetRecordsResponse Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

Methods

rnf :: GetRecordsResponse -> () #

type Rep GetRecordsResponse Source # 
Instance details

Defined in Amazonka.DynamoDBStreams.GetRecords

type Rep GetRecordsResponse = D1 ('MetaData "GetRecordsResponse" "Amazonka.DynamoDBStreams.GetRecords" "libZSservicesZSamazonka-dynamodb-streamsZSamazonka-dynamodb-streams" 'False) (C1 ('MetaCons "GetRecordsResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "records") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [Record])) :*: (S1 ('MetaSel ('Just "nextShardIterator") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))))

newGetRecordsResponse Source #

Create a value of GetRecordsResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:records:GetRecordsResponse', getRecordsResponse_records - The stream records from the shard, which were retrieved using the shard iterator.

$sel:nextShardIterator:GetRecordsResponse', getRecordsResponse_nextShardIterator - The next position in the shard from which to start sequentially reading stream records. If set to null, the shard has been closed and the requested iterator will not return any more data.

$sel:httpStatus:GetRecordsResponse', getRecordsResponse_httpStatus - The response's http status code.

Response Lenses

getRecordsResponse_records :: Lens' GetRecordsResponse (Maybe [Record]) Source #

The stream records from the shard, which were retrieved using the shard iterator.

getRecordsResponse_nextShardIterator :: Lens' GetRecordsResponse (Maybe Text) Source #

The next position in the shard from which to start sequentially reading stream records. If set to null, the shard has been closed and the requested iterator will not return any more data.