mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-04 01:42:15 +08:00
Signed-off-by: longjiquan <jiquan.long@zilliz.com> Signed-off-by: longjiquan <jiquan.long@zilliz.com>
22 lines
787 B
Go
22 lines
787 B
Go
package migration
|
|
|
|
type Migration interface {
|
|
// Validate if migration can be executed. For example, higher version to lower version is not allowed.
|
|
Validate() error
|
|
// CheckCompatible check if target is compatible with source. If compatible, no migration should be executed.
|
|
CheckCompatible() bool
|
|
// CheckSessions check if any sessions are alive. Abort migration if any.
|
|
CheckSessions() error
|
|
// RegisterSession register session to avoid any other migration is also running, registered session will be deleted
|
|
// as soon as possible after migration is done.
|
|
RegisterSession() error
|
|
// Backup source meta information.
|
|
Backup() error
|
|
// Migrate to target backend.
|
|
Migrate() error
|
|
// Rollback migration.
|
|
Rollback() error
|
|
// Stop complete the migration overflow.
|
|
Stop()
|
|
}
|