Package jenkins.install
Class InstallUtil
- java.lang.Object
-
- jenkins.install.InstallUtil
-
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public class InstallUtil extends Object
Jenkins install utilities.- Author:
- tom.fennelly@gmail.com
-
-
Field Summary
Fields Modifier and Type Field Description static VersionNumber
NEW_INSTALL_VERSION
-
Constructor Summary
Constructors Constructor Description InstallUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
clearInstallStatus()
Call to remove any active install statusstatic String
getLastExecVersion()
Get the last saved Jenkins instance version.static Map<String,String>
getPersistedInstallStatus()
Returns a list of any plugins that are persisted in the installing liststatic void
persistInstallStatus(List<UpdateCenter.UpdateCenterJob> installingPlugins)
Persists a list of installing plugins; this is used in the case Jenkins fails mid-installation and needs to be restartedstatic void
proceedToNextStateFrom(InstallState prior)
Proceed to the state following the provided onestatic void
saveLastExecVersion()
Save the current Jenkins instance version as the last executed version.
-
-
-
Field Detail
-
NEW_INSTALL_VERSION
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public static final VersionNumber NEW_INSTALL_VERSION
-
-
Method Detail
-
proceedToNextStateFrom
public static void proceedToNextStateFrom(InstallState prior)
Proceed to the state following the provided one
-
saveLastExecVersion
public static void saveLastExecVersion()
Save the current Jenkins instance version as the last executed version.This state information is required in order to determine whether or not the Jenkins instance is just restarting, or is being upgraded from an earlier version.
-
getLastExecVersion
@NonNull public static String getLastExecVersion()
Get the last saved Jenkins instance version.- Returns:
- The last saved Jenkins instance version.
- See Also:
saveLastExecVersion()
-
getPersistedInstallStatus
@CheckForNull public static Map<String,String> getPersistedInstallStatus()
Returns a list of any plugins that are persisted in the installing list
-
persistInstallStatus
public static void persistInstallStatus(List<UpdateCenter.UpdateCenterJob> installingPlugins)
Persists a list of installing plugins; this is used in the case Jenkins fails mid-installation and needs to be restarted
-
clearInstallStatus
public static void clearInstallStatus()
Call to remove any active install status
-
-