Add the ability to generate RDE deposits in lenient mode

We will not want to run this under normal circumstances, but in cases (such as PDT testing in sandbox) where it's desirable to generate an escrow deposit even if it isn't technically valid XML, this gives us that option. Manual-mode RDE generation is also changed so that, if no watermark date is specified, it defaults to the previous midnight, to better support running of RDE in sandbox to catch data problems.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=156108295
This commit is contained in:
mountford 2017-05-15 14:56:02 -07:00 committed by Ben McIlwain
parent e1f4df86bd
commit 74a0defef3
9 changed files with 101 additions and 33 deletions

View file

@ -45,6 +45,7 @@ public final class RdeModule {
public static final String PARAM_DIRECTORY = "directory";
public static final String PARAM_MODE = "mode";
public static final String PARAM_REVISION = "revision";
public static final String PARAM_LENIENT = "lenient";
@Provides
@Parameter(PARAM_WATERMARK)
@ -82,6 +83,12 @@ public final class RdeModule {
return extractOptionalIntParameter(req, PARAM_REVISION);
}
@Provides
@Parameter(PARAM_LENIENT)
static boolean provideLenient(HttpServletRequest req) {
return extractBooleanParameter(req, PARAM_REVISION);
}
@Provides
@Named("brda")
static Queue provideQueueBrda() {