diff --git a/workers/blobuploadcleanupworker/blobuploadcleanupworker.py b/workers/blobuploadcleanupworker/blobuploadcleanupworker.py index 4c664641f..82d3acda3 100644 --- a/workers/blobuploadcleanupworker/blobuploadcleanupworker.py +++ b/workers/blobuploadcleanupworker/blobuploadcleanupworker.py @@ -11,9 +11,8 @@ from util.log import logfile_path logger = logging.getLogger(__name__) - DELETION_DATE_THRESHOLD = timedelta(days=2) -BLOBUPLOAD_CLEANUP_FREQUENCY = app.config.get('BLOBUPLOAD_CLEANUP_FREQUENCY', 60*60) +BLOBUPLOAD_CLEANUP_FREQUENCY = app.config.get('BLOBUPLOAD_CLEANUP_FREQUENCY', 60 * 60) class BlobUploadCleanupWorker(Worker): diff --git a/workers/blobuploadcleanupworker/models_pre_oci.py b/workers/blobuploadcleanupworker/models_pre_oci.py index e7d0dbd20..97db6e159 100644 --- a/workers/blobuploadcleanupworker/models_pre_oci.py +++ b/workers/blobuploadcleanupworker/models_pre_oci.py @@ -2,8 +2,9 @@ from datetime import datetime, timedelta from data import model from data.database import BlobUpload as BlobUploadTable -from workers.blobuploadcleanupworker.models_interface import (BlobUpload, - BlobUploadCleanupWorkerDataInterface) +from workers.blobuploadcleanupworker.models_interface import ( + BlobUpload, BlobUploadCleanupWorkerDataInterface) + class PreOCIModel(BlobUploadCleanupWorkerDataInterface): def get_stale_blob_upload(self, stale_threshold): @@ -33,4 +34,5 @@ class PreOCIModel(BlobUploadCleanupWorkerDataInterface): blob_upload = model.blob.get_blob_upload_by_uuid(upload_uuid) return blob_upload is not None + pre_oci_model = PreOCIModel()