Skip to content

[Workers] update size and startup limits in platform/limits.md - #6613

Merged
kabirsikand merged 1 commit into
productionfrom
workers-size-and-startup
Nov 14, 2022
Merged

[Workers] update size and startup limits in platform/limits.md#6613
kabirsikand merged 1 commit into
productionfrom
workers-size-and-startup

Conversation

@matthewdavidrodgers

Copy link
Copy Markdown
Contributor

Updates max worker size for free and paid customers
And adds documentation for script startup limits

@deadlypants1973 deadlypants1973 added this to the Pages and Workers milestone Nov 11, 2022
Comment thread content/workers/platform/limits.md Outdated
| [Environment variable<br/>size](#environment-variables) | 5 KB | 5 KB |
| [Worker size](#worker-size) | 1 MB | 1 MB |
| [Worker size](#worker-size) | 1 MB | 5 MB |
| [Worker startup time](#worker-startup-time) | 200ms | 200ms |

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
| [Worker startup time](#worker-startup-time) | 200ms | 200ms |
| [Worker startup time](#worker-startup-time) | 200 ms | 200 ms |
Comment thread content/workers/platform/limits.md Outdated

### Worker startup time

A Worker must be able to be parsed and execute its global scope (e.g. top-level code outside of your "fetch" handler) within 200ms. Script size can impact startup, as there's more code to parse and evaluate. Avoiding expensive code in the global scope can keep startup snappy as well. You can request adjustments to limits that conflict with your project goals by contacting Cloudflare. To increase a limit, complete the [Limit Increase Request Form](https://forms.gle/ukpeZVLWLnKeixDu7).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
A Worker must be able to be parsed and execute its global scope (e.g. top-level code outside of your "fetch" handler) within 200ms. Script size can impact startup, as there's more code to parse and evaluate. Avoiding expensive code in the global scope can keep startup snappy as well. You can request adjustments to limits that conflict with your project goals by contacting Cloudflare. To increase a limit, complete the [Limit Increase Request Form](https://forms.gle/ukpeZVLWLnKeixDu7).
A Worker must be able to be parsed and execute its global scope (top-level code outside of your `fetch` handler) within 200 ms. Script size can impact startup because there is more code to parse and evaluate. Avoiding expensive code in the global scope can keep startup efficient. You can request adjustments to limits that conflict with your project goals by contacting Cloudflare. To increase a limit, complete the [Limit Increase Request Form](https://forms.gle/ukpeZVLWLnKeixDu7).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was 'eg' supposed to be 'for example' or 'that is' in this context? We don't use Latin shorthand in docs. Also, checking to see if 'expensive' code is intentional? Or is it supposed to be 'expansive code' - as in large?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • for 'e.g.' - both definitions make sense, but I removed it for clarity
  • for 'expensive' - that was intentional. code that costs a lot of cpu or memory to execute
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 11, 2022

Copy link
Copy Markdown

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: 62b23f7
Status: ✅  Deploy successful!
Preview URL: https://4a31a024.cloudflare-docs-7ou.pages.dev
Branch Preview URL: https://workers-size-and-startup.cloudflare-docs-7ou.pages.dev

View logs

@kabirsikand
kabirsikand merged commit be6049d into production Nov 14, 2022
@kabirsikand
kabirsikand deleted the workers-size-and-startup branch November 14, 2022 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants