Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- newtype QueueUrl = QueueUrl Text
- data SQSError = DeleteMessageBatchError
- class HasReceiptHandle a
- data ConsumerMode
- data ConsumerResult
- readQueue :: MonadAWS m => QueueUrl -> m [Message]
- drainQueue :: MonadAWS m => QueueUrl -> m [Message]
- ackMessage :: (MonadAWS m, HasReceiptHandle msg) => QueueUrl -> msg -> m (Either SQSError ())
- ackMessages :: (MonadAWS m, HasReceiptHandle msg) => QueueUrl -> [msg] -> m (Either SQSError ())
- queueSource :: MonadAWS m => QueueUrl -> ConduitT () Message m ()
- forAllMessages :: (MonadUnliftIO m, HasEnv env) => env -> QueueUrl -> ConsumerMode -> (Message -> m ConsumerResult) -> m ()
- data Message
- mBody :: Lens' Message (Maybe Text)
- mMD5OfBody :: Lens' Message (Maybe Text)
- mMessageId :: Lens' Message (Maybe Text)
- mReceiptHandle :: Lens' Message (Maybe Text)
- mAttributes :: Lens' Message (HashMap MessageAttribute Text)
Documentation
Instances
Eq QueueUrl Source # | |
Show QueueUrl Source # | |
IsString QueueUrl Source # | |
Defined in Antiope.SQS.Types fromString :: String -> QueueUrl # | |
Generic QueueUrl Source # | |
ToText QueueUrl Source # | |
Defined in Antiope.SQS.Types | |
FromText QueueUrl Source # | |
Defined in Antiope.SQS.Types | |
type Rep QueueUrl Source # | |
Defined in Antiope.SQS.Types |
class HasReceiptHandle a Source #
Instances
HasReceiptHandle Message Source # | |
Defined in Antiope.SQS.Types | |
HasReceiptHandle ReceiptHandle Source # | |
Defined in Antiope.SQS.Types | |
HasReceiptHandle (SqsMessage a) Source # | |
Defined in Antiope.SQS.Messages getReceiptHandle :: SqsMessage a -> Maybe ReceiptHandle Source # |
data ConsumerMode Source #
Queue consuming mode
Instances
Eq ConsumerMode Source # | |
Defined in Antiope.SQS.Types (==) :: ConsumerMode -> ConsumerMode -> Bool # (/=) :: ConsumerMode -> ConsumerMode -> Bool # | |
Show ConsumerMode Source # | |
Defined in Antiope.SQS.Types showsPrec :: Int -> ConsumerMode -> ShowS # show :: ConsumerMode -> String # showList :: [ConsumerMode] -> ShowS # | |
Generic ConsumerMode Source # | |
Defined in Antiope.SQS.Types type Rep ConsumerMode :: Type -> Type # from :: ConsumerMode -> Rep ConsumerMode x # to :: Rep ConsumerMode x -> ConsumerMode # | |
type Rep ConsumerMode Source # | |
data ConsumerResult Source #
Instances
Eq ConsumerResult Source # | |
Defined in Antiope.SQS.Types (==) :: ConsumerResult -> ConsumerResult -> Bool # (/=) :: ConsumerResult -> ConsumerResult -> Bool # | |
Show ConsumerResult Source # | |
Defined in Antiope.SQS.Types showsPrec :: Int -> ConsumerResult -> ShowS # show :: ConsumerResult -> String # showList :: [ConsumerResult] -> ShowS # | |
Generic ConsumerResult Source # | |
Defined in Antiope.SQS.Types type Rep ConsumerResult :: Type -> Type # from :: ConsumerResult -> Rep ConsumerResult x # to :: Rep ConsumerResult x -> ConsumerResult # | |
type Rep ConsumerResult Source # | |
readQueue :: MonadAWS m => QueueUrl -> m [Message] Source #
Reads the specified SQS queue once returning a bath of messages
drainQueue :: MonadAWS m => QueueUrl -> m [Message] Source #
Reads the specified SQS queue until it is empty and returns a list of messages
ackMessage :: (MonadAWS m, HasReceiptHandle msg) => QueueUrl -> msg -> m (Either SQSError ()) Source #
Acknowledges a single SQS message
ackMessages :: (MonadAWS m, HasReceiptHandle msg) => QueueUrl -> [msg] -> m (Either SQSError ()) Source #
Acknowledges a group of SQS messages
queueSource :: MonadAWS m => QueueUrl -> ConduitT () Message m () Source #
Reads from an SQS indefinitely, producing messages into a conduit
forAllMessages :: (MonadUnliftIO m, HasEnv env) => env -> QueueUrl -> ConsumerMode -> (Message -> m ConsumerResult) -> m () Source #
Re-exports
An Amazon SQS message.
See: message
smart constructor.
Instances
mMessageId :: Lens' Message (Maybe Text) #
A unique identifier for the message. A MessageId
is considered unique across all AWS accounts for an extended period of time.
mReceiptHandle :: Lens' Message (Maybe Text) #
An identifier associated with the act of receiving the message. A new receipt handle is returned every time you receive a message. When deleting a message, you provide the last received receipt handle to delete the message.
mAttributes :: Lens' Message (HashMap MessageAttribute Text) #
SenderId
, SentTimestamp
, ApproximateReceiveCount
, andor ApproximateFirstReceiveTimestamp
. SentTimestamp
and ApproximateFirstReceiveTimestamp
are each returned as an integer representing the <http:en.wikipedia.orgwiki/Unix_time epoch time> in milliseconds.