Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug in multiple_per_run #2456

Merged
merged 1 commit into from
Oct 29, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def process(ccdb: Ccdb, object_path: str, delay: int, from_timestamp: int, to_t
Go through the map: for each run (resp. run+pass+period)
Get SOR (validity of first object)
if SOR < now - mw_deletion_delay
if mw_deletion_delay != -1 and SOR < now - mw_deletion_delay
delete the data for this run
if SOR < now - delay
Expand Down Expand Up @@ -106,7 +106,7 @@ def process(ccdb: Ccdb, object_path: str, delay: int, from_timestamp: int, to_t
elif not (from_timestamp < first_object.createdAt < to_timestamp): # not in the allowed period
logger.debug(f" not in the allowed period, skip this bucket")
preservation_list.extend(run_versions)
elif first_object.createdAtDt < datetime.now() - timedelta(minutes=mw_deletion_delay):
elif mw_deletion_delay != -1 and first_object.createdAtDt < datetime.now() - timedelta(minutes=mw_deletion_delay): # moving windows case
logger.debug(f" after mw_deletion_delay period, delete this bucket")
for v in run_versions:
if "/mw/" in v.path: # this is because we really don't want to take the risk of batch deleting non moving windows
Expand Down
Loading