Skip to content

Commit a27dd9c

Browse files
feat: gapic-generator-java v1.0.13, mtls support (#712)
* chore: release gapic-generator-java v1.0.12 Committer: @miraleung PiperOrigin-RevId: 378718217 Source-Author: Google APIs <noreply@google.com> Source-Date: Thu Jun 10 13:08:49 2021 -0700 Source-Repo: googleapis/googleapis Source-Sha: 08c4eeb531c01ad031134dca94b18e3f7dd35902 Source-Link: googleapis/googleapis@08c4eeb * chore: release gapic-generator-java v1.0.13 Committer: @miraleung PiperOrigin-RevId: 379784268 Source-Author: Google APIs <noreply@google.com> Source-Date: Wed Jun 16 12:29:58 2021 -0700 Source-Repo: googleapis/googleapis Source-Sha: 551681f25e36b11829e87e580281350461f4f3f5 Source-Link: googleapis/googleapis@551681f Co-authored-by: Neenu Shaji <Neenu1995@users.noreply.github.com>
1 parent 475e780 commit a27dd9c

File tree

7 files changed

+29
-15
lines changed

7 files changed

+29
-15
lines changed

google-cloud-firestore-admin/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreAdminStubSettings.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -336,6 +336,11 @@ public static String getDefaultEndpoint() {
336336
return "firestore.googleapis.com:443";
337337
}
338338

339+
/** Returns the default mTLS service endpoint. */
340+
public static String getDefaultMtlsEndpoint() {
341+
return "firestore.mtls.googleapis.com:443";
342+
}
343+
339344
/** Returns the default service scopes. */
340345
public static List<String> getDefaultServiceScopes() {
341346
return DEFAULT_SERVICE_SCOPES;
@@ -543,6 +548,8 @@ private static Builder createDefault() {
543548
builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build());
544549
builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build());
545550
builder.setEndpoint(getDefaultEndpoint());
551+
builder.setMtlsEndpoint(getDefaultMtlsEndpoint());
552+
builder.setSwitchToMtlsEndpointAllowed(true);
546553

547554
return initDefaults(builder);
548555
}

google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStubSettings.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,11 @@ public static String getDefaultEndpoint() {
414414
return "firestore.googleapis.com:443";
415415
}
416416

417+
/** Returns the default mTLS service endpoint. */
418+
public static String getDefaultMtlsEndpoint() {
419+
return "firestore.mtls.googleapis.com:443";
420+
}
421+
417422
/** Returns the default service scopes. */
418423
public static List<String> getDefaultServiceScopes() {
419424
return DEFAULT_SERVICE_SCOPES;
@@ -704,6 +709,8 @@ private static Builder createDefault() {
704709
builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build());
705710
builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build());
706711
builder.setEndpoint(getDefaultEndpoint());
712+
builder.setMtlsEndpoint(getDefaultMtlsEndpoint());
713+
builder.setSwitchToMtlsEndpointAllowed(true);
707714

708715
return initDefaults(builder);
709716
}

proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/CollectionGroupName.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -211,9 +211,9 @@ public Builder setCollection(String collection) {
211211
}
212212

213213
private Builder(CollectionGroupName collectionGroupName) {
214-
project = collectionGroupName.project;
215-
database = collectionGroupName.database;
216-
collection = collectionGroupName.collection;
214+
this.project = collectionGroupName.project;
215+
this.database = collectionGroupName.database;
216+
this.collection = collectionGroupName.collection;
217217
}
218218

219219
public CollectionGroupName build() {

proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/DatabaseName.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,8 @@ public Builder setDatabase(String database) {
181181
}
182182

183183
private Builder(DatabaseName databaseName) {
184-
project = databaseName.project;
185-
database = databaseName.database;
184+
this.project = databaseName.project;
185+
this.database = databaseName.database;
186186
}
187187

188188
public DatabaseName build() {

proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldName.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,10 +247,10 @@ public Builder setField(String field) {
247247
}
248248

249249
private Builder(FieldName fieldName) {
250-
project = fieldName.project;
251-
database = fieldName.database;
252-
collection = fieldName.collection;
253-
field = fieldName.field;
250+
this.project = fieldName.project;
251+
this.database = fieldName.database;
252+
this.collection = fieldName.collection;
253+
this.field = fieldName.field;
254254
}
255255

256256
public FieldName build() {

proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexName.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,10 +247,10 @@ public Builder setIndex(String index) {
247247
}
248248

249249
private Builder(IndexName indexName) {
250-
project = indexName.project;
251-
database = indexName.database;
252-
collection = indexName.collection;
253-
index = indexName.index;
250+
this.project = indexName.project;
251+
this.database = indexName.database;
252+
this.collection = indexName.collection;
253+
this.index = indexName.index;
254254
}
255255

256256
public IndexName build() {

synth.metadata

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
"git": {
1212
"name": "googleapis",
1313
"remote": "https://github.com/googleapis/googleapis.git",
14-
"sha": "9e3105549a35520f215359065c11e8dce15e18af",
15-
"internalRef": "378266372"
14+
"sha": "551681f25e36b11829e87e580281350461f4f3f5",
15+
"internalRef": "379784268"
1616
}
1717
},
1818
{

0 commit comments

Comments
 (0)