Skip to content

Commit

Permalink
Rename --host to --fireStoreHost
Browse files Browse the repository at this point in the history
  • Loading branch information
Abacn committed Oct 30, 2023
1 parent 8a28100 commit 44ab540
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions sdks/java/io/google-cloud-platform/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -186,13 +186,13 @@ task integrationTest(type: Test, dependsOn: processTestResources) {
def gcpProject = project.findProperty('gcpProject') ?: 'apache-beam-testing'
def gcpTempRoot = project.findProperty('gcpTempRoot') ?: 'gs://temp-storage-for-end-to-end-tests'
def firestoreDb = project.findProperty('firestoreDb') ?: 'firestoredb'
def host = project.findProperty('host') ?: 'batch-firestore.googleapis.com:443'
def firestoreHost = project.findProperty('firestoreHost') ?: 'batch-firestore.googleapis.com:443'
systemProperty "beamTestPipelineOptions", JsonOutput.toJson([
"--runner=DirectRunner",
"--project=${gcpProject}",
"--tempRoot=${gcpTempRoot}",
"--firestoreDb=${firestoreDb}",
"--host=${host}",
"--firestoreHost=${firestoreHost}",
])

// Disable Gradle cache: these ITs interact with live service that should always be considered "out of date"
Expand Down Expand Up @@ -220,14 +220,14 @@ task integrationTestKms(type: Test) {
def gcpTempRoot = project.findProperty('gcpTempRootKms') ?: 'gs://temp-storage-for-end-to-end-tests-cmek'
def dataflowKmsKey = project.findProperty('dataflowKmsKey') ?: "projects/apache-beam-testing/locations/global/keyRings/beam-it/cryptoKeys/test"
def firestoreDb = project.findProperty('firestoreDb') ?: 'firestoredb'
def host = project.findProperty('host') ?: 'batch-firestore.googleapis.com:443'
def firestoreHost = project.findProperty('firestoreHost') ?: 'batch-firestore.googleapis.com:443'
systemProperty "beamTestPipelineOptions", JsonOutput.toJson([
"--runner=DirectRunner",
"--project=${gcpProject}",
"--tempRoot=${gcpTempRoot}",
"--dataflowKmsKey=${dataflowKmsKey}",
"--firestoreDb=${firestoreDb}",
"--host=${host}",
"--firestoreHost=${firestoreHost}",
])

// Disable Gradle cache: these ITs interact with live service that should always be considered "out of date"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,13 @@ public interface FirestoreOptions extends PipelineOptions {
*/
@Description("Firestore endpoint (host and port)")
@Default.String("batch-firestore.googleapis.com:443")
String getHost();
String getFirestoreHost();

/**
* Define a host port pair to allow connecting to a Cloud Firestore instead of the default live
* service.
*
* @param host the host and port to connect to
*/
void setHost(String host);
void setFirestoreHost(String host);
}
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ FirestoreStub getFirestoreStub(PipelineOptions options) {
GcpOptions gcpOptions = options.as(GcpOptions.class);
builder
.setCredentialsProvider(FixedCredentialsProvider.create(gcpOptions.getGcpCredential()))
.setEndpoint(firestoreOptions.getHost());
.setEndpoint(firestoreOptions.getFirestoreHost());
headers.put(
"x-goog-request-params",
"project_id="
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public FirestoreTestingHelper(CleanupMode cleanupMode) {
.setCredentials(gcpOptions.getGcpCredential())
.setProjectId(gcpOptions.getProject())
.setDatabaseId(firestoreBeamOptions.getFirestoreDb())
.setHost(firestoreBeamOptions.getHost())
.setHost(firestoreBeamOptions.getFirestoreHost())
.build();
fs = firestoreOptions.getService();
rpc = (FirestoreRpc) firestoreOptions.getRpc();
Expand Down

0 comments on commit 44ab540

Please sign in to comment.