Add Spec11 registrar emailing mechanism

This adds the terminal step of the Spec11 pipeline- processing the output of
the Beam pipeline to send an e-mail to each registrar informing them of
identified 'bad urls.'

This also factors out methods common between invoicing (which uses similar beam pipeline tools) and spec11 to the common superpackage ReportingModule + ReportingUtils classes.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=210932496
This commit is contained in:
larryruili 2018-08-30 10:16:20 -07:00 committed by jianglai
parent e4bb1c281c
commit c5e6eae555
26 changed files with 816 additions and 93 deletions

View file

@ -564,10 +564,24 @@ public final class RegistryConfig {
*/
@Provides
@Config("reportingBucket")
public static String provideIcannReportingBucket(@Config("projectId") String projectId) {
public static String provideReportingBucket(@Config("projectId") String projectId) {
return projectId + "-reporting";
}
/**
* Returns the Google Cloud Storage bucket URL for Spec11 and ICANN transaction and activity
* reports to be uploaded.
*
* @see google.registry.reporting.icann.IcannReportingUploadAction
* @see google.registry.reporting.spec11.PublishSpec11ReportAction
*/
@Provides
@Config("reportingBucketUrl")
public static String provideReportingBucketUrl(
@Config("reportingBucket") String reportingBucket) {
return "gs://" + reportingBucket;
}
/**
* Returns the URL we send HTTP PUT requests for ICANN monthly transactions reports.
*
@ -613,17 +627,6 @@ public final class RegistryConfig {
return "gs://" + billingBucket;
}
/**
* Returns the URL of the GCS subdirectory we store Spec11 reports in.
*
* @see google.registry.beam.spec11.Spec11Pipeline
*/
@Provides
@Config("spec11BucketUrl")
public static String provideSpec11BucketUrl(@Config("reportingBucket") String reportingBucket) {
return "gs://" + reportingBucket + "/icann/spec11";
}
/**
* Returns whether or not we should publish invoices to partners automatically by default.
*