Package jetbrains.buildServer.diagnostic
Class ThreadTracesCleaner
- java.lang.Object
-
- jetbrains.buildServer.diagnostic.RequestDiagnosticsCleanerBase
-
- jetbrains.buildServer.diagnostic.ThreadTracesCleaner
-
- All Implemented Interfaces:
RequestDiagnosticsCleaner
,AfterBuildsCleanupExtension
,ServerExtension
,TeamCityExtension
public class ThreadTracesCleaner extends RequestDiagnosticsCleanerBase implements AfterBuildsCleanupExtension
-
-
Field Summary
Fields Modifier and Type Field Description static String
MAX_DAYS_TO_KEEP
static String
NUM_FILES_TO_KEEP
static String
NUM_FILES_TO_KEEP_LEGACY
-
Constructor Summary
Constructors Constructor Description ThreadTracesCleaner(ExecutorServices executorServices)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterCleanup(CleanupProcessState cleanupState)
Invoked upon finishing of the main cleanup process.String
getDescription()
int
getNumberOfFilesToKeep()
File is cleaned if any of maxFiles or maxDays conditions matchint
getNumberOfHoursToKeep()
-
Methods inherited from class jetbrains.buildServer.diagnostic.RequestDiagnosticsCleanerBase
cleanup, scheduleCleanup
-
-
-
-
Field Detail
-
NUM_FILES_TO_KEEP_LEGACY
public static final String NUM_FILES_TO_KEEP_LEGACY
- See Also:
- Constant Field Values
-
NUM_FILES_TO_KEEP
public static final String NUM_FILES_TO_KEEP
- See Also:
- Constant Field Values
-
MAX_DAYS_TO_KEEP
public static final String MAX_DAYS_TO_KEEP
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ThreadTracesCleaner
public ThreadTracesCleaner(@NotNull ExecutorServices executorServices)
-
-
Method Detail
-
getNumberOfFilesToKeep
public int getNumberOfFilesToKeep()
Description copied from class:RequestDiagnosticsCleanerBase
File is cleaned if any of maxFiles or maxDays conditions match- Specified by:
getNumberOfFilesToKeep
in classRequestDiagnosticsCleanerBase
-
getNumberOfHoursToKeep
public int getNumberOfHoursToKeep()
- Specified by:
getNumberOfHoursToKeep
in classRequestDiagnosticsCleanerBase
-
getDescription
public String getDescription()
- Specified by:
getDescription
in interfaceRequestDiagnosticsCleaner
- Specified by:
getDescription
in classRequestDiagnosticsCleanerBase
-
afterCleanup
public void afterCleanup(@NotNull CleanupProcessState cleanupState)
Description copied from interface:AfterBuildsCleanupExtension
Invoked upon finishing of the main cleanup process. At this point all data for specific builds is deleted.
Note: This extension might not be called for every cleanup run as cleanup process can be interrupted earlier. Extension must check cleanup process state and if it is interrupted, complete its operations and return as quick as possible.- Specified by:
afterCleanup
in interfaceAfterBuildsCleanupExtension
- Parameters:
cleanupState
- cleanup process state
-
-