{"record":{"id":"db9c649d4956bbed","repo":"pinpoint-apm/pinpoint","slug":"manifest-error","errorCode":null,"errorMessage":" Manifest error","messagePattern":" Manifest error","errorType":"exception","errorClass":"PluginException","httpStatus":null,"severity":"error","filePath":"agent-module/profiler/src/main/java/com/navercorp/pinpoint/profiler/plugin/PluginManifest.java","lineNumber":66,"sourceCode":"\n        String pluginId = JarFileUtils.getValue(mainAttributes, PluginJar.PINPOINT_PLUGIN_ID, null);\n        String pluginCompilerVersion = JarFileUtils.getValue(mainAttributes, PluginJar.PINPOINT_PLUGIN_COMPILER_VERSION, null);\n\n        String pluginPackages = JarFileUtils.getValue(mainAttributes, PluginJar.PINPOINT_PLUGIN_PACKAGE, PluginJar.DEFAULT_PINPOINT_PLUGIN_PACKAGE_NAME);\n\n        List<String> pluginPackageList = StringUtils.tokenizeToStringList(pluginPackages, \",\");\n\n        String pluginPackageRequirements = JarFileUtils.getValue(mainAttributes, PluginJar.PINPOINT_PLUGIN_PACKAGE_CLASS_REQUIREMENTS, null);\n        List<String> pluginPackageRequirementList = StringUtils.tokenizeToStringList(pluginPackageRequirements, \",\");\n\n        return new PluginManifest(pluginId, pluginCompilerVersion, pluginPackageList, pluginPackageRequirementList);\n    }\n\n    private static Manifest getManifest(JarFile jarFile) {\n        try {\n            return jarFile.getManifest();\n        } catch (IOException e) {\n            throw new PluginException(jarFile.getName() + \" Manifest error\", e);\n        }\n    }\n\n    public String getPluginId() {\n        return pluginId;\n    }\n\n    public String getPluginCompilerVersion() {\n        return pluginCompilerVersion;\n    }\n\n    public List<String> getPluginPackages() {\n        return pluginPackages;\n    }\n\n    public List<String> getPluginPackageRequirements() {\n        return pluginPackageRequirements;\n    }","sourceCodeStart":48,"sourceCodeEnd":84,"githubUrl":"https://github.com/pinpoint-apm/pinpoint/blob/744c3d3075e595656abb1ae331ad2c0e4c9eb996/agent-module/profiler/src/main/java/com/navercorp/pinpoint/profiler/plugin/PluginManifest.java#L48-L84","documentation":"PluginManifest.getManifest() wraps IOException thrown by JarFile.getManifest() into this PluginException, indicating the jar's manifest could not be read. A jar without a readable manifest cannot expose the plugin's Pinpoint-Plugin metadata needed for loading.","triggerScenarios":"Reading a plugin jar whose MANIFEST.MF is missing, corrupted, or whose jar file is a broken/invalid zip — JarFile.getManifest() throws IOException and this error propagates during plugin loading at agent startup.","commonSituations":"Plugin jar truncated during upload/deployment, jar built without maven-jar-plugin manifest config (no Manifest.txt), corrupted jar after failed transfer, or a text file renamed to .jar.","solutions":["Verify jar integrity: `jar tf <plugin.jar>` or `unzip -t`; redeploy if corrupt","Rebuild the plugin ensuring the manifest is generated (maven-jar-plugin with addDefaultSpecificationEntries/classpath or shade plugin)","Confirm the jar contains META-INF/MANIFEST.MF: `unzip -l plugin.jar | grep MANIFEST`"],"exampleFix":"<!-- before: no manifest config -->\n<artifactId>maven-jar-plugin</artifactId>\n<!-- after -->\n<plugin><artifactId>maven-jar-plugin</artifactId><configuration><archive><manifest><addDefaultImplementationEntries>true</addDefaultImplementationEntries></manifest></archive></configuration></plugin>","handlingStrategy":"try-catch","validationCode":"try (JarFile jf = new JarFile(pluginPath.toFile())) { if (jf.getManifest() == null) throw new IllegalStateException(\"No manifest in \" + pluginPath); }","typeGuard":"boolean hasManifest(Path jar) { try (JarFile jf = new JarFile(jar.toFile())) { return jf.getManifest() != null; } catch (IOException e) { return false; } }","tryCatchPattern":"try { PluginManifest.manifest(jarPath); } catch (PluginException e) { log.error(\"Unreadable/corrupt plugin manifest in {}: {}\", jarPath, e.getMessage()); }","preventionTips":["Verify jars with `jar tf` after CI/CD transfer before deployment","Ensure build produces META-INF/MANIFEST.MF via maven-jar/shade plugin","Fail the deploy pipeline if jar integrity checks fail"],"tags":["java","plugin-loader","jar"],"backgroundTag":"file-read-failed","analyzedSha":"744c3d3075e595656abb1ae331ad2c0e4c9eb996","analyzedAt":"2026-09-07T18:48:45.289Z","contentChangedAt":"2026-09-07T18:48:45.289Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}