{"record":{"id":"c19d16281a2498b2","repo":"apache/flink","slug":"multiple-jars-with-manifest-attribute-for-entry-cl","errorCode":null,"errorMessage":"Multiple JARs with manifest attribute for entry class: %s","messagePattern":"Multiple JARs with manifest attribute for entry class: (.+?)","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"flink-clients/src/main/java/org/apache/flink/client/deployment/application/JarManifestParser.java","lineNumber":87,"sourceCode":"     */\n    static JarFileWithEntryClass findOnlyEntryClass(Iterable<File> jarFiles) throws IOException {\n        List<JarFileWithEntryClass> jarsWithEntryClasses = new ArrayList<>();\n        for (File jarFile : jarFiles) {\n            findEntryClass(jarFile)\n                    .ifPresent(\n                            entryClass ->\n                                    jarsWithEntryClasses.add(\n                                            new JarFileWithEntryClass(jarFile, entryClass)));\n        }\n        int size = jarsWithEntryClasses.size();\n        if (size == 0) {\n            throw new NoSuchElementException(\"No JAR with manifest attribute for entry class\");\n        }\n        if (size == 1) {\n            return jarsWithEntryClasses.get(0);\n        }\n        // else: size > 1\n        throw new IllegalArgumentException(\n                \"Multiple JARs with manifest attribute for entry class: \" + jarsWithEntryClasses);\n    }\n\n    /**\n     * Returns the entry class as specified in the manifest of the provided JAR file.\n     *\n     * <p>The following manifest attributes are checked in order to find the entry class:\n     *\n     * <ol>\n     *   <li>{@link PackagedProgram#MANIFEST_ATTRIBUTE_ASSEMBLER_CLASS}\n     *   <li>{@link PackagedProgram#MANIFEST_ATTRIBUTE_MAIN_CLASS}\n     * </ol>\n     *\n     * @param jarFile JAR file to parse\n     * @return Optional holding entry class\n     * @throws IOException If there is an error accessing the JAR\n     */\n    @VisibleForTesting","sourceCodeStart":69,"sourceCodeEnd":105,"githubUrl":"https://github.com/apache/flink/blob/2f3c205e9266cb30240eb7f4fdab15cad629a70f/flink-clients/src/main/java/org/apache/flink/client/deployment/application/JarManifestParser.java#L69-L105","documentation":"Error \"Multiple JARs with manifest attribute for entry class: %s\" thrown in apache/flink.","triggerScenarios":"Triggered at runtime when the operation fails because: Multiple JARs with manifest attribute for entry class: the reported value.","commonSituations":"Commonly caused by misconfiguration, missing dependencies or files, unsupported types or operations, or invalid user input leading to: Multiple JARs with manifest attribute for entry class: the reported value.","solutions":["Address the cause reported by the error message: Multiple JARs with manifest attribute for entry class: the reported value","Verify the inputs, configuration values, and classpath/dependency setup related to this operation, then retry."],"exampleFix":"Correct the condition described (\"Multiple JARs with manifest attribute for entry class: the reported value\") and rerun the job or command.","handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2f3c205e9266cb30240eb7f4fdab15cad629a70f","analyzedAt":"2026-08-14T08:48:24.518Z","schemaVersion":2},"datasetVersion":"2026-08-14T10:17:34.591Z"}