add documentation for logicalcluster migration#4242
Conversation
|
/retest |
1 similar comment
|
/retest |
/test pull-kcp-test-e2e-sharded |
ntnn
left a comment
There was a problem hiding this comment.
Just two comments, thanks for adding the docs!
| - The `migration.kcp.io` API is bound in the workspace where you want to create the | ||
| `LogicalClusterMigration` resource (typically the parent of the workspace being migrated) |
There was a problem hiding this comment.
| - The `migration.kcp.io` API is bound in the workspace where you want to create the | |
| `LogicalClusterMigration` resource (typically the parent of the workspace being migrated) | |
| - The `migration.kcp.io` API is bound in the workspace where you want to create the `LogicalClusterMigration` resource |
I wouldn't give a recommendation where to bind the API. I can see e.g. an operator that rebalances shards to get a workspaces to themselves just for LogicalClusterMigrations or admins manually creating them in the root workspace, ...
| server | ||
| - The `migration.kcp.io` API is bound in the workspace where you want to create the | ||
| `LogicalClusterMigration` resource (typically the parent of the workspace being migrated) | ||
| - No other migration is currently in progress for the same logical cluster |
There was a problem hiding this comment.
| - No other migration is currently in progress for the same logical cluster |
The process ensures that only one LCM affects an LC - if an LCM for an LC in migration is created it is placed into a failstate.
Though we should have a test for that, I don't think we do at the moment.
| The migration proceeds through several phases: | ||
|
|
||
| | Phase | Description | | ||
| |-------|-------------| | ||
| | `Preparing` | Origin shard marks the logical cluster as migrating, cancels active connections, and purges informer caches | | ||
| | `Migrating` | Destination shard pulls all etcd data from the origin via the migration virtual workspace | | ||
| | `OriginCleanup` | Origin shard deletes all etcd data belonging to the logical cluster | | ||
| | `DestinationFinalize` | Destination shard removes the migration annotation and updates informers | | ||
| | `Completed` | Migration finished successfully | | ||
| | `Failed` | Migration encountered an unrecoverable error | |
There was a problem hiding this comment.
I think it'd be better to just link the doc.go in the logicalclustermigration package, iirc @SimonTheLeg is already adding some more phases for defensiveness.
There was a problem hiding this comment.
yup there will be new phases introduced. So probably makes the most sense
|
LGTM label has been added. DetailsGit tree hash: 61ee331eea2f66297e06c6959271d549065facc6 |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ntnn The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/retest |
2 similar comments
|
/retest |
|
/retest |
Summary
This adds basic documentation on how the cluster migration works.
What Type of PR Is This?
/kind documentation
Related Issue(s)
Fixes #4203
Release Notes