Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions public/__redirects
Original file line number Diff line number Diff line change
Expand Up @@ -2259,7 +2259,7 @@
/workers/platform/sites/configuration/ /workers/configuration/sites/configuration/ 301
/workers/platform/deploy-button/ /workers/platform/deploy-buttons/ 301
/workers/configuration/deploy-button/ /workers/platform/deploy-buttons/ 301
/workers/platform/deployments/ /workers/configuration/versions-and-deployments/ 301
/workers/platform/deployments/ /workers/versions-and-deployments/ 301
/workers/platform/environment-variables/ /workers/configuration/environment-variables/ 301
/workers/platform/smart-placement/ /workers/configuration/placement/ 301
/workers/configuration/smart-placement/ /workers/configuration/placement/ 301
Expand All @@ -2280,7 +2280,12 @@
/workers/runtime-apis/service-bindings/ /workers/runtime-apis/bindings/service-bindings/ 301
/workers/observability/local-development-and-testing/ /workers/local-development/ 301
/workers/observability/sentry-integration/ /workers/observability/integrations/sentry 301
/workers/configuration/deployments/ /workers/configuration/versions-and-deployments/ 301
/workers/configuration/deployments/ /workers/versions-and-deployments/ 301
/workers/configuration/versions-and-deployments/ /workers/versions-and-deployments/ 301
/workers/configuration/versions-and-deployments/gradual-deployments/ /workers/versions-and-deployments/gradual-deployments/ 301
/workers/configuration/versions-and-deployments/version-overrides/ /workers/versions-and-deployments/version-overrides/ 301
/workers/configuration/versions-and-deployments/rollbacks/ /workers/versions-and-deployments/rollbacks/ 301
/workers/static-assets/routing/advanced/gradual-rollouts/ /workers/versions-and-deployments/gradual-deployments/version-affinity/ 301
/workers/configuration/continuous-integration/ /workers/ci-cd/ 301
/workers/wrangler/ci-cd/ /workers/ci-cd/external-cicd/ 301
/workers/tutorials/hello-world-rust/ /workers/tutorials/ 301
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ We've revamped the [Workers Metrics dashboard](https://dash.cloudflare.com/?to=/

![Workers Metrics dashboard](~/assets/images/workers/observability/workers-metrics.png)

Now you can easily compare metrics across Worker versions, understand the current state of a [gradual deployment](/workers/configuration/versions-and-deployments/gradual-deployments/), and review key Workers metrics in a single view. This new interface enables you to:
Now you can easily compare metrics across Worker versions, understand the current state of a [gradual deployment](/workers/versions-and-deployments/gradual-deployments/), and review key Workers metrics in a single view. This new interface enables you to:

- Drag-and-select using a graphical timepicker for precise metric selection.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ This dual approach means:
## Learn more
- [Infrastructure as Code (IaC) guide](/workers/platform/infrastructure-as-code)
- [API documentation](/api/resources/workers/subresources/beta/)
- [Versions and Deployments overview](/workers/configuration/versions-and-deployments/)
- [Versions and Deployments overview](/workers/versions-and-deployments/)

## Technical notes

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ This allows you to:

* Promote any of the 100 most recent versions to be the active deployment.

* Split traffic using [gradual deployments](/workers/configuration/versions-and-deployments/gradual-deployments/) between your latest code and any of the 100 most recent versions.
* Split traffic using [gradual deployments](/workers/versions-and-deployments/gradual-deployments/) between your latest code and any of the 100 most recent versions.

You can do this through the Cloudflare dashboard or with [Wrangler's rollback command](/workers/wrangler/commands/general/#rollback)

Learn more about [versioned deployments](/workers/configuration/versions-and-deployments/) and [rollbacks](/workers/configuration/versions-and-deployments/rollbacks/).
Learn more about [versioned deployments](/workers/versions-and-deployments/) and [rollbacks](/workers/versions-and-deployments/rollbacks/).
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ You can set a maximum of eight tags per script. Avoid special characters like `,

## Gradual Deployments

[Gradual Deployments](/workers/configuration/versions-and-deployments/gradual-deployments/) is not supported yet for user Workers. Changes made to user Workers create a new version that deployed all-at-once to 100% of traffic.
[Gradual Deployments](/workers/versions-and-deployments/gradual-deployments/) is not supported yet for user Workers. Changes made to user Workers create a new version that deployed all-at-once to 100% of traffic.

## API Rate Limits

Expand Down
2 changes: 1 addition & 1 deletion src/content/docs/containers/platform-details/limits.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,4 @@ The following limits apply per account:
| Image size | Same as [instance disk space](#instance-types) |
| Total image storage per account | 50 GB [^1] |

[^1]: Delete container images with `wrangler containers delete` to free up space. If you delete a container image and then [roll back](/workers/configuration/versions-and-deployments/rollbacks/) your Worker to a previous version, this version may no longer work.
[^1]: Delete container images with `wrangler containers delete` to free up space. If you delete a container image and then [roll back](/workers/versions-and-deployments/rollbacks/) your Worker to a previous version, this version may no longer work.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ storage. Durable Objects
<GlossaryTooltip term="Storage API">Storage API</GlossaryTooltip> provides
access to a Durable Object's attached storage.

A Durable Object's [in-memory state](/durable-objects/reference/in-memory-state/) is preserved as long as the Durable Object is not evicted from memory. Inactive Durable Objects with no incoming request traffic can be evicted. There are normal operations like [code deployments](/workers/configuration/versions-and-deployments/) that trigger Durable Objects to restart and lose their in-memory state. For these reasons, you should use Storage API to persist state durably on disk that needs to survive eviction or restart of Durable Objects.
A Durable Object's [in-memory state](/durable-objects/reference/in-memory-state/) is preserved as long as the Durable Object is not evicted from memory. Inactive Durable Objects with no incoming request traffic can be evicted. There are normal operations like [code deployments](/workers/versions-and-deployments/) that trigger Durable Objects to restart and lose their in-memory state. For these reasons, you should use Storage API to persist state durably on disk that needs to survive eviction or restart of Durable Objects.

## Access storage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ A Durable Object incurs charges only when it is **actively running in-memory**,

Durable Objects will occasionally shut down and objects are restarted, which will run your Durable Object class constructor. This can happen for various reasons, including:

- New Worker [deployments](/workers/configuration/versions-and-deployments/) with code updates
- New Worker [deployments](/workers/versions-and-deployments/) with code updates
- Lack of requests to an object following the state transitions documented above
- Cloudflare updates to the Workers runtime system
- Workers runtime decisions on where to host objects
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ A Durable Object may be replaced in the event of a network partition or a softwa

## Code updates

Code changes for Workers and Durable Objects are released globally in an eventually consistent manner. Because each Durable Object is globally unique, the situation can arise that a request arrives to the latest version of your Worker (running in one part of the world), which then calls to a unique Durable Object running the previous version of your code for a short period of time (typically seconds to minutes). If you create a [gradual deployment](/workers/configuration/versions-and-deployments/gradual-deployments/), this period of time is determined by how long your live deployment is configured to use more than one version.
Code changes for Workers and Durable Objects are released globally in an eventually consistent manner. Because each Durable Object is globally unique, the situation can arise that a request arrives to the latest version of your Worker (running in one part of the world), which then calls to a unique Durable Object running the previous version of your code for a short period of time (typically seconds to minutes). If you create a [gradual deployment](/workers/versions-and-deployments/gradual-deployments/), this period of time is determined by how long your live deployment is configured to use more than one version.

For this reason, it is best practice to ensure that API changes between your Workers and Durable Objects are forward and backward compatible across code updates.

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
pcx_content_type: navigation
title: Gradual Deployments
external_link: /workers/configuration/versions-and-deployments/gradual-deployments/#gradual-deployments-for-durable-objects
external_link: /workers/versions-and-deployments/gradual-deployments/#gradual-deployments-for-durable-objects
sidebar:
order: 10
head: []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -410,5 +410,5 @@ Note that `.toml` files do not allow line breaks in inline tables (the `{key = "
You cannot enable a SQLite storage backend on an existing, deployed Durable Object class, so setting `new_sqlite_classes` on later migrations will fail with an error. Automatic migration of deployed classes from their key-value storage backend to SQLite storage backend will be available in the future.

:::caution[Important]
Durable Object migrations are atomic operations and cannot be gradually deployed. To provide early feedback to developers, new Worker versions with new migrations cannot be uploaded. Refer to [Gradual deployments for Durable Objects](/workers/configuration/versions-and-deployments/gradual-deployments/#gradual-deployments-for-durable-objects) for more information.
Durable Object migrations are atomic operations and cannot be gradually deployed. To provide early feedback to developers, new Worker versions with new migrations cannot be uploaded. Refer to [Gradual deployments for Durable Objects](/workers/versions-and-deployments/gradual-deployments/#gradual-deployments-for-durable-objects) for more information.
:::
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ The command above will output the ID of your Hyperdrive. Set this ID in the [Wra

</WranglerConfig>

To update your Worker to use the new Hyperdrive configuration, redeploy your Worker or use [gradual deployments](/workers/configuration/versions-and-deployments/gradual-deployments/).
To update your Worker to use the new Hyperdrive configuration, redeploy your Worker or use [gradual deployments](/workers/versions-and-deployments/gradual-deployments/).

## Update the existing Hyperdrive configuration

Expand Down
2 changes: 1 addition & 1 deletion src/content/docs/kv/examples/routing-with-workers-kv.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ In single-tenant applications, this can be used to route requests to various ori
In multi-tenant applications, requests can be routed to the tenant's respective origin resources (for example, requests to `tenantA.your-worker-hostname.com` routed to server for Tenant A, `tenantB.your-worker-hostname.com` routed to server for Tenant B).

Routing can also be used to implement [A/B testing](/reference-architecture/diagrams/serverless/a-b-testing-using-workers/), canary deployments, or [blue-green deployments](https://en.wikipedia.org/wiki/Blue%E2%80%93green_deployment) for your own external applications.
If you are looking to implement canary or blue-green deployments of applications built fully on Cloudflare Workers, see [Workers gradual deployments](/workers/configuration/versions-and-deployments/gradual-deployments/).
If you are looking to implement canary or blue-green deployments of applications built fully on Cloudflare Workers, see [Workers gradual deployments](/workers/versions-and-deployments/gradual-deployments/).

## Route requests with Workers KV

Expand Down
2 changes: 1 addition & 1 deletion src/content/docs/rules/snippets/when-to-use.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ Snippets are ideal for fast, cost-free request and response modifications at the
| Support non-HTTP [protocols](/workers/reference/protocols/) |||
| Analyze execution [logs](/workers/observability/logs/workers-logs/) and track performance metrics |||
| Deploy via [command-line interface (CLI)](/workers/wrangler/) |||
| Roll out gradually, roll back to previous [versions](/workers/configuration/versions-and-deployments/) |||
| Roll out gradually, roll back to previous [versions](/workers/versions-and-deployments/) |||
| Optimize execution with [Smart Placement](/workers/configuration/placement/) |||

---
Expand Down
4 changes: 2 additions & 2 deletions src/content/docs/workers/ci-cd/builds/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ For details about supported frameworks and what files are created, refer to [Dep

You can monitor a build's status and its build logs by navigating to **View build history** at the bottom of the **Deployments** tab of your Worker.

If the build is successful, you can view the build details by selecting **View build** in the associated new [version](/workers/configuration/versions-and-deployments/) created under Version History. There you will also find the [preview URL](/workers/configuration/previews/) generated by the version under Version ID.
If the build is successful, you can view the build details by selecting **View build** in the associated new [version](/workers/versions-and-deployments/) created under Version History. There you will also find the [preview URL](/workers/configuration/previews/) generated by the version under Version ID.

:::note[Builds, versions, deployments]

Expand All @@ -81,4 +81,4 @@ To disconnect a Worker from a GitHub or GitLab repository:

If you want to switch to a different repository for your Worker, you must first disable builds, then reconnect to select the new repository.

To disable automatic deployments while still allowing builds to run automatically and save as [versions](/workers/configuration/versions-and-deployments/) (without promoting them to an active deployment), update your deploy command to: `npx wrangler versions upload`.
To disable automatic deployments while still allowing builds to run automatically and save as [versions](/workers/versions-and-deployments/) (without promoting them to an active deployment), update your deploy command to: `npx wrangler versions upload`.
2 changes: 1 addition & 1 deletion src/content/docs/workers/ci-cd/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ pcx_content_type: concept
title: CI/CD
description: Set up continuous integration and continuous deployment for your Workers.
sidebar:
order: 9
order: 10
products:
- workers
---
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ At a minimum, the `main_module` key is required to upload a Worker.

## Additional attributes: [Workers Script Upload API](/api/resources/workers/subresources/scripts/methods/update/)

For [immediately deployed uploads](/workers/configuration/versions-and-deployments/#upload-a-new-version-and-deploy-it-immediately), the following **additional** attributes are configurable at the top-level.
For [immediately deployed uploads](/workers/versions-and-deployments/#upload-a-new-version-and-deploy-it-immediately), the following **additional** attributes are configurable at the top-level.

:::note

Expand All @@ -99,7 +99,7 @@ Except for `annotations`, these attributes are **not available** for version upl

## Additional attributes: [Version Upload API](/api/resources/workers/subresources/scripts/subresources/versions/methods/create/)

For [version uploads](/workers/configuration/versions-and-deployments/#upload-a-new-version-to-be-gradually-deployed-or-deployed-at-a-later-time), the following **additional** attributes are configurable at the top-level.
For [version uploads](/workers/versions-and-deployments/#upload-a-new-version-to-be-gradually-deployed-or-deployed-at-a-later-time), the following **additional** attributes are configurable at the top-level.

- `annotations` <Type text="object" /> <MetaInfo text="optional" />
- Annotations object specific to the Worker version.
Expand Down
6 changes: 3 additions & 3 deletions src/content/docs/workers/configuration/previews.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Preview URLs can be:
- Used for collaboration between teams to test code changes in a live environment and verify updates.
- Used to test new API endpoints, validate data formats, and ensure backward compatibility with existing services.

When testing zone level performance or security features for a version, we recommend using [version overrides](/workers/configuration/versions-and-deployments/version-overrides/) so that your zone's performance and security settings apply.
When testing zone level performance or security features for a version, we recommend using [version overrides](/workers/versions-and-deployments/version-overrides/) so that your zone's performance and security settings apply.

:::note
Preview URLs are only available for Worker versions uploaded after 2024-09-25.
Expand All @@ -36,7 +36,7 @@ Preview URLs are only available for Worker versions uploaded after 2024-09-25.

### Versioned Preview URLs

Every time you create a new [version](/workers/configuration/versions-and-deployments/#versions) of your Worker, a unique static version preview URL is generated automatically. These URLs use a version prefix and follow the format `<VERSION_PREFIX>-<WORKER_NAME>.<SUBDOMAIN>.workers.dev`.
Every time you create a new [version](/workers/versions-and-deployments/#versions) of your Worker, a unique static version preview URL is generated automatically. These URLs use a version prefix and follow the format `<VERSION_PREFIX>-<WORKER_NAME>.<SUBDOMAIN>.workers.dev`.

New versions of a Worker are created when you run:

Expand All @@ -52,7 +52,7 @@ Minimum required Wrangler version: 3.74.0. Check your version by running `wrangl

#### View versioned preview URLs using Wrangler

The [`wrangler versions upload`](/workers/wrangler/commands/general/#versions-upload) command uploads a new [version](/workers/configuration/versions-and-deployments/#versions) of your Worker and returns a preview URL for each version uploaded.
The [`wrangler versions upload`](/workers/wrangler/commands/general/#versions-upload) command uploads a new [version](/workers/versions-and-deployments/#versions) of your Worker and returns a preview URL for each version uploaded.

#### View versioned preview URLs on the Workers dashboard

Expand Down
Loading