Hi,
Has anybody else come across this issue? I’m using:
Framework Core: 1.70.1
Plugin: 3.6.11
SDK: 2.3.0
Components: 2.30.10
I have a lambda function and custom authorizer, both using provisioned concurrency:
…
authenticator:
general:
name: authenticatorGeneral
type: TOKEN
# Cache authentication result for 5 minutes
resultTtlInSeconds: 300
identitySource: method.request.header.Authorization
identityValidationExpression: Bearer (.*)
functions:
authenticatorGeneral:
handler: src/authenticator.general
provisionedConcurrency: 1
reservedConcurrency: 10
memorySize: 512
proxy:
handler: src/handler.server
provisionedConcurrency: 1
reservedConcurrency: 10
memorySize: 1024
events:
- http:
method: any
path: /{proxy+}
cors: true
authorizer: ${self:custom.authenticator.general}
.....
Both these lambda functions are created with the provisioned alias and provisioning set as expected. API Gateway is mapping to the correctly aliased function for the proxy endpoint:
aura-auth-service-prod-proxy:provisioned
This works as expected, and does not suffer cold starts. If I check API Gateway for the custom authorizer mapping, it is not using the ‘provisioned’ alias:
aura-auth-service-prod-authenticatorGeneral
So I assume this will use ‘latest’, which is not provisioned? This is not working as expected and is suffering from cold starts.
Is this a known issue or am I configuring this incorrectly?
Cheers,
Rob