{"record":{"id":"3a6d7e2d7d8f3283","repo":"influxdata/influxdb","slug":"each-subsequent-generation-must-be-an-even-multiple-of-its","errorCode":null,"errorMessage":"each subsequent generation must be an even multiple of its predecessor","messagePattern":"each subsequent generation must be an even multiple of its predecessor","errorType":"validation","errorClass":"EnterpriseCatalogError","httpStatus":null,"severity":"error","filePath":"influxdb3_catalog/src/error/enterprise.rs","lineNumber":52,"sourceCode":"    #[error(\n        \"too many compacted generations requested, maximum allowed: 254, requested: {requested}\"\n    )]\n    TooManyCompactedGenerations { requested: usize },\n\n    #[error(\"gen1 duration is not configured in the catalog\")]\n    MissingGen1Duration,\n\n    #[error(\n        \"gen2 duration must be an even multiple of gen1 duration, \\\n        provided gen2 duration: {gen2_duration_secs} seconds, \\\n        existing gen1 duration: {gen1_duration_secs} seconds\"\n    )]\n    InvalidGen2Duration {\n        gen2_duration_secs: u64,\n        gen1_duration_secs: u64,\n    },\n\n    #[error(\"each subsequent generation must be an even multiple of its predecessor\")]\n    MisalignedGenerations,\n}\n","sourceCodeStart":34,"sourceCodeEnd":55,"githubUrl":"https://github.com/influxdata/influxdb/blob/06200ef96ba82c5f6727e5038a83af8e722c6875/influxdb3_catalog/src/error/enterprise.rs#L34-L55","documentation":"EnterpriseCatalogError::MisalignedGenerations. Raised when the full generation-duration chain (gen1, gen2, gen3, ...) is not strictly nested: each generation duration must be an even multiple of the previous one. This generalizes the gen2 check to the whole chain.","triggerScenarios":"Configuring three or more generation durations where a later duration is not an even multiple of its predecessor — e.g. gen1=10m, gen2=60m, gen3=100m (100 not a multiple of 60).","commonSituations":"Hand-editing generation duration lists; partial config updates that change one duration but not its successor; automation generating durations from independent knobs.","solutions":["Redesign the duration chain so each level is an integer multiple of the previous (e.g. 10m -> 60m -> 360m).","Validate the whole chain in deployment config before applying it to the catalog.","Update all dependent durations together when any single duration changes.","Add a preflight script asserting durations[i+1] % durations[i] == 0 for all i."],"exampleFix":"// before\ngen_durations = [10m, 60m, 100m]  // 100 % 60 != 0\n// after\ngen_durations = [10m, 60m, 360m]  // each an even multiple of its predecessor","handlingStrategy":"validation","validationCode":"fn generations_aligned(durs: &[u64]) -> bool {\n    durs.windows(2).all(|w| w[1] % w[0] == 0)\n}\n// call before applying any duration chain","typeGuard":null,"tryCatchPattern":"match result {\n    Err(EnterpriseCatalogError::MisalignedGenerations) =>\n        eprintln!(\"each generation duration must be an even multiple of its predecessor\"),\n    other => other?,\n}","preventionTips":["Validate the entire duration chain before writing it to the catalog","Change all chain levels together when adjusting any duration","Generate durations programmatically from a base and multipliers","Keep durations in a config file with a lint rule for divisibility"],"tags":["enterprise","generations","duration","configuration"],"backgroundTag":"invalid-config-value","analyzedSha":"06200ef96ba82c5f6727e5038a83af8e722c6875","analyzedAt":"2026-09-19T12:55:30.003Z","contentChangedAt":"2026-09-19T12:55:30.003Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}