mirror of
https://github.com/google/nomulus.git
synced 2025-04-30 12:07:51 +02:00
Remove the beam parameter in RDE staging action (#1684)
The parameter was used to force a RDE beam run, which is no longer necessary, now that the mapreduce pipeline is deleted.
This commit is contained in:
parent
aa348ada3d
commit
725e52f817
3 changed files with 0 additions and 42 deletions
|
@ -42,7 +42,6 @@ public abstract class RdeModule {
|
||||||
public static final String PARAM_WATERMARK = "watermark";
|
public static final String PARAM_WATERMARK = "watermark";
|
||||||
public static final String PARAM_WATERMARKS = "watermarks";
|
public static final String PARAM_WATERMARKS = "watermarks";
|
||||||
public static final String PARAM_MANUAL = "manual";
|
public static final String PARAM_MANUAL = "manual";
|
||||||
public static final String PARAM_BEAM = "beam";
|
|
||||||
public static final String PARAM_DIRECTORY = "directory";
|
public static final String PARAM_DIRECTORY = "directory";
|
||||||
public static final String PARAM_MODE = "mode";
|
public static final String PARAM_MODE = "mode";
|
||||||
public static final String PARAM_REVISION = "revision";
|
public static final String PARAM_REVISION = "revision";
|
||||||
|
@ -70,12 +69,6 @@ public abstract class RdeModule {
|
||||||
return extractBooleanParameter(req, PARAM_MANUAL);
|
return extractBooleanParameter(req, PARAM_MANUAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
|
||||||
@Parameter(PARAM_BEAM)
|
|
||||||
static boolean provideBeam(HttpServletRequest req) {
|
|
||||||
return extractBooleanParameter(req, PARAM_BEAM);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
@Parameter(PARAM_DIRECTORY)
|
@Parameter(PARAM_DIRECTORY)
|
||||||
static Optional<String> provideDirectory(HttpServletRequest req) {
|
static Optional<String> provideDirectory(HttpServletRequest req) {
|
||||||
|
|
|
@ -15,7 +15,6 @@
|
||||||
package google.registry.tools;
|
package google.registry.tools;
|
||||||
|
|
||||||
import static google.registry.model.tld.Registries.assertTldsExist;
|
import static google.registry.model.tld.Registries.assertTldsExist;
|
||||||
import static google.registry.rde.RdeModule.PARAM_BEAM;
|
|
||||||
import static google.registry.rde.RdeModule.PARAM_DIRECTORY;
|
import static google.registry.rde.RdeModule.PARAM_DIRECTORY;
|
||||||
import static google.registry.rde.RdeModule.PARAM_LENIENT;
|
import static google.registry.rde.RdeModule.PARAM_LENIENT;
|
||||||
import static google.registry.rde.RdeModule.PARAM_MANUAL;
|
import static google.registry.rde.RdeModule.PARAM_MANUAL;
|
||||||
|
@ -71,13 +70,6 @@ final class GenerateEscrowDepositCommand implements CommandWithRemoteApi {
|
||||||
+ "XML deposit files.")
|
+ "XML deposit files.")
|
||||||
private boolean lenient = false;
|
private boolean lenient = false;
|
||||||
|
|
||||||
@Parameter(
|
|
||||||
names = {"-b", "--beam"},
|
|
||||||
description =
|
|
||||||
"Whether to explicitly launch the beam pipeline instead of letting the action decide"
|
|
||||||
+ " which one to run.")
|
|
||||||
private boolean beam = false;
|
|
||||||
|
|
||||||
@Parameter(
|
@Parameter(
|
||||||
names = {"-r", "--revision"},
|
names = {"-r", "--revision"},
|
||||||
description = "Revision number. Use >0 for resends.")
|
description = "Revision number. Use >0 for resends.")
|
||||||
|
@ -119,7 +111,6 @@ final class GenerateEscrowDepositCommand implements CommandWithRemoteApi {
|
||||||
.put(PARAM_MODE, mode.toString())
|
.put(PARAM_MODE, mode.toString())
|
||||||
.put(PARAM_DIRECTORY, outdir)
|
.put(PARAM_DIRECTORY, outdir)
|
||||||
.put(PARAM_LENIENT, Boolean.toString(lenient))
|
.put(PARAM_LENIENT, Boolean.toString(lenient))
|
||||||
.put(PARAM_BEAM, Boolean.toString(beam))
|
|
||||||
.put(PARAM_TLDS, tlds.stream().collect(Collectors.joining(",")))
|
.put(PARAM_TLDS, tlds.stream().collect(Collectors.joining(",")))
|
||||||
.put(
|
.put(
|
||||||
PARAM_WATERMARKS,
|
PARAM_WATERMARKS,
|
||||||
|
|
|
@ -201,29 +201,6 @@ public class GenerateEscrowDepositCommandTest
|
||||||
.param("revision", "42"));
|
.param("revision", "42"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
void testCommand_successWithBeam() throws Exception {
|
|
||||||
runCommand(
|
|
||||||
"--tld=tld",
|
|
||||||
"--watermark=2017-01-01T00:00:00Z",
|
|
||||||
"--mode=thin",
|
|
||||||
"--beam",
|
|
||||||
"-r 42",
|
|
||||||
"-o test");
|
|
||||||
|
|
||||||
cloudTasksHelper.assertTasksEnqueued(
|
|
||||||
"rde-report",
|
|
||||||
new TaskMatcher()
|
|
||||||
.url("/_dr/task/rdeStaging")
|
|
||||||
.param("mode", "THIN")
|
|
||||||
.param("beam", "true")
|
|
||||||
.param("watermarks", "2017-01-01T00:00:00.000Z")
|
|
||||||
.param("tlds", "tld")
|
|
||||||
.param("directory", "test")
|
|
||||||
.param("manual", "true")
|
|
||||||
.param("revision", "42"));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
void testCommand_successWithDefaultValidationMode() throws Exception {
|
void testCommand_successWithDefaultValidationMode() throws Exception {
|
||||||
runCommand("--tld=tld", "--watermark=2017-01-01T00:00:00Z", "--mode=thin", "-r 42", "-o test");
|
runCommand("--tld=tld", "--watermark=2017-01-01T00:00:00Z", "--mode=thin", "-r 42", "-o test");
|
||||||
|
@ -250,7 +227,6 @@ public class GenerateEscrowDepositCommandTest
|
||||||
new TaskMatcher()
|
new TaskMatcher()
|
||||||
.url("/_dr/task/rdeStaging")
|
.url("/_dr/task/rdeStaging")
|
||||||
.param("lenient", "false")
|
.param("lenient", "false")
|
||||||
.param("beam", "false")
|
|
||||||
.param("mode", "THIN")
|
.param("mode", "THIN")
|
||||||
.param("watermarks", "2017-01-01T00:00:00.000Z")
|
.param("watermarks", "2017-01-01T00:00:00.000Z")
|
||||||
.param("tlds", "tld")
|
.param("tlds", "tld")
|
||||||
|
@ -268,7 +244,6 @@ public class GenerateEscrowDepositCommandTest
|
||||||
.url("/_dr/task/rdeStaging")
|
.url("/_dr/task/rdeStaging")
|
||||||
.param("mode", "FULL")
|
.param("mode", "FULL")
|
||||||
.param("lenient", "false")
|
.param("lenient", "false")
|
||||||
.param("beam", "false")
|
|
||||||
.param("watermarks", "2017-01-01T00:00:00.000Z")
|
.param("watermarks", "2017-01-01T00:00:00.000Z")
|
||||||
.param("tlds", "tld")
|
.param("tlds", "tld")
|
||||||
.param("directory", "test")
|
.param("directory", "test")
|
||||||
|
@ -291,7 +266,6 @@ public class GenerateEscrowDepositCommandTest
|
||||||
.url("/_dr/task/rdeStaging")
|
.url("/_dr/task/rdeStaging")
|
||||||
.param("mode", "THIN")
|
.param("mode", "THIN")
|
||||||
.param("lenient", "false")
|
.param("lenient", "false")
|
||||||
.param("beam", "false")
|
|
||||||
.param("watermarks", "2017-01-01T00:00:00.000Z,2017-01-02T00:00:00.000Z")
|
.param("watermarks", "2017-01-01T00:00:00.000Z,2017-01-02T00:00:00.000Z")
|
||||||
.param("tlds", "tld,anothertld")
|
.param("tlds", "tld,anothertld")
|
||||||
.param("directory", "test")
|
.param("directory", "test")
|
||||||
|
|
Loading…
Add table
Reference in a new issue