Add config option to specify period dimension of the invitation scheduler.

This commit is contained in:
Anatoliy Sablin
2021-01-13 21:59:47 +03:00
parent a0f6fe9b0d
commit a71d32ba77
3 changed files with 61 additions and 22 deletions

View File

@@ -67,6 +67,7 @@ public class InvitationConfig {
private boolean recursive = true;
private long timer = 5;
private PeriodDimension period = PeriodDimension.minutes;
public boolean isRecursive() {
return recursive;
@@ -84,6 +85,13 @@ public class InvitationConfig {
this.timer = timer;
}
public PeriodDimension getPeriod() {
return period;
}
public void setPeriod(PeriodDimension period) {
this.period = period;
}
}
public static class SenderPolicy {
@@ -147,4 +155,10 @@ public class InvitationConfig {
log.info("Policies: {}", GsonUtil.get().toJson(getPolicy()));
}
public enum PeriodDimension {
minutes,
seconds
}
}