Package com.netflix.genie.web.tasks.node
Class DiskCleanupTask
java.lang.Object
com.netflix.genie.web.tasks.node.DiskCleanupTask
- All Implemented Interfaces:
Runnable
This task runs on every Genie node and is responsible for cleaning up the local disk so that space can be
recaptured.
- Since:
- 3.0.0
-
Constructor Summary
ConstructorDescriptionDiskCleanupTask
(@NotNull DiskCleanupProperties properties, @NotNull org.springframework.scheduling.TaskScheduler scheduler, @NotNull org.springframework.core.io.Resource jobsDir, @NotNull DataServices dataServices, @NotNull JobsProperties jobsProperties, @NotNull org.apache.commons.exec.Executor processExecutor, @NotNull io.micrometer.core.instrument.MeterRegistry registry) Constructor. -
Method Summary
-
Constructor Details
-
DiskCleanupTask
public DiskCleanupTask(@NotNull @NotNull DiskCleanupProperties properties, @NotNull @NotNull org.springframework.scheduling.TaskScheduler scheduler, @NotNull @NotNull org.springframework.core.io.Resource jobsDir, @NotNull @NotNull DataServices dataServices, @NotNull @NotNull JobsProperties jobsProperties, @NotNull @NotNull org.apache.commons.exec.Executor processExecutor, @NotNull @NotNull io.micrometer.core.instrument.MeterRegistry registry) throws IOException Constructor. Schedules this task to be run by the task scheduler.- Parameters:
properties
- The disk cleanup properties to use.scheduler
- The scheduler to use to schedule the cron trigger.jobsDir
- The resource representing the location of the job directorydataServices
- TheDataServices
instance to usejobsProperties
- The jobs properties to useprocessExecutor
- The process executor to use to delete directoriesregistry
- The metrics registry- Throws:
IOException
- When it is unable to open a file reference to the job directory
-
-
Method Details