Skip to content
This repository was archived by the owner on Sep 16, 2023. It is now read-only.

Commit 5dd9dcf

Browse files
fix(v1): migrate to grpc_service_config (#193)
This PR was generated using Autosynth. 🌈 Synth log will be available here: https://source.cloud.google.com/results/invocations/26799c93-8ee3-4b0a-a39f-018d7fd4c10d/targets - [ ] To automatically regenerate this PR, check this box. PiperOrigin-RevId: 322642677 Source-Link: googleapis/googleapis@8d58283
1 parent dba4e11 commit 5dd9dcf

File tree

9 files changed

+1315
-1122
lines changed

9 files changed

+1315
-1122
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ If you are using Maven with [BOM][libraries-bom], add this to your pom.xml file
1717
<dependency>
1818
<groupId>com.google.cloud</groupId>
1919
<artifactId>libraries-bom</artifactId>
20-
<version>8.0.0</version>
20+
<version>8.1.0</version>
2121
<type>pom</type>
2222
<scope>import</scope>
2323
</dependency>

google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerClient.java

Lines changed: 568 additions & 567 deletions
Large diffs are not rendered by default.

google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerSettings.java

Lines changed: 48 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -55,16 +55,16 @@
5555
* <p>The builder of this class is recursive, so contained classes are themselves builders. When
5656
* build() is called, the tree of builders is called to create the complete settings object.
5757
*
58-
* <p>For example, to set the total timeout of deleteDeviceRegistry to 30 seconds:
58+
* <p>For example, to set the total timeout of createDeviceRegistry to 30 seconds:
5959
*
6060
* <pre>
6161
* <code>
6262
* DeviceManagerSettings.Builder deviceManagerSettingsBuilder =
6363
* DeviceManagerSettings.newBuilder();
6464
* deviceManagerSettingsBuilder
65-
* .deleteDeviceRegistrySettings()
65+
* .createDeviceRegistrySettings()
6666
* .setRetrySettings(
67-
* deviceManagerSettingsBuilder.deleteDeviceRegistrySettings().getRetrySettings().toBuilder()
67+
* deviceManagerSettingsBuilder.createDeviceRegistrySettings().getRetrySettings().toBuilder()
6868
* .setTotalTimeout(Duration.ofSeconds(30))
6969
* .build());
7070
* DeviceManagerSettings deviceManagerSettings = deviceManagerSettingsBuilder.build();
@@ -74,28 +74,6 @@
7474
@Generated("by gapic-generator")
7575
@BetaApi
7676
public class DeviceManagerSettings extends ClientSettings<DeviceManagerSettings> {
77-
/** Returns the object with the settings used for calls to deleteDeviceRegistry. */
78-
public UnaryCallSettings<DeleteDeviceRegistryRequest, Empty> deleteDeviceRegistrySettings() {
79-
return ((DeviceManagerStubSettings) getStubSettings()).deleteDeviceRegistrySettings();
80-
}
81-
82-
/** Returns the object with the settings used for calls to deleteDevice. */
83-
public UnaryCallSettings<DeleteDeviceRequest, Empty> deleteDeviceSettings() {
84-
return ((DeviceManagerStubSettings) getStubSettings()).deleteDeviceSettings();
85-
}
86-
87-
/** Returns the object with the settings used for calls to modifyCloudToDeviceConfig. */
88-
public UnaryCallSettings<ModifyCloudToDeviceConfigRequest, DeviceConfig>
89-
modifyCloudToDeviceConfigSettings() {
90-
return ((DeviceManagerStubSettings) getStubSettings()).modifyCloudToDeviceConfigSettings();
91-
}
92-
93-
/** Returns the object with the settings used for calls to sendCommandToDevice. */
94-
public UnaryCallSettings<SendCommandToDeviceRequest, SendCommandToDeviceResponse>
95-
sendCommandToDeviceSettings() {
96-
return ((DeviceManagerStubSettings) getStubSettings()).sendCommandToDeviceSettings();
97-
}
98-
9977
/** Returns the object with the settings used for calls to createDeviceRegistry. */
10078
public UnaryCallSettings<CreateDeviceRegistryRequest, DeviceRegistry>
10179
createDeviceRegistrySettings() {
@@ -113,6 +91,11 @@ public UnaryCallSettings<GetDeviceRegistryRequest, DeviceRegistry> getDeviceRegi
11391
return ((DeviceManagerStubSettings) getStubSettings()).updateDeviceRegistrySettings();
11492
}
11593

94+
/** Returns the object with the settings used for calls to deleteDeviceRegistry. */
95+
public UnaryCallSettings<DeleteDeviceRegistryRequest, Empty> deleteDeviceRegistrySettings() {
96+
return ((DeviceManagerStubSettings) getStubSettings()).deleteDeviceRegistrySettings();
97+
}
98+
11699
/** Returns the object with the settings used for calls to listDeviceRegistries. */
117100
public PagedCallSettings<
118101
ListDeviceRegistriesRequest,
@@ -137,12 +120,23 @@ public UnaryCallSettings<UpdateDeviceRequest, Device> updateDeviceSettings() {
137120
return ((DeviceManagerStubSettings) getStubSettings()).updateDeviceSettings();
138121
}
139122

123+
/** Returns the object with the settings used for calls to deleteDevice. */
124+
public UnaryCallSettings<DeleteDeviceRequest, Empty> deleteDeviceSettings() {
125+
return ((DeviceManagerStubSettings) getStubSettings()).deleteDeviceSettings();
126+
}
127+
140128
/** Returns the object with the settings used for calls to listDevices. */
141129
public PagedCallSettings<ListDevicesRequest, ListDevicesResponse, ListDevicesPagedResponse>
142130
listDevicesSettings() {
143131
return ((DeviceManagerStubSettings) getStubSettings()).listDevicesSettings();
144132
}
145133

134+
/** Returns the object with the settings used for calls to modifyCloudToDeviceConfig. */
135+
public UnaryCallSettings<ModifyCloudToDeviceConfigRequest, DeviceConfig>
136+
modifyCloudToDeviceConfigSettings() {
137+
return ((DeviceManagerStubSettings) getStubSettings()).modifyCloudToDeviceConfigSettings();
138+
}
139+
146140
/** Returns the object with the settings used for calls to listDeviceConfigVersions. */
147141
public UnaryCallSettings<ListDeviceConfigVersionsRequest, ListDeviceConfigVersionsResponse>
148142
listDeviceConfigVersionsSettings() {
@@ -171,6 +165,12 @@ public UnaryCallSettings<GetIamPolicyRequest, Policy> getIamPolicySettings() {
171165
return ((DeviceManagerStubSettings) getStubSettings()).testIamPermissionsSettings();
172166
}
173167

168+
/** Returns the object with the settings used for calls to sendCommandToDevice. */
169+
public UnaryCallSettings<SendCommandToDeviceRequest, SendCommandToDeviceResponse>
170+
sendCommandToDeviceSettings() {
171+
return ((DeviceManagerStubSettings) getStubSettings()).sendCommandToDeviceSettings();
172+
}
173+
174174
/** Returns the object with the settings used for calls to bindDeviceToGateway. */
175175
public UnaryCallSettings<BindDeviceToGatewayRequest, BindDeviceToGatewayResponse>
176176
bindDeviceToGatewaySettings() {
@@ -280,29 +280,6 @@ public Builder applyToAllUnaryMethods(
280280
return this;
281281
}
282282

283-
/** Returns the builder for the settings used for calls to deleteDeviceRegistry. */
284-
public UnaryCallSettings.Builder<DeleteDeviceRegistryRequest, Empty>
285-
deleteDeviceRegistrySettings() {
286-
return getStubSettingsBuilder().deleteDeviceRegistrySettings();
287-
}
288-
289-
/** Returns the builder for the settings used for calls to deleteDevice. */
290-
public UnaryCallSettings.Builder<DeleteDeviceRequest, Empty> deleteDeviceSettings() {
291-
return getStubSettingsBuilder().deleteDeviceSettings();
292-
}
293-
294-
/** Returns the builder for the settings used for calls to modifyCloudToDeviceConfig. */
295-
public UnaryCallSettings.Builder<ModifyCloudToDeviceConfigRequest, DeviceConfig>
296-
modifyCloudToDeviceConfigSettings() {
297-
return getStubSettingsBuilder().modifyCloudToDeviceConfigSettings();
298-
}
299-
300-
/** Returns the builder for the settings used for calls to sendCommandToDevice. */
301-
public UnaryCallSettings.Builder<SendCommandToDeviceRequest, SendCommandToDeviceResponse>
302-
sendCommandToDeviceSettings() {
303-
return getStubSettingsBuilder().sendCommandToDeviceSettings();
304-
}
305-
306283
/** Returns the builder for the settings used for calls to createDeviceRegistry. */
307284
public UnaryCallSettings.Builder<CreateDeviceRegistryRequest, DeviceRegistry>
308285
createDeviceRegistrySettings() {
@@ -321,6 +298,12 @@ public UnaryCallSettings.Builder<DeleteDeviceRequest, Empty> deleteDeviceSetting
321298
return getStubSettingsBuilder().updateDeviceRegistrySettings();
322299
}
323300

301+
/** Returns the builder for the settings used for calls to deleteDeviceRegistry. */
302+
public UnaryCallSettings.Builder<DeleteDeviceRegistryRequest, Empty>
303+
deleteDeviceRegistrySettings() {
304+
return getStubSettingsBuilder().deleteDeviceRegistrySettings();
305+
}
306+
324307
/** Returns the builder for the settings used for calls to listDeviceRegistries. */
325308
public PagedCallSettings.Builder<
326309
ListDeviceRegistriesRequest,
@@ -345,13 +328,24 @@ public UnaryCallSettings.Builder<UpdateDeviceRequest, Device> updateDeviceSettin
345328
return getStubSettingsBuilder().updateDeviceSettings();
346329
}
347330

331+
/** Returns the builder for the settings used for calls to deleteDevice. */
332+
public UnaryCallSettings.Builder<DeleteDeviceRequest, Empty> deleteDeviceSettings() {
333+
return getStubSettingsBuilder().deleteDeviceSettings();
334+
}
335+
348336
/** Returns the builder for the settings used for calls to listDevices. */
349337
public PagedCallSettings.Builder<
350338
ListDevicesRequest, ListDevicesResponse, ListDevicesPagedResponse>
351339
listDevicesSettings() {
352340
return getStubSettingsBuilder().listDevicesSettings();
353341
}
354342

343+
/** Returns the builder for the settings used for calls to modifyCloudToDeviceConfig. */
344+
public UnaryCallSettings.Builder<ModifyCloudToDeviceConfigRequest, DeviceConfig>
345+
modifyCloudToDeviceConfigSettings() {
346+
return getStubSettingsBuilder().modifyCloudToDeviceConfigSettings();
347+
}
348+
355349
/** Returns the builder for the settings used for calls to listDeviceConfigVersions. */
356350
public UnaryCallSettings.Builder<
357351
ListDeviceConfigVersionsRequest, ListDeviceConfigVersionsResponse>
@@ -381,6 +375,12 @@ public UnaryCallSettings.Builder<GetIamPolicyRequest, Policy> getIamPolicySettin
381375
return getStubSettingsBuilder().testIamPermissionsSettings();
382376
}
383377

378+
/** Returns the builder for the settings used for calls to sendCommandToDevice. */
379+
public UnaryCallSettings.Builder<SendCommandToDeviceRequest, SendCommandToDeviceResponse>
380+
sendCommandToDeviceSettings() {
381+
return getStubSettingsBuilder().sendCommandToDeviceSettings();
382+
}
383+
384384
/** Returns the builder for the settings used for calls to bindDeviceToGateway. */
385385
public UnaryCallSettings.Builder<BindDeviceToGatewayRequest, BindDeviceToGatewayResponse>
386386
bindDeviceToGatewaySettings() {

google-cloud-iot/src/main/java/com/google/cloud/iot/v1/package-info.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,9 @@
2929
* <pre>
3030
* <code>
3131
* try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
32-
* RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
33-
* deviceManagerClient.deleteDeviceRegistry(name);
32+
* LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
33+
* DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
34+
* DeviceRegistry response = deviceManagerClient.createDeviceRegistry(parent, deviceRegistry);
3435
* }
3536
* </code>
3637
* </pre>

google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/DeviceManagerStub.java

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -65,24 +65,6 @@
6565
@BetaApi("A restructuring of stub classes is planned, so this may break in the future")
6666
public abstract class DeviceManagerStub implements BackgroundResource {
6767

68-
public UnaryCallable<DeleteDeviceRegistryRequest, Empty> deleteDeviceRegistryCallable() {
69-
throw new UnsupportedOperationException("Not implemented: deleteDeviceRegistryCallable()");
70-
}
71-
72-
public UnaryCallable<DeleteDeviceRequest, Empty> deleteDeviceCallable() {
73-
throw new UnsupportedOperationException("Not implemented: deleteDeviceCallable()");
74-
}
75-
76-
public UnaryCallable<ModifyCloudToDeviceConfigRequest, DeviceConfig>
77-
modifyCloudToDeviceConfigCallable() {
78-
throw new UnsupportedOperationException("Not implemented: modifyCloudToDeviceConfigCallable()");
79-
}
80-
81-
public UnaryCallable<SendCommandToDeviceRequest, SendCommandToDeviceResponse>
82-
sendCommandToDeviceCallable() {
83-
throw new UnsupportedOperationException("Not implemented: sendCommandToDeviceCallable()");
84-
}
85-
8668
public UnaryCallable<CreateDeviceRegistryRequest, DeviceRegistry> createDeviceRegistryCallable() {
8769
throw new UnsupportedOperationException("Not implemented: createDeviceRegistryCallable()");
8870
}
@@ -95,6 +77,10 @@ public UnaryCallable<UpdateDeviceRegistryRequest, DeviceRegistry> updateDeviceRe
9577
throw new UnsupportedOperationException("Not implemented: updateDeviceRegistryCallable()");
9678
}
9779

80+
public UnaryCallable<DeleteDeviceRegistryRequest, Empty> deleteDeviceRegistryCallable() {
81+
throw new UnsupportedOperationException("Not implemented: deleteDeviceRegistryCallable()");
82+
}
83+
9884
public UnaryCallable<ListDeviceRegistriesRequest, ListDeviceRegistriesPagedResponse>
9985
listDeviceRegistriesPagedCallable() {
10086
throw new UnsupportedOperationException("Not implemented: listDeviceRegistriesPagedCallable()");
@@ -117,6 +103,10 @@ public UnaryCallable<UpdateDeviceRequest, Device> updateDeviceCallable() {
117103
throw new UnsupportedOperationException("Not implemented: updateDeviceCallable()");
118104
}
119105

106+
public UnaryCallable<DeleteDeviceRequest, Empty> deleteDeviceCallable() {
107+
throw new UnsupportedOperationException("Not implemented: deleteDeviceCallable()");
108+
}
109+
120110
public UnaryCallable<ListDevicesRequest, ListDevicesPagedResponse> listDevicesPagedCallable() {
121111
throw new UnsupportedOperationException("Not implemented: listDevicesPagedCallable()");
122112
}
@@ -125,6 +115,11 @@ public UnaryCallable<ListDevicesRequest, ListDevicesResponse> listDevicesCallabl
125115
throw new UnsupportedOperationException("Not implemented: listDevicesCallable()");
126116
}
127117

118+
public UnaryCallable<ModifyCloudToDeviceConfigRequest, DeviceConfig>
119+
modifyCloudToDeviceConfigCallable() {
120+
throw new UnsupportedOperationException("Not implemented: modifyCloudToDeviceConfigCallable()");
121+
}
122+
128123
public UnaryCallable<ListDeviceConfigVersionsRequest, ListDeviceConfigVersionsResponse>
129124
listDeviceConfigVersionsCallable() {
130125
throw new UnsupportedOperationException("Not implemented: listDeviceConfigVersionsCallable()");
@@ -148,6 +143,11 @@ public UnaryCallable<GetIamPolicyRequest, Policy> getIamPolicyCallable() {
148143
throw new UnsupportedOperationException("Not implemented: testIamPermissionsCallable()");
149144
}
150145

146+
public UnaryCallable<SendCommandToDeviceRequest, SendCommandToDeviceResponse>
147+
sendCommandToDeviceCallable() {
148+
throw new UnsupportedOperationException("Not implemented: sendCommandToDeviceCallable()");
149+
}
150+
151151
public UnaryCallable<BindDeviceToGatewayRequest, BindDeviceToGatewayResponse>
152152
bindDeviceToGatewayCallable() {
153153
throw new UnsupportedOperationException("Not implemented: bindDeviceToGatewayCallable()");

0 commit comments

Comments
 (0)