mirror of
https://github.com/google/nomulus.git
synced 2025-05-15 17:07:15 +02:00
Use different locks for thin and full rde reports
The lock is used to prevent dual writing of the same output file, and to prevent us from generating the same data twice (if RdeStaging was run twice). However, at times when we're creating both RDE and BRDA reports - we use the same lock for both even though they write to different files and create different reports. This causes one of the two to almost always fail (when both are created, which is once a week I think) delaying that report by several hours. Note that the "prefix" part of the filenames has the mode in it, so different modes will not have the same files. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=168882007
This commit is contained in:
parent
892424b148
commit
3cc44259da
1 changed files with 1 additions and 1 deletions
|
@ -107,7 +107,7 @@ public final class RdeStagingReducer extends Reducer<PendingDeposit, DepositFrag
|
||||||
reduceWithLock(key, fragments);
|
reduceWithLock(key, fragments);
|
||||||
return null;
|
return null;
|
||||||
}};
|
}};
|
||||||
String lockName = String.format("RdeStaging %s", key.tld());
|
String lockName = String.format("RdeStaging %s %s", key.tld(), key.mode());
|
||||||
if (!lockHandler.executeWithLocks(lockRunner, null, lockTimeout, lockName)) {
|
if (!lockHandler.executeWithLocks(lockRunner, null, lockTimeout, lockName)) {
|
||||||
logger.warningfmt("Lock in use: %s", lockName);
|
logger.warningfmt("Lock in use: %s", lockName);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue