Class MultipartUploadCleanupService
java.lang.Object
org.apache.hadoop.hdds.utils.BackgroundService
org.apache.hadoop.ozone.om.service.MultipartUploadCleanupService
public class MultipartUploadCleanupService
extends org.apache.hadoop.hdds.utils.BackgroundService
This is the background service to abort incomplete Multipart Upload.
Scan the MultipartInfoTable periodically to get MPU keys with
creationTimestamp older than a certain threshold, and delete them.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.hadoop.hdds.utils.BackgroundService
org.apache.hadoop.hdds.utils.BackgroundService.PeriodicalTask -
Constructor Summary
ConstructorsConstructorDescriptionMultipartUploadCleanupService(long interval, TimeUnit unit, long timeout, OzoneManager ozoneManager, org.apache.hadoop.hdds.conf.ConfigurationSource conf) -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the number of times this Background service has run.longReturns the number of MPU info that were submitted for deletion by this service.org.apache.hadoop.hdds.utils.BackgroundTaskQueuegetTasks()voidresume()Resume the service if suspended (for testing).voidsuspend()Suspend the service (for testing).Methods inherited from class org.apache.hadoop.hdds.utils.BackgroundService
execTaskCompletion, getExecutorService, getFuture, getIntervalMillis, getThreadCount, runPeriodicalTaskNow, setInterval, setPoolSize, setServiceTimeoutInNanos, shutdown, start
-
Constructor Details
-
MultipartUploadCleanupService
public MultipartUploadCleanupService(long interval, TimeUnit unit, long timeout, OzoneManager ozoneManager, org.apache.hadoop.hdds.conf.ConfigurationSource conf)
-
-
Method Details
-
getRunCount
public long getRunCount()Returns the number of times this Background service has run.- Returns:
- Long, run count.
-
suspend
public void suspend()Suspend the service (for testing). -
resume
public void resume()Resume the service if suspended (for testing). -
getSubmittedMpuInfoCount
public long getSubmittedMpuInfoCount()Returns the number of MPU info that were submitted for deletion by this service. If the MPUInfoTable were completed/aborted from the MPUInfoTable between being submitted for deletion and the actual delete operation, they will not be deleted.- Returns:
- long count.
-
getTasks
public org.apache.hadoop.hdds.utils.BackgroundTaskQueue getTasks()- Specified by:
getTasksin classorg.apache.hadoop.hdds.utils.BackgroundService
-