amazonka-kinesis-firehose-1.4.2: Amazon Kinesis Firehose SDK.

Copyright(c) 2013-2016 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.Firehose.PutRecord

Contents

Description

Writes a single data record into an Amazon Kinesis Firehose delivery stream. To write multiple data records into a delivery stream, use PutRecordBatch. Applications using these operations are referred to as producers.

By default, each delivery stream can take in up to 2,000 transactions per second, 5,000 records per second, or 5 MB per second. Note that if you use PutRecord and PutRecordBatch, the limits are an aggregate across these two operations for each delivery stream. For more information about limits and how to request an increase, see Amazon Kinesis Firehose Limits.

You must specify the name of the delivery stream and the data record when using PutRecord. The data record consists of a data blob that can be up to 1,000 KB in size, and any kind of data, for example, a segment from a log file, geographic location data, web site clickstream data, etc.

Firehose buffers records before delivering them to the destination. To disambiguate the data blobs at the destination, a common solution is to use delimiters in the data, such as a newline ('\\n') or some other character unique within the data. This allows the consumer application(s) to parse individual data items when reading the data from the destination.

The PutRecord operation returns a RecordId, which is a unique string assigned to each record. Producer applications can use this ID for purposes such as auditability and investigation.

If the PutRecord operation throws a ServiceUnavailableException, back off and retry. If the exception persists, it is possible that the throughput limits have been exceeded for the delivery stream.

Data records sent to Firehose are stored for 24 hours from the time they are added to a delivery stream as it attempts to send the records to the destination. If the destination is unreachable for more than 24 hours, the data is no longer available.

Synopsis

Creating a Request

putRecord Source #

Creates a value of PutRecord with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data PutRecord Source #

Contains the parameters for PutRecord.

See: putRecord smart constructor.

Instances

Eq PutRecord Source # 
Data PutRecord Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutRecord -> c PutRecord #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutRecord #

toConstr :: PutRecord -> Constr #

dataTypeOf :: PutRecord -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutRecord) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutRecord) #

gmapT :: (forall b. Data b => b -> b) -> PutRecord -> PutRecord #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutRecord -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutRecord -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutRecord -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutRecord -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutRecord -> m PutRecord #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutRecord -> m PutRecord #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutRecord -> m PutRecord #

Read PutRecord Source # 
Show PutRecord Source # 
Generic PutRecord Source # 

Associated Types

type Rep PutRecord :: * -> * #

Hashable PutRecord Source # 
ToJSON PutRecord Source # 
NFData PutRecord Source # 

Methods

rnf :: PutRecord -> () #

AWSRequest PutRecord Source # 
ToQuery PutRecord Source # 
ToPath PutRecord Source # 
ToHeaders PutRecord Source # 

Methods

toHeaders :: PutRecord -> [Header] #

type Rep PutRecord Source # 
type Rep PutRecord = D1 (MetaData "PutRecord" "Network.AWS.Firehose.PutRecord" "amazonka-kinesis-firehose-1.4.2-H0T82FeNCx46rFPbtiwyVU" False) (C1 (MetaCons "PutRecord'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_prDeliveryStreamName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) (S1 (MetaSel (Just Symbol "_prRecord") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Record))))
type Rs PutRecord Source # 

Request Lenses

prDeliveryStreamName :: Lens' PutRecord Text Source #

The name of the delivery stream.

Destructuring the Response

putRecordResponse Source #

Creates a value of PutRecordResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data PutRecordResponse Source #

Contains the output of PutRecord.

See: putRecordResponse smart constructor.

Instances

Eq PutRecordResponse Source # 
Data PutRecordResponse Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutRecordResponse -> c PutRecordResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutRecordResponse #

toConstr :: PutRecordResponse -> Constr #

dataTypeOf :: PutRecordResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutRecordResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutRecordResponse) #

gmapT :: (forall b. Data b => b -> b) -> PutRecordResponse -> PutRecordResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutRecordResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutRecordResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutRecordResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutRecordResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutRecordResponse -> m PutRecordResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutRecordResponse -> m PutRecordResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutRecordResponse -> m PutRecordResponse #

Read PutRecordResponse Source # 
Show PutRecordResponse Source # 
Generic PutRecordResponse Source # 
NFData PutRecordResponse Source # 

Methods

rnf :: PutRecordResponse -> () #

type Rep PutRecordResponse Source # 
type Rep PutRecordResponse = D1 (MetaData "PutRecordResponse" "Network.AWS.Firehose.PutRecord" "amazonka-kinesis-firehose-1.4.2-H0T82FeNCx46rFPbtiwyVU" False) (C1 (MetaCons "PutRecordResponse'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_prrsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int)) (S1 (MetaSel (Just Symbol "_prrsRecordId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text))))

Response Lenses