Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provider Lambda timeout no set from functionProps.timeout #41

Open
mikel67 opened this issue Nov 9, 2024 · 0 comments
Open

Provider Lambda timeout no set from functionProps.timeout #41

mikel67 opened this issue Nov 9, 2024 · 0 comments

Comments

@mikel67
Copy link

mikel67 commented Nov 9, 2024

When setting function properties for the provider the timeout is not applied and always uses the default of 5 minutes.

e.g.
const rdsProvider = new Provider(this, "Provider", {
vpc: vpc,
cluster: cluster,
vpcSubnets: vpc.selectSubnets({
subnetType: SubnetType.PUBLIC
}),
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
secret: cluster.secret!,
functionProps: {
allowPublicSubnet: true,
timeout: Duration.minutes(15),
}
});

Investigated and see that the issue is with newCustomResourceHandler (line 136)

current code: timeout: props.timeout ?? Duration.seconds(300),

fixed code: timeout: props.functionProps?.timeout ?? Duration.seconds(300),

I have tested on a local clone and the change results in the Lambda function having the expected timeout of 15 minutes. Once I get a chance to familiarise myself with the codebase and tests, will submit a PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant