Flink Forward 2025 Barcelona: The Future of AI is Real-Time
On Ververica Platform, I would like to move a Deployment from one Namespace to another, e.g. after upgrading from the Community Edition to the Stream Edition. How can this be done?
Note: This section applies to Ververica Platform Stream Edition 2.0 or later.
The following four steps will guide you through the process of moving a deployment from one namespace to another namespace:
1) Stop your running deployment with a savepoint, e.g. via the "suspend" button, in the original namespace
2) Note the most recent snapshot's URI, e.g. via the "Snapshots" tab, then click "Actions" for the latest savepoint, and select "Copy URI to Clipboard".
3) Re-create the deployment in the new namespace:
Create Deployment
's YAML editor in the new namespacespec.state
to CANCELLED
restoreStrategy.kind
is either LATEST_SAVEPOINT
or LATEST_STATE
spec.deploymentTargetId
to a deployment target of your new namespace (either in the YAML editor if you know the new ID, or by switching to the Standard editor and changing it there) Create Deployment
4) Add a savepoint to the new deployment in the new namespace with the savepoint URI noted above by clicking "Add Savepoint Manually" under "Snapshots" tab. For Ververica Platform before 2.7, you can use the REST API to add Savepoint Resource. The REST API call can also be done using the platform's swagger interface through <ververica-platform-url>/swagger:
If you now browse to the new deployment and click into the "Snapshots" tab, you should see the added savepoint under the "Next job will use the following snapshot" section.
If that is the case, you can simply start the deployment again and remove the old deployment from the original namespace after verifying the new setup is working correctly.
Note: There are a few technical details to point out:
deploymentId
will be different from the old one.${baseUri}/flink-savepoints/namespaces/${ns}/deployments/${deploymentId}
using the new namespace (similarly, checkpoints).