Skip to content

Commit

Permalink
Update SpannerWriteSchemaTransformProvider.java
Browse files Browse the repository at this point in the history
  • Loading branch information
reeba212 committed Sep 4, 2024
1 parent 66ff2de commit 8f9178e
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ public PCollectionRowTuple expand(@NonNull PCollectionRowTuple input) {
public abstract static class SpannerWriteSchemaTransformConfiguration implements Serializable {

@SchemaFieldDescription("Specifies the GCP project.")
@Nullable
public abstract String getProjectId();

@SchemaFieldDescription("Specifies the Cloud Spanner instance.")
Expand Down Expand Up @@ -289,10 +290,6 @@ public abstract static class Builder {
public void validate() {
String invalidConfigMessage = "Invalid Spanner Write configuration: ";

checkArgument(
!Strings.isNullOrEmpty(this.getProjectId()),
invalidConfigMessage + "Project ID for a Spanner Write must be specified.");

checkArgument(
!Strings.isNullOrEmpty(this.getInstanceId()),
invalidConfigMessage + "Instance ID for a Spanner Write must be specified.");
Expand Down

0 comments on commit 8f9178e

Please sign in to comment.