{"record":{"id":"4af1a0df927b2bfe","repo":"apache/hadoop","slug":"delete-missing-is-applicable-only-with-update-or-o","errorCode":null,"errorMessage":"Delete missing is applicable only with update or overwrite options","messagePattern":"Delete missing is applicable only with update or overwrite options","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"hadoop-tools/hadoop-distcp/src/main/java/org/apache/hadoop/tools/DistCpOptions.java","lineNumber":605,"sourceCode":"    private void validate() {\n      if ((useDiff || useRdiff) && deleteMissing) {\n        // -delete and -diff/-rdiff are mutually exclusive.\n        throw new IllegalArgumentException(\"-delete and -diff/-rdiff are \"\n            + \"mutually exclusive. The -delete option will be ignored.\");\n      }\n\n      if (!atomicCommit && atomicWorkPath != null) {\n        throw new IllegalArgumentException(\n            \"-tmp work-path can only be specified along with -atomic\");\n      }\n\n      if (syncFolder && atomicCommit) {\n        throw new IllegalArgumentException(\"Atomic commit can't be used with \"\n            + \"sync folder or overwrite options\");\n      }\n\n      if (deleteMissing && !(overwrite || syncFolder)) {\n        throw new IllegalArgumentException(\"Delete missing is applicable \"\n            + \"only with update or overwrite options\");\n      }\n\n      if (overwrite && syncFolder) {\n        throw new IllegalArgumentException(\"Overwrite and update options are \"\n            + \"mutually exclusive\");\n      }\n\n      if (!syncFolder && append) {\n        throw new IllegalArgumentException(\n            \"Append is valid only with update options\");\n      }\n      if (skipCRC && append) {\n        throw new IllegalArgumentException(\n            \"Append is disallowed when skipping CRC\");\n      }\n      if (!syncFolder && (useDiff || useRdiff)) {\n        throw new IllegalArgumentException(","sourceCodeStart":587,"sourceCodeEnd":623,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-tools/hadoop-distcp/src/main/java/org/apache/hadoop/tools/DistCpOptions.java#L587-L623","documentation":"Error \"Delete missing is applicable only with update or overwrite options\" thrown in apache/hadoop.","triggerScenarios":"distcp -delete is specified without -update or -overwrite.","commonSituations":"See trigger scenarios.","solutions":["Use -delete only together with -update or -overwrite.","Drop -delete if neither update nor overwrite is requested."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2add9630210752f88ceb1bb74eb65e37bf41da8e","analyzedAt":"2026-08-22T19:55:07.957Z","schemaVersion":2},"datasetVersion":"2026-08-22T20:17:22.307Z"}