Package hudson.plugins.disk_usage
Class DiskUsageUtil
java.lang.Object
hudson.plugins.disk_usage.DiskUsageUtil
- Author:
- Lucie Votypkova
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
ACallable
which computes disk usage of remote file object -
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
addProperty
(Item item) static void
calculateDiskUsageForBuild
(String buildId, AbstractProject project) static void
static void
static Long
calculateWorkspaceDiskUsageForPath
(FilePath workspace, ArrayList<FilePath> exceeded) static void
calculationDiskUsageOfBuild
(AbstractBuild build, TaskListener listener) Calculate disk usage of build after its execution (or as post-build step)static void
static void
static String
formatTimeInMilisec
(long time) static List<AbstractProject>
getAllProjects
(ItemGroup<? extends Item> itemGroup) static Date
getDate
(int unit, int count) static Date
static Long
getFileSize
(File f, List<File> exceedFiles) static int
static double
getScale
(long number) static Long
getSizeInBytes
(String stringSize) static String
getSizeString
(Long size) static String
getUnitString
(int floor) static boolean
protected static void
loadData
(DiskUsageProperty property, boolean loadAllBuilds) static void
-
Field Details
-
LOGGER
-
-
Constructor Details
-
DiskUsageUtil
public DiskUsageUtil()
-
-
Method Details
-
addProperty
-
loadData
-
getDate
-
getDate
-
formatTimeInMilisec
-
sendEmail
- Throws:
jakarta.mail.MessagingException
-
getSizeInBytes
-
controlAllJobsExceedSize
- Throws:
IOException
-
controlWorkspaceExceedSize
-
parseExcludedJobsFromString
-
getSizeString
-
getScale
public static double getScale(long number) -
getIndex
-
getUnitString
-
calculationDiskUsageOfBuild
Calculate disk usage of build after its execution (or as post-build step)- Parameters:
build
-listener
-
-
isSymlink
- Throws:
IOException
-
getFileSize
- Throws:
IOException
-
calculateDiskUsageForProject
- Throws:
IOException
-
calculateDiskUsageForBuild
public static void calculateDiskUsageForBuild(String buildId, AbstractProject project) throws IOException - Throws:
IOException
-
calculateWorkspaceDiskUsageForPath
public static Long calculateWorkspaceDiskUsageForPath(FilePath workspace, ArrayList<FilePath> exceeded) throws IOException, InterruptedException - Throws:
IOException
InterruptedException
-
calculateWorkspaceDiskUsage
public static void calculateWorkspaceDiskUsage(AbstractProject project) throws IOException, InterruptedException - Throws:
IOException
InterruptedException
-
getAllProjects
-