Safe Haskell | None |
---|---|
Language | Haskell2010 |
Creates a new Lambda function or updates an existing function. The function metadata is created from the request parameters, and the code for the function is provided by a .zip file in the request body. If the function name already exists, the existing Lambda function is updated with the new code and metadata. This operation requires permission for the lambda:UploadFunction action.
http://docs.aws.amazon.com/lambda/latest/dg/API_UploadFunction.html
- data UploadFunction
- uploadFunction :: Text -> Base64 -> Text -> Text -> Text -> Text -> UploadFunction
- ufDescription :: Lens' UploadFunction (Maybe Text)
- ufFunctionName :: Lens' UploadFunction Text
- ufFunctionZip :: Lens' UploadFunction Base64
- ufHandler :: Lens' UploadFunction Text
- ufMemorySize :: Lens' UploadFunction (Maybe Natural)
- ufMode :: Lens' UploadFunction Text
- ufRole :: Lens' UploadFunction Text
- ufRuntime :: Lens' UploadFunction Text
- ufTimeout :: Lens' UploadFunction (Maybe Natural)
- data UploadFunctionResponse
- uploadFunctionResponse :: UploadFunctionResponse
- ufrCodeSize :: Lens' UploadFunctionResponse (Maybe Integer)
- ufrConfigurationId :: Lens' UploadFunctionResponse (Maybe Text)
- ufrDescription :: Lens' UploadFunctionResponse (Maybe Text)
- ufrFunctionARN :: Lens' UploadFunctionResponse (Maybe Text)
- ufrFunctionName :: Lens' UploadFunctionResponse (Maybe Text)
- ufrHandler :: Lens' UploadFunctionResponse (Maybe Text)
- ufrLastModified :: Lens' UploadFunctionResponse (Maybe UTCTime)
- ufrMemorySize :: Lens' UploadFunctionResponse (Maybe Natural)
- ufrMode :: Lens' UploadFunctionResponse (Maybe Text)
- ufrRole :: Lens' UploadFunctionResponse (Maybe Text)
- ufrRuntime :: Lens' UploadFunctionResponse (Maybe Text)
- ufrTimeout :: Lens' UploadFunctionResponse (Maybe Natural)
Request
data UploadFunction Source
Request constructor
UploadFunction
constructor.
The fields accessible through corresponding lenses are:
Request lenses
ufDescription :: Lens' UploadFunction (Maybe Text) Source
A short, user-defined function description. Lambda does not use this value. Assign a meaningful description as you see fit.
ufFunctionName :: Lens' UploadFunction Text Source
The name you want to assign to the function you are uploading. The function names appear in the console and are returned in the ListFunctions API. Function names are used to specify functions to other AWS Lambda APIs, such as InvokeAsync.
ufFunctionZip :: Lens' UploadFunction Base64 Source
A .zip file containing your packaged source code. For more information about creating a .zip file, go to AWS LambdaL How it Works in the AWS Lambda Developer Guide.
ufHandler :: Lens' UploadFunction Text Source
The function that Lambda calls to begin execution. For Node.js, it is the module-name.export value in your function.
ufMemorySize :: Lens' UploadFunction (Maybe Natural) Source
The amount of memory, in MB, your Lambda function is given. Lambda uses this memory size to infer the amount of CPU allocated to your function. Your function use-case determines your CPU and memory requirements. For example, database operation might need less memory compared to image processing function. The default value is 128 MB. The value must be a multiple of 64 MB.
ufMode :: Lens' UploadFunction Text Source
How the Lambda function will be invoked. Lambda supports only the "event" mode.
ufRole :: Lens' UploadFunction Text Source
The Amazon Resource Name (ARN) of the IAM role that Lambda assumes when it executes your function to access any other Amazon Web Services (AWS) resources.
ufRuntime :: Lens' UploadFunction Text Source
The runtime environment for the Lambda function you are uploading. Currently, Lambda supports only "nodejs" as the runtime.
ufTimeout :: Lens' UploadFunction (Maybe Natural) Source
The function execution time at which Lambda should terminate the function. Because the execution time has cost implications, we recommend you set this value based on your expected execution time. The default is 3 seconds.
Response
Response constructor
uploadFunctionResponse :: UploadFunctionResponse Source
UploadFunctionResponse
constructor.
The fields accessible through corresponding lenses are:
ufrCodeSize
::
Maybe
Integer
ufrConfigurationId
::
Maybe
Text
ufrDescription
::
Maybe
Text
ufrFunctionARN
::
Maybe
Text
ufrFunctionName
::
Maybe
Text
ufrHandler
::
Maybe
Text
ufrLastModified
::
Maybe
UTCTime
ufrMemorySize
::
Maybe
Natural
ufrMode
::
Maybe
Text
ufrRole
::
Maybe
Text
ufrRuntime
::
Maybe
Text
ufrTimeout
::
Maybe
Natural
Response lenses
ufrCodeSize :: Lens' UploadFunctionResponse (Maybe Integer) Source
The size, in bytes, of the function .zip file you uploaded.
ufrConfigurationId :: Lens' UploadFunctionResponse (Maybe Text) Source
A Lambda-assigned unique identifier for the current function code and related configuration.
ufrDescription :: Lens' UploadFunctionResponse (Maybe Text) Source
The user-provided description.
ufrFunctionARN :: Lens' UploadFunctionResponse (Maybe Text) Source
The Amazon Resource Name (ARN) assigned to the function.
ufrFunctionName :: Lens' UploadFunctionResponse (Maybe Text) Source
The name of the function.
ufrHandler :: Lens' UploadFunctionResponse (Maybe Text) Source
The function Lambda calls to begin executing your function.
ufrLastModified :: Lens' UploadFunctionResponse (Maybe UTCTime) Source
The timestamp of the last time you updated the function.
ufrMemorySize :: Lens' UploadFunctionResponse (Maybe Natural) Source
The memory size, in MB, you configured for the function. Must be a multiple of 64 MB.
ufrMode :: Lens' UploadFunctionResponse (Maybe Text) Source
The type of the Lambda function you uploaded.
ufrRole :: Lens' UploadFunctionResponse (Maybe Text) Source
The Amazon Resource Name (ARN) of the IAM role that Lambda assumes when it executes your function to access any other Amazon Web Services (AWS) resources.
ufrRuntime :: Lens' UploadFunctionResponse (Maybe Text) Source
The runtime environment for the Lambda function.
ufrTimeout :: Lens' UploadFunctionResponse (Maybe Natural) Source
The function execution time at which Lambda should terminate the function. Because the execution time has cost implications, we recommend you set this value based on your expected execution time. The default is 3 seconds.