@Restricted(value=org.kohsuke.accmod.restrictions.NoExternalUse.class) public class DetachedPluginsUtil extends Object
Originally, some features were directly in Jenkins core. Over time, more and more features got extracted in dedicated plugins. Issue is: many plugins had started depending on these features, that now were not in the core anymore. So the chosen design strategy has been that the jenkins.war would embed these plugins, and automatically install them and mark them as optional dependencies. This way, older plugins would keep working without having to be modified.
This code was originally moved from ClassicPluginStrategy
.
Modifier and Type | Class and Description |
---|---|
static class |
DetachedPluginsUtil.DetachedPlugin
Information about plugins that were originally in the core.
|
Modifier and Type | Method and Description |
---|---|
static List<DetachedPluginsUtil.DetachedPlugin> |
getDetachedPlugins()
Get the list of all plugins that have ever been
detached from Jenkins core, applicable to the current Java runtime. |
static List<DetachedPluginsUtil.DetachedPlugin> |
getDetachedPlugins(VersionNumber since)
Get the list of plugins that have been detached since a specific Jenkins release version.
|
static List<PluginWrapper.Dependency> |
getImpliedDependencies(String pluginName,
String jenkinsVersion)
Returns all the plugin dependencies that are implicit based on a particular Jenkins version
|
static boolean |
isDetachedPlugin(String pluginId)
Is the named plugin a plugin that was detached from Jenkins at some point in the past.
|
@NonNull public static List<PluginWrapper.Dependency> getImpliedDependencies(String pluginName, String jenkinsVersion)
@NonNull public static List<DetachedPluginsUtil.DetachedPlugin> getDetachedPlugins()
detached
from Jenkins core, applicable to the current Java runtime.List
of DetachedPluginsUtil.DetachedPlugin
s.JavaUtils.getCurrentJavaRuntimeVersionNumber()
@NonNull public static List<DetachedPluginsUtil.DetachedPlugin> getDetachedPlugins(@NonNull VersionNumber since)
since
- The Jenkins version.List
of DetachedPluginsUtil.DetachedPlugin
s.getDetachedPlugins()
public static boolean isDetachedPlugin(@NonNull String pluginId)
pluginId
- The plugin ID.true
if the plugin is a plugin that was detached from Jenkins at some
point in the past, otherwise false
.Copyright © 2004–2021. All rights reserved.