Migrate Cloud Graphs to Self-Hosted

Migrate your graph from cloud-hosted to self-hosted


The Serverless and Dedicated plans end on [TODO SUNSET DATE]. After this date, cloud routers are no longer available.

If you are on a Serverless or Dedicated plan, migrate your graphs to use self-hosted routers by [TODO SUNSET DATE]. After migrating your graphs, move your organization to a supported plan.

During the migration window, your cloud router continues to receive traffic, schema updates, and configuration updates. The migration window ends on [TODO SUNSET DATE].

This guide provides step-by-step instructions to migrate graphs on Serverless or Dedicated plans to self-hosted graphs on a supported plan. Complete these steps before [TODO SUNSET DATE]:

  1. Export your cloud router configuration

  2. Change your graph's hosting mode to self-hosted

  3. Deploy a self-hosted router

  4. Validate and shift traffic to your self-hosted endpoint

  5. Move your organization to a supported plan

Steps to migrate

Export your cloud router configuration

You need this router configuration in a later step when you deploy your self-hosted router.

Export your cloud router configuration using one of the following methods:

Using Studio

In Studio, navigate to your graph's Cloud Router page and click the Router configuration YAML tab to download the configuration.

Cloud Router configuration in GraphOS Studio

If you can't access the Cloud Router page (for example, if you have already changed your graph's hosting mode), use the Rover CLI to export the configuration.

Using the Rover CLI

Use the cloud config fetch command. Install and configure the Rover CLI to run this command.

Replace the <GRAPH_REF> placeholder in the following command with your graph ref to download the router configuration YAML to a local router.yaml file.

Bash
rover cloud config fetch <GRAPH_REF> > router.yaml

Change the graph's hosting mode to self-hosted

In Studio, click the Start the migration process button at the top of the graph variant's page to change the graph's hosting mode to self-hosted.

During the migration window, the cloud router remains running and continues to receive schema and configuration updates.

Deploy a self-hosted router

Deploy a self-hosted router using your preferred platform.

For Kubernetes deployments, use the Apollo GraphOS Operator.

For other platforms, see the following guides:

Use the router configuration YAML you exported in the previous step to configure your self-hosted router.

Validate and shift traffic

Validate the new endpoint, then gradually shift production traffic from the cloud router to your self-hosted endpoint.

Move your organization to a supported plan

After you migrate all graphs to self-hosted mode, navigate to [TODO] to move your organization to a supported plan.

Frequently asked questions

What happens to your running cloud routers when you change your graph's hosting mode?

Changing a graph's hosting mode doesn't affect running cloud routers. Cloud routers continue to receive traffic, emit telemetry, and receive schema and configuration updates until a shutdown event occurs for Serverless routers or the migration period ends on [TODO SUNSET DATE].

How do you retrieve and update the configuration of your running cloud routers after converting to self-hosted mode?

Use the cloud config fetch command to fetch your cloud router configuration. Install and configure the Rover CLI to run this command.

Bash
rover cloud config fetch <GRAPH_REF> > router.yaml

Use the cloud config update command to update your running cloud routers' configuration. For example, to apply changes from a local router.yaml:

Bash
rover cloud config update --file router.yaml <GRAPH_REF>
Feedback

Edit on GitHub

Ask Community