jenkins .hpi插件安装后在plugins目录中变成.j
2021-12-22 本文已影响0人
87d6dc4b11a7
当我们通过“系统管理—插件管理”安装*.hpi
的插件,安装完成后在$jenkins_home/plugins
目录下查看发现后缀是.jpi
。在插件安装过程中发生了什么呢?
/jenkins/core/src/main/java/hudson/PluginManager.java
protected void copyBundledPlugin(URL src, String fileName) throws IOException {
LOGGER.log(FINE, "Copying {0}", src);
fileName = fileName.replace(".hpi",".jpi"); // normalize fileNames to have the correct suffix
String legacyName = fileName.replace(".jpi",".hpi");
long lastModified = getModificationDate(src);
File file = new File(rootDir, fileName);
https://github.com/jenkinsci/jenkins
https://javadoc.jenkins.io/hudson/PluginManager.html