Permalink
Browse files

Modified deleteOnly to final boolean

  • Loading branch information...
1 parent b4ca2f2 commit fa4d6fee16d94eb15e952f4c18772efe678295da Chinmay Soman committed Aug 8, 2011
Showing with 12 additions and 13 deletions.
  1. +12 −13 src/java/voldemort/server/scheduler/slop/RepairJob.java
View
25 src/java/voldemort/server/scheduler/slop/RepairJob.java
@@ -39,31 +39,30 @@
private final StoreRepository storeRepo;
private final MetadataStore metadataStore;
private final Map<String, Long> storeStats;
- private boolean deleteOnly;
+ private final boolean deleteOnly;
- public RepairJob(StoreRepository storeRepo, MetadataStore metadataStore, Semaphore repairPermits) {
+ public RepairJob(StoreRepository storeRepo,
+ MetadataStore metadataStore,
+ Semaphore repairPermits,
+ boolean deleteOnly,
+ int deleteBatchSize) {
this.storeRepo = storeRepo;
this.metadataStore = metadataStore;
this.repairPermits = Utils.notNull(repairPermits);
this.storeStats = Maps.newHashMap();
- this.deleteOnly = false;
+ this.deleteOnly = deleteOnly;
+ this.DELETE_BATCH = deleteBatchSize;
}
- public RepairJob(StoreRepository storeRepo,
- MetadataStore metadataStore,
- Semaphore repairPermits,
- boolean deleteOnly) {
- this(storeRepo, metadataStore, repairPermits);
- this.deleteOnly = deleteOnly;
+ public RepairJob(StoreRepository storeRepo, MetadataStore metadataStore, Semaphore repairPermits) {
+ this(storeRepo, metadataStore, repairPermits, false, 1000);
}
public RepairJob(StoreRepository storeRepo,
MetadataStore metadataStore,
Semaphore repairPermits,
- boolean deleteOnly,
- int deleteBatchSize) {
- this(storeRepo, metadataStore, repairPermits, deleteOnly);
- this.DELETE_BATCH = deleteBatchSize;
+ boolean deleteOnly) {
+ this(storeRepo, metadataStore, repairPermits, deleteOnly, 1000);
}
@JmxOperation(description = "Start the Repair Job thread", impact = MBeanOperationInfo.ACTION)

0 comments on commit fa4d6fe

Please sign in to comment.