Skip to content

Commit 61d73c3

Browse files
korinneRebeccaTamachiro
authored andcommitted
Updates documentation for route limits when running a remote dev session (#21152)
* adds docs for limit on routes per zone when using `--remote` * adds section to remote development docs about routes per zone limit
1 parent 464cc99 commit 61d73c3

File tree

2 files changed

+40
-20
lines changed

2 files changed

+40
-20
lines changed

src/content/docs/workers/local-development.mdx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ head: []
77
description: Develop your Workers locally via Wrangler.
88
---
99

10+
import { Aside } from "~/components";
11+
1012
Cloudflare Workers and most connected resources can be fully developed and tested locally - providing confidence that the applications you build locally will work the same way in production. This allows you to be more efficient and effective by providing a faster feedback loop and removing the need to [test against remote resources](#develop-using-remote-resources-and-bindings). Local development runs against the same production runtime used by Cloudflare Workers, [workerd](https://github.com/cloudflare/workerd).
1113

1214
In addition to testing Workers locally with [`wrangler dev`](/workers/wrangler/commands/#dev), the use of Miniflare allows you to test other Developer Platform products locally, such as [R2](/r2/), [KV](/kv/), [D1](/d1/), and [Durable Objects](/durable-objects/).
@@ -127,6 +129,19 @@ npx wrangler dev --remote
127129

128130
For some products like KV and R2, remote resources used for `wrangler dev --remote` must be specified with preview ID/names in the [Wrangler configuration file](/workers/wrangler/configuration/) such as `preview_id` for KV or `preview_bucket name` for R2. Resources used for remote mode (preview) can be different from resources used for production to prevent changing production data during development. To use production data in `wrangler dev --remote`, set the preview ID/name of the resource to the ID/name of your production resource.
129131

132+
<Aside
133+
type="note"
134+
title="Number of routes per zone in a remote development session"
135+
>
136+
When you run a remote development session using the `--remote` flag, a
137+
[limit](/workers/platform/limits/#routes-and-domains) of 50
138+
[routes](/workers/configuration/routing/routes/) per zone is enforced. The
139+
Quick Editor in the Cloudflare Dashboard also uses `wrangler dev --remote`, so
140+
any changes made there are subject to the same 50-route limit. If your zone
141+
has more than 50 routes, you **will not be able to run a remote session**. To
142+
fix this, you must remove routes until you are under the 50-route limit.
143+
</Aside>
144+
130145
## Customize `wrangler dev`
131146

132147
You can customize how `wrangler dev` works to fit your needs. Refer to [the `wrangler dev` documentation](/workers/wrangler/commands/#dev) for available configuration options.

src/content/docs/workers/platform/limits.mdx

Lines changed: 25 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,16 @@ import { Render } from "~/components";
1111

1212
## Account plan limits
1313

14-
| Feature | Workers Free | Workers Paid |
15-
| -------------------------------------------------------------------------------- | ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
14+
| Feature | Workers Free | Workers Paid |
15+
| -------------------------------------------------------------------------------- | ------------ | ------------ |
1616
| [Subrequests](#subrequests) | 50/request | 1000/request |
17-
| [Simultaneous outgoing<br/>connections/request](#simultaneous-open-connections) | 6 | 6 |
18-
| [Environment variables](#environment-variables) | 64/Worker | 128/Worker |
19-
| [Environment variable<br/>size](#environment-variables) | 5 KB | 5 KB |
20-
| [Worker size](#worker-size) | 3 MB | 10 MB |
21-
| [Worker startup time](#worker-startup-time) | 400 ms | 400 ms |
22-
| [Number of Workers](#number-of-workers)<sup>1</sup> | 100 | 500 |
23-
| Number of [Cron Triggers](/workers/configuration/cron-triggers/)<br/>per account | 5 | 250 |
17+
| [Simultaneous outgoing<br/>connections/request](#simultaneous-open-connections) | 6 | 6 |
18+
| [Environment variables](#environment-variables) | 64/Worker | 128/Worker |
19+
| [Environment variable<br/>size](#environment-variables) | 5 KB | 5 KB |
20+
| [Worker size](#worker-size) | 3 MB | 10 MB |
21+
| [Worker startup time](#worker-startup-time) | 400 ms | 400 ms |
22+
| [Number of Workers](#number-of-workers)<sup>1</sup> | 100 | 500 |
23+
| Number of [Cron Triggers](/workers/configuration/cron-triggers/)<br/>per account | 5 | 250 |
2424

2525
<sup>1</sup> If you are running into limits, your project may be a good fit for
2626
[Workers for Platforms](/cloudflare-for-platforms/workers-for-platforms/).
@@ -58,11 +58,11 @@ Cloudflare does not enforce response limits on response body sizes, but cache li
5858

5959
## Worker limits
6060

61-
| Feature | Workers Free | Workers Paid |
62-
| ------------------------ | ------------------------------------------ | ---------------- |
63-
| [Request](#request) | 100,000 requests/day<br/>1000 requests/min | No limit |
64-
| [Worker memory](#memory) | 128 MB | 128 MB |
65-
| [CPU time](#cpu-time) | 10 ms | 5 min HTTP request <br/> 15 min [Cron Trigger](/workers/configuration/cron-triggers/) |
61+
| Feature | Workers Free | Workers Paid |
62+
| ------------------------ | ------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
63+
| [Request](#request) | 100,000 requests/day<br/>1000 requests/min | No limit |
64+
| [Worker memory](#memory) | 128 MB | 128 MB |
65+
| [CPU time](#cpu-time) | 10 ms | 5 min HTTP request <br/> 15 min [Cron Trigger](/workers/configuration/cron-triggers/) |
6666
| [Duration](#duration) | No limit | No limit for Workers. <br/>15 min duration limit for [Cron Triggers](/workers/configuration/cron-triggers/), [Durable Object Alarms](/durable-objects/api/alarms/) and [Queue Consumers](/queues/configuration/javascript-apis/#consumer) |
6767

6868
### Duration
@@ -93,7 +93,7 @@ Scheduled Workers ([Cron Triggers](/workers/configuration/cron-triggers/)) have
9393

9494
## Cache API limits
9595

96-
| Feature | Workers Free | Workers Paid
96+
| Feature | Workers Free | Workers Paid |
9797
| ---------------------------------------- | ------------ | ------------ |
9898
| [Maximum object size](#cache-api-limits) | 512 MB | 512 MB |
9999
| [Calls/request](#cache-api-limits) | 50 | 1,000 |
@@ -290,6 +290,10 @@ If you need more than 500 Workers, consider using [Workers for Platforms](/cloud
290290

291291
Each zone has a limit of 1,000 [routes](/workers/configuration/routing/routes/). If you require more than 1,000 routes on your zone, consider using [Workers for Platforms](/cloudflare-for-platforms/workers-for-platforms/) or request an increase to this limit.
292292

293+
### Number of routes per zone when using `wrangler dev --remote`
294+
295+
When you run a [remote development](/workers/local-development/#develop-using-remote-resources-and-bindings) session using the `--remote` flag, a limit of 50 [routes](/workers/configuration/routing/routes/) per zone is enforced. The Quick Editor in the Cloudflare Dashboard also uses `wrangler dev --remote`, so any changes made there are subject to the same 50-route limit. If your zone has more than 50 routes, you **will not be able to run a remote session**. To fix this, you must remove routes until you are under the 50-route limit.
296+
293297
### Number of custom domains per zone
294298

295299
Each zone has a limit of 100 [custom domains](/workers/configuration/routing/custom-domains/). If you require more than 100 custom domains on your zone, consider using a wildcard [route](/workers/configuration/routing/routes/) or request an increase to this limit.
@@ -323,10 +327,11 @@ Unbound and Bundled plans have been deprecated and are no longer available for n
323327
If your Worker is on an Unbound plan, your limits are exactly the same as the Workers Paid plan.
324328

325329
If your Worker is on a Bundled plan, your limits are the same as the Workers Paid plan except for the following differences:
326-
* Your limit for [subrequests](/workers/platform/limits/#subrequests) is 50/request
327-
* Your limit for [CPU time](/workers/platform/limits/#cpu-time) is 50ms for HTTP requests and 50ms for [Cron Triggers](/workers/configuration/cron-triggers/)
328-
* You have no [Duration](/workers/platform/limits/#duration) limits for [Cron Triggers](/workers/configuration/cron-triggers/), [Durable Object alarms](/durable-objects/api/alarms/), or [Queue consumers](/queues/configuration/javascript-apis/#consumer)
329-
* Your Cache API limits for calls/requests is 50
330+
331+
- Your limit for [subrequests](/workers/platform/limits/#subrequests) is 50/request
332+
- Your limit for [CPU time](/workers/platform/limits/#cpu-time) is 50ms for HTTP requests and 50ms for [Cron Triggers](/workers/configuration/cron-triggers/)
333+
- You have no [Duration](/workers/platform/limits/#duration) limits for [Cron Triggers](/workers/configuration/cron-triggers/), [Durable Object alarms](/durable-objects/api/alarms/), or [Queue consumers](/queues/configuration/javascript-apis/#consumer)
334+
- Your Cache API limits for calls/requests is 50
330335

331336
---
332337

@@ -336,4 +341,4 @@ Review other developer platform resource limits.
336341

337342
- [KV limits](/kv/platform/limits/)
338343
- [Durable Object limits](/durable-objects/platform/limits/)
339-
- [Queues limits](/queues/platform/limits/)
344+
- [Queues limits](/queues/platform/limits/)

0 commit comments

Comments
 (0)