{"record":{"id":"b0ea7c8c68e212bc","repo":"quarkusio/quarkus","slug":"conflictstrategyhandler-named-entry-getvalue","errorCode":null,"errorMessage":"ConflictStrategyHandler named '\" + entry.getValue() + \"' not found. Used with filter '\" + entry.getKey() + \"'","messagePattern":"ConflictStrategyHandler named '\" \\+ entry\\.getValue\\(\\) \\+ \"' not found\\. Used with filter '\" \\+ entry\\.getKey\\(\\) \\+ \"'","errorType":"exception","errorClass":"CodestartStructureException","httpStatus":null,"severity":"error","filePath":"independent-projects/tools/codestarts/src/main/java/io/quarkus/devtools/codestarts/core/CodestartProcessor.java","lineNumber":94,"sourceCode":"        }\n    }\n\n    public void writeFiles() throws IOException {\n        for (Map.Entry<String, List<TargetFile>> e : files.entrySet()) {\n            final String relativePath = e.getKey();\n            final CodestartFileStrategyHandler strategy = getStrategy(relativePath).orElse(getSelectedDefaultStrategy());\n            log.debug(\"processing file '%s' with strategy %s\", relativePath, strategy.name());\n            strategy.process(targetDirectory, relativePath, e.getValue(), data);\n        }\n    }\n\n    public static List<CodestartFileStrategy> buildStrategies(Map<String, String> spec) {\n        final List<CodestartFileStrategy> codestartFileStrategyHandlers = new ArrayList<>(spec.size());\n\n        for (Map.Entry<String, String> entry : spec.entrySet()) {\n            final CodestartFileStrategyHandler handler = CodestartFileStrategyHandler.BY_NAME.get(entry.getValue());\n            if (handler == null) {\n                throw new CodestartStructureException(\"ConflictStrategyHandler named '\" + entry.getValue()\n                        + \"' not found. Used with filter '\" + entry.getKey() + \"'\");\n            }\n            codestartFileStrategyHandlers.add(new CodestartFileStrategy(entry.getKey(), handler));\n        }\n        return codestartFileStrategyHandlers;\n    }\n\n    void addBuiltinData() {\n        // needed for azure functions codestart\n        data.put(\"gen-info\", Collections.singletonMap(\"time\", System.currentTimeMillis()));\n    }\n\n    void processLanguageDir(final CodestartResource projectResource, final CodestartResource resource, final String languageDir,\n            final Map<String, Object> finalData) {\n        log.debug(\"processing dir: %s\", resource.pathName());\n        final List<Source> sources = resource.listSources(languageDir);\n\n        for (Source source : sources) {","sourceCodeStart":76,"sourceCodeEnd":112,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/independent-projects/tools/codestarts/src/main/java/io/quarkus/devtools/codestarts/core/CodestartProcessor.java#L76-L112","documentation":"CodestartProcessor.buildStrategies maps codestart conflict-strategy spec entries to named CodestartFileStrategyHandler instances via a BY_NAME registry. This error means a strategy name in the codestart spec (codestarts.yml / project generation config) does not match any registered handler. It is a configuration error in the codestart definition, not user code.","triggerScenarios":"A codestart YAML declares a 'conflict-strategy' (or file strategy) map whose value names a handler that is not in CodestartFileStrategyHandler.BY_NAME, and a project generation loads that codestart.","commonSituations":"Typos in strategy names in codestarts.yml; renaming/removing a handler enum constant while old codestarts still reference it; custom codestarts copied from an incompatible Quarkus version.","solutions":["Fix the strategy name in the codestart spec to one of the registered handler names (e.g. default, override, merge, fail) — check CodestartFileStrategyHandler for valid values","Update the custom codestart definition to match the current Quarkus codestart spec","If a custom handler was intended, register/define it in the handlers enum before use"],"exampleFix":"# before\ncodestart:\n  conflict-strategy:\n    '*': overwrit\n# after\ncodestart:\n  conflict-strategy:\n    '*': override","handlingStrategy":"validation","validationCode":"spec.values().forEach(v -> {\n    if (!CodestartFileStrategyHandler.BY_NAME.containsKey(v))\n        throw new IllegalArgumentException(\"Unknown strategy handler: \" + v);\n});","typeGuard":null,"tryCatchPattern":"try {\n    CodestartProcessor.buildStrategies(spec);\n} catch (CodestartStructureException e) {\n    // surface the offending filter/strategy name from e.getMessage()\n}","preventionTips":["Use only registered handler names in specs","Validate codestart YAML in CI","Sync handler renames with all codestart definitions"],"tags":["configuration","codestart","yaml"],"backgroundTag":"unknown-strategy-name","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}