{"record":{"id":"0fc63e5e4d814f70","repo":"risingwavelabs/risingwave","slug":"not-supported-write-model-v1-to-meta-store-v2","errorCode":null,"errorMessage":"not supported: write model V1 to meta store V2","messagePattern":"not supported: write model V1 to meta store V2","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/meta/src/backup_restore/restore.rs","lineNumber":191,"sourceCode":"        }\n        Some(s) => s,\n    };\n\n    if opts.validate_integrity {\n        tracing::info!(\"Start integrity validation.\");\n        validate_integrity(\n            snapshot.objects.clone(),\n            &opts.hummock_storage_url,\n            &opts.hummock_storage_directory,\n        )\n        .await\n        .inspect_err(|_| tracing::error!(\"Fail integrity validation.\"))?;\n        tracing::info!(\"Succeed integrity validation.\");\n    }\n\n    let format_version = snapshot.format_version;\n    if format_version < 2 {\n        unimplemented!(\"not supported: write model V1 to meta store V2\");\n    } else {\n        dispatch(\n            target_id,\n            &opts,\n            LoaderV2::new(backup_store),\n            WriterModelV2ToMetaStoreV2::new(meta_store),\n        )\n        .await?;\n    }\n\n    Ok(())\n}\n\nasync fn dispatch<L: Loader<S>, W: Writer<S>, S: Metadata>(\n    target_id: MetaSnapshotId,\n    opts: &RestoreOpts,\n    loader: L,\n    writer: W,","sourceCodeStart":173,"sourceCodeEnd":209,"githubUrl":"https://github.com/risingwavelabs/risingwave/blob/6469eb736d691e8e9b8a419a57edd6429ca77417/src/meta/src/backup_restore/restore.rs#L173-L209","documentation":"Meta store model V2 cannot accept snapshots written with format_version < 2 (write model V1); restore_impl calls `unimplemented!` to abort. Upgrading from V1 backups to a V2 meta store is unsupported — the snapshot must be migrated by other means.","triggerScenarios":"Restoring a meta snapshot whose `format_version` is 1 (or 0) into a current meta store that expects V2 write model.","commonSituations":"Using a very old RisingWave backup (pre-V2 format) with a modern binary after the storage format change.","solutions":["Restore the V1 snapshot with an older RisingWave version that supports V1 write model, then upgrade and take a new backup","Regenerate a V2-format backup before attempting restore on the current binary","Do not attempt direct V1 restore; migrate data via the intermediate version"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"if snapshot.format_version < 2 {\n    return Err(anyhow!(\"V1 snapshot cannot be restored to V2 meta store; migrate via intermediate version\"));\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Recreate backups with the current RisingWave version after upgrades","Document snapshot format versions alongside stored backups","Test restore procedures after version upgrades"],"tags":["rust","meta","restore","version-compatibility"],"backgroundTag":"incompatible-source-type","analyzedSha":"6469eb736d691e8e9b8a419a57edd6429ca77417","analyzedAt":"2026-09-11T21:06:21.487Z","contentChangedAt":"2026-09-11T21:06:21.487Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}