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

    Constructors
    Constructor
    Description
    MultipartUploadCleanupService(long interval, TimeUnit unit, long timeout, OzoneManager ozoneManager, org.apache.hadoop.hdds.conf.ConfigurationSource conf)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    long
    Returns the number of times this Background service has run.
    long
    Returns the number of MPU info that were submitted for deletion by this service.
    org.apache.hadoop.hdds.utils.BackgroundTaskQueue
     
    void
    Resume the service if suspended (for testing).
    void
    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

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 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:
      getTasks in class org.apache.hadoop.hdds.utils.BackgroundService