Skip to content

Commit 450ba64

Browse files
authored
[DatastreamToSpanner, SpannerToSourceDb, SourceDbToSpanner] Remove hardcoded VPC parameters from integration tests (#3179)
* Remove hardcoded VPC parameters from integration tests * Formatting changes
1 parent 649a70e commit 450ba64

12 files changed

+1
-36
lines changed

v2/datastream-to-spanner/src/test/java/com/google/cloud/teleport/v2/templates/DataStreamToSpannerITBase.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,7 @@ public abstract class DataStreamToSpannerITBase extends TemplateTestBase {
6363
// Format of avro file path in GCS - {table}/2023/12/20/06/57/{fileName}
6464
public static final String DATA_STREAM_EVENT_FILES_PATH_FORMAT_IN_GCS = "%s/2023/12/20/06/57/%s";
6565
private static final Logger LOG = LoggerFactory.getLogger(DataStreamToSpannerITBase.class);
66-
protected static final String VPC_NAME = "spanner-wide-row-pr-test-vpc";
67-
protected static final String VPC_REGION = "us-central1";
68-
protected static final String SUBNET_NAME = "regions/" + VPC_REGION + "/subnetworks/" + VPC_NAME;
66+
6967
protected static final Map<String, String> ADDITIONAL_JOB_PARAMS = new HashMap<>();
7068
public static final int CUTOVER_MILLIS = 30 * 1000;
7169

v2/datastream-to-spanner/src/test/java/com/google/cloud/teleport/v2/templates/DataStreamToSpannerWideRowForMax16KeyTablePerDatabaseIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,9 +111,6 @@ public void setUp() throws IOException {
111111
ADDITIONAL_JOB_PARAMS.putAll(
112112
new HashMap<>() {
113113
{
114-
put("network", VPC_NAME);
115-
put("subnetwork", SUBNET_NAME);
116-
put("workerRegion", VPC_REGION);
117114
}
118115
});
119116
jobInfo =

v2/datastream-to-spanner/src/test/java/com/google/cloud/teleport/v2/templates/DataStreamToSpannerWideRowForMax9MibTablePerDatabaseIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,6 @@ public void setUp() throws IOException {
120120
ADDITIONAL_JOB_PARAMS.putAll(
121121
new HashMap<>() {
122122
{
123-
put("network", VPC_NAME);
124-
put("subnetwork", SUBNET_NAME);
125-
put("workerRegion", VPC_REGION);
126123
}
127124
});
128125
jobInfo =

v2/datastream-to-spanner/src/test/java/com/google/cloud/teleport/v2/templates/DataStreamToSpannerWideRowForMaxColumnsPerTablesIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,6 @@ public void setUp() throws IOException {
112112
ADDITIONAL_JOB_PARAMS.putAll(
113113
new HashMap<>() {
114114
{
115-
put("network", VPC_NAME);
116-
put("subnetwork", SUBNET_NAME);
117-
put("workerRegion", VPC_REGION);
118115
}
119116
});
120117
jobInfo =

v2/datastream-to-spanner/src/test/java/com/google/cloud/teleport/v2/templates/DataStreamToSpannerWideRowForMaxTableNameIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,6 @@ public void setUp() throws IOException {
112112
ADDITIONAL_JOB_PARAMS.putAll(
113113
new HashMap<>() {
114114
{
115-
put("network", VPC_NAME);
116-
put("subnetwork", SUBNET_NAME);
117-
put("workerRegion", VPC_REGION);
118115
}
119116
});
120117
jobInfo =

v2/datastream-to-spanner/src/test/java/com/google/cloud/teleport/v2/templates/DataStreamToSpannerWideRowForMaxTableNameWithMaxColumnNameIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,6 @@ public void setUp() throws IOException {
114114
ADDITIONAL_JOB_PARAMS.putAll(
115115
new HashMap<>() {
116116
{
117-
put("network", VPC_NAME);
118-
put("subnetwork", SUBNET_NAME);
119-
put("workerRegion", VPC_REGION);
120117
}
121118
});
122119
jobInfo =

v2/spanner-to-sourcedb/src/test/java/com/google/cloud/teleport/v2/templates/SpannerToCassandraSourceDbMaxColumnsIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -106,9 +106,6 @@ public void setUp() throws Exception {
106106
Map<String, String> jobParameters =
107107
new HashMap<>() {
108108
{
109-
put("network", VPC_NAME);
110-
put("subnetwork", SUBNET_NAME);
111-
put("workerRegion", VPC_REGION);
112109
}
113110
};
114111
jobInfo =

v2/spanner-to-sourcedb/src/test/java/com/google/cloud/teleport/v2/templates/SpannerToCassandraSourceDbMaxColumnsSizeIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,6 @@ public void setUp() throws Exception {
110110
Map<String, String> jobParameters =
111111
new HashMap<>() {
112112
{
113-
put("network", VPC_NAME);
114-
put("subnetwork", SUBNET_NAME);
115-
put("workerRegion", VPC_REGION);
116113
}
117114
};
118115
jobInfo =

v2/spanner-to-sourcedb/src/test/java/com/google/cloud/teleport/v2/templates/SpannerToCassandraSourceDbWideRow10MbIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,6 @@ public void setUp() throws IOException {
110110
Map<String, String> jobParameters =
111111
new HashMap<>() {
112112
{
113-
put("network", VPC_NAME);
114-
put("subnetwork", SUBNET_NAME);
115-
put("workerRegion", VPC_REGION);
116113
}
117114
};
118115
jobInfo =

v2/spanner-to-sourcedb/src/test/java/com/google/cloud/teleport/v2/templates/SpannerToMySqlSourceDbWideRow10MbIT.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,6 @@ public void setUp() throws IOException {
112112
Map<String, String> jobParameters =
113113
new HashMap<>() {
114114
{
115-
put("network", VPC_NAME);
116-
put("subnetwork", SUBNET_NAME);
117-
put("workerRegion", VPC_REGION);
118115
put("sessionFilePath", getGcsPath("input/session.json", gcsResourceManager));
119116
}
120117
};

0 commit comments

Comments
 (0)