-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | AWS Lambda backend for distributed-fork. -- -- AWS Lambda backend for distributed-fork. @package distributed-fork-aws-lambda @version 0.0.2.0 -- | Provides a Backend using AWS Lambda functions. -- -- In order to do that, roughly: -- --
-- {-# LANGUAGE StaticPointers #-}
--
-- import Control.Lens
-- import Control.Distributed.Fork
-- import Control.Distributed.Fork.Lambda
--
-- opts :: LambdaBackendOptions
-- opts = lambdaBackendOptions "my-s3-bucket"
-- & lboMemory .~ 1024
--
-- main :: IO ()
-- main = do
-- initDistributedFork
-- withLambdaBackend opts $ \backend -> do
-- handle <- fork backend (static Dict) (static (return "Hello from Lambda!"))
-- await handle >>= putStrLn
--
withLambdaBackend :: LambdaBackendOptions -> (Backend -> IO a) -> IO a
-- | Options required for creating a Lambda backend.
--
-- Use lambdaBackendOptions smart constructor to create and lenses
-- below for setting optional fields.
data LambdaBackendOptions
lambdaBackendOptions :: Text -> LambdaBackendOptions
-- | Prefix to the deployment archive and the CloudFormation stack.
--
-- Default: "distributed-fork"
lboPrefix :: Lens' LambdaBackendOptions Text
-- | Desired memory for the Lambda functions.
--
-- See CloudFormation's AWS::Lambda::Function::MemorySize page for
-- allowed values.
--
-- Default: 128
lboMemory :: Lens' LambdaBackendOptions Int