Skip to content

Commit

Permalink
continued: Add log for when retention job starts
Browse files Browse the repository at this point in the history
Signed-off-by: wslulciuc <willy@datakin.com>
  • Loading branch information
wslulciuc committed Jul 25, 2023
1 parent 9bff632 commit 2c6861c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions api/src/main/java/marquez/jobs/DbRetentionJob.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
public class DbRetentionJob extends AbstractScheduledService implements Managed {
private static final Duration NO_DELAY = Duration.ofMinutes(0);

/* The number of rows deleted per batch. */
/* The retention policy frequency. */
private final int frequencyMins;

/* The number of rows deleted per batch. */
Expand All @@ -45,10 +45,11 @@ public class DbRetentionJob extends AbstractScheduledService implements Managed
*/
public DbRetentionJob(
@NonNull final Jdbi jdbi, @NonNull final DbRetentionConfig dbRetentionConfig) {
this.frequencyMins = dbRetentionConfig.getFrequencyMins();
this.numberOfRowsPerBatch = dbRetentionConfig.getNumberOfRowsPerBatch();
this.retentionDays = dbRetentionConfig.getRetentionDays();

// Open connection.
// Connection to database retention policy will be applied.
this.jdbi = jdbi;

// Define fixed schedule with no delay.
Expand Down

0 comments on commit 2c6861c

Please sign in to comment.