{"record":{"id":"80e4e12a4dcee299","repo":"elastic/elasticsearch","slug":"vendor-not-specified-for-jdk-name","errorCode":null,"errorMessage":"vendor not specified for jdk [${name}]","messagePattern":"vendor not specified for jdk \\[(.+?)\\]","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/Jdk.java","lineNumber":200,"sourceCode":"            }\n        };\n    }\n\n    private String getHomeRoot() {\n        boolean isOSX = \"mac\".equals(getPlatform()) || \"darwin\".equals(getPlatform());\n        return getPath() + (isOSX ? \"/Contents/Home\" : \"\");\n    }\n\n    // internal, make this jdks configuration unmodifiable\n    void finalizeValues() {\n        if (version.isPresent() == false) {\n            throw new IllegalArgumentException(\"version not specified for jdk [\" + name + \"]\");\n        }\n        if (platform.isPresent() == false) {\n            throw new IllegalArgumentException(\"platform not specified for jdk [\" + name + \"]\");\n        }\n        if (vendor.isPresent() == false) {\n            throw new IllegalArgumentException(\"vendor not specified for jdk [\" + name + \"]\");\n        }\n        if (architecture.isPresent() == false) {\n            throw new IllegalArgumentException(\"architecture not specified for jdk [\" + name + \"]\");\n        }\n        version.finalizeValue();\n        platform.finalizeValue();\n        vendor.finalizeValue();\n        architecture.finalizeValue();\n        distributionVersion.finalizeValue();\n    }\n\n    @Override\n    public Iterator<File> iterator() {\n        return configuration.iterator();\n    }\n\n    private void parseVersion(String version) {\n        // decompose the bundled jdk version, broken into elements as: [feature, interim, update, build]","sourceCodeStart":182,"sourceCodeEnd":218,"githubUrl":"https://github.com/elastic/elasticsearch/blob/db6a809a667c081ca1dc7500389d26975573215f/build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/Jdk.java#L182-L218","documentation":"Thrown by Jdk.finalizeValues() when the vendor Property is unset (vendor.isPresent() == false). It is the third guard in finalizeValues(), after version and platform. Note that setVendor validates against the allowlist, but skipping the setter entirely leaves the Property absent.","triggerScenarios":"A Jdk is declared with version and platform but setVendor(...) is never called, then the configuration is resolved.","commonSituations":"Forgetting the vendor line in a jdk block; assuming 'openjdk' is the implicit default (there is none).","solutions":["Add vendor = '<adoptium|openjdk|zulu>' to the named jdk block.","Remove the partially-configured jdk declaration if it is unused."],"exampleFix":"// before\njdks { j { version='21.0.3+9'; platform='linux'; architecture='x64'; } }\n// after\njdks { j { version='21.0.3+9'; platform='linux'; architecture='x64'; vendor='adoptium'; } }","handlingStrategy":"validation","validationCode":"// Ensure the vendor property is set before resolution:\njdks {\n  my_jdk {\n    version = '21.0.3+9'\n    platform = 'linux'\n    architecture = 'x64'\n    vendor = 'adoptium'   // <-- required, no default\n  }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["vendor has no default — always set it explicitly.","Set all four properties in one block to surface errors at config time, not resolution time.","Use a shared helper/extension to configure jdks consistently."],"tags":["gradle","jdk","build-config","validation","missing-property"],"backgroundTag":null,"analyzedSha":"db6a809a667c081ca1dc7500389d26975573215f","analyzedAt":"2026-08-12T01:39:14.192Z","schemaVersion":2},"datasetVersion":"2026-08-12T12:31:55.035Z"}