public static class LambdaInvokerFactory.Builder extends Object
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
<T> T |
build(Class<T> interfaceClass)
Build a remote proxy of the given interface to make calls to AWS Lambda.
|
LambdaInvokerFactory.Builder |
functionAlias(String functionAlias)
Sets the function alias to invoke.
|
LambdaInvokerFactory.Builder |
functionVersion(String functionVersion)
Sets the function version to invoke.
|
LambdaInvokerFactory.Builder |
lambdaClient(AWSLambda lambda)
Sets the client to use to call AWS Lambda.
|
LambdaInvokerFactory.Builder |
lambdaFunctionNameResolver(LambdaFunctionNameResolver functionNameResolver)
Sets a new Function name resolver to override the default behavior.
|
LambdaInvokerFactory.Builder |
objectMapper(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
Sets the ObjectMapper used to (de-)serialize payload if you do not wish to use the default mapper.
|
public LambdaInvokerFactory.Builder lambdaFunctionNameResolver(LambdaFunctionNameResolver functionNameResolver)
functionNameResolver
- Implementation of LambdaFunctionNameResolver
public LambdaInvokerFactory.Builder objectMapper(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
ObjectMapper
for configuration options)
The FAIL_ON_UNKNOWN_PROPERTIES property MUST be disabled for any custom object mapper so that the response unmarshalling is forward compatible with any new fields your Lambda function may return but might not be modeled.
public LambdaInvokerFactory.Builder functionAlias(String functionAlias)
public LambdaInvokerFactory.Builder functionVersion(String functionVersion)
public LambdaInvokerFactory.Builder lambdaClient(AWSLambda lambda)
AWSLambdaAsyncClientBuilder.defaultClient()
).lambda
- Client instance to use.public <T> T build(Class<T> interfaceClass)
T
- Interface type.interfaceClass
- Interface class to proxy.