Open skorfmann opened 1 year ago
I'd imagine the warning should only appear if you're compiling to a target where cold starts are relevant (e.g. AWS)
I'd imagine the warning should only appear if you're compiling to a target where cold starts are relevant (e.g. AWS)
Not sure, since the ultimate goal is likely to deploy to one of the cloud providers? Wouldn't you want to get a hint early in the process?
If we think cold starts are applicable to all cloud providers then I guess it's alright. I just want to make sure we are avoiding giving error messages that don't apply to all cloud providers. For example, if someone wrote a backend for cloud.Function
that uses e.g. Cloudflare Workers, then it's possible a 1s timeout might be OK if they have shorter cold starts.
Also if we emit warnings, there ought to be a way for users to turn them off / ignore them.
Hi,
This issue hasn't seen activity in 60 days. Therefore, we are marking this issue as stale for now. It will be closed after 7 days. Feel free to re-open this issue when there's an update or relevant information to be added. Thanks!
There are too many variables to consider:
Hi,
This issue hasn't seen activity in 90 days. Therefore, we are marking this issue as stale for now. It will be closed after 7 days. Feel free to re-open this issue when there's an update or relevant information to be added. Thanks!
Hi,
This issue hasn't seen activity in 90 days. Therefore, we are marking this issue as stale for now. It will be closed after 7 days. Feel free to re-open this issue when there's an update or relevant information to be added. Thanks!
Feature Spec
wing now let's the user know, that timeouts for inflight functions below 3 seconds are likely to run into the given timeouts in cold start situations.
e.g. the following example
will work for warm inflight functions, but will be killed due to the ambitious timeout setting for cold starts. This can be quite confusing and unexpected. Hence, the wing compiler will now warn about this and recommend a minimum of 3 seconds.
Use Cases
while short timeouts work in the simulator, this won't work as expected for the
tf-aws
target.Implementation Notes
This is also depending on the runtime sizing (probably not an issue for larger sized Lambda functions). Perhaps this should be taken into account.
Component
Compiler, SDK
Community Notes