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

Commit 8ea2edc

Browse files
fix: restore GAPIC v2 retry configs (#170)
This PR was generated using Autosynth. 🌈 Synth log will be available here: https://source.cloud.google.com/results/invocations/b94bacd6-05ee-45c2-be4d-b0f667030fab/targets PiperOrigin-RevId: 312088359 Source-Link: googleapis/googleapis@5a90d46
1 parent afc2ac2 commit 8ea2edc

File tree

8 files changed

+1309
-1311
lines changed

8 files changed

+1309
-1311
lines changed

google-cloud-datalabeling/src/main/java/com/google/cloud/datalabeling/v1beta1/DataLabelingServiceClient.java

+654-655
Large diffs are not rendered by default.

google-cloud-datalabeling/src/main/java/com/google/cloud/datalabeling/v1beta1/DataLabelingServiceSettings.java

+74-74
Original file line numberDiff line numberDiff line change
@@ -59,16 +59,16 @@
5959
* <p>The builder of this class is recursive, so contained classes are themselves builders. When
6060
* build() is called, the tree of builders is called to create the complete settings object.
6161
*
62-
* <p>For example, to set the total timeout of createDataset to 30 seconds:
62+
* <p>For example, to set the total timeout of deleteDataset to 30 seconds:
6363
*
6464
* <pre>
6565
* <code>
6666
* DataLabelingServiceSettings.Builder dataLabelingServiceSettingsBuilder =
6767
* DataLabelingServiceSettings.newBuilder();
6868
* dataLabelingServiceSettingsBuilder
69-
* .createDatasetSettings()
69+
* .deleteDatasetSettings()
7070
* .setRetrySettings(
71-
* dataLabelingServiceSettingsBuilder.createDatasetSettings().getRetrySettings().toBuilder()
71+
* dataLabelingServiceSettingsBuilder.deleteDatasetSettings().getRetrySettings().toBuilder()
7272
* .setTotalTimeout(Duration.ofSeconds(30))
7373
* .build());
7474
* DataLabelingServiceSettings dataLabelingServiceSettings = dataLabelingServiceSettingsBuilder.build();
@@ -78,6 +78,41 @@
7878
@Generated("by gapic-generator")
7979
@BetaApi
8080
public class DataLabelingServiceSettings extends ClientSettings<DataLabelingServiceSettings> {
81+
/** Returns the object with the settings used for calls to deleteDataset. */
82+
public UnaryCallSettings<DeleteDatasetRequest, Empty> deleteDatasetSettings() {
83+
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteDatasetSettings();
84+
}
85+
86+
/** Returns the object with the settings used for calls to exportData. */
87+
public UnaryCallSettings<ExportDataRequest, Operation> exportDataSettings() {
88+
return ((DataLabelingServiceStubSettings) getStubSettings()).exportDataSettings();
89+
}
90+
91+
/** Returns the object with the settings used for calls to exportData. */
92+
@BetaApi(
93+
"The surface for long-running operations is not stable yet and may change in the future.")
94+
public OperationCallSettings<
95+
ExportDataRequest, ExportDataOperationResponse, ExportDataOperationMetadata>
96+
exportDataOperationSettings() {
97+
return ((DataLabelingServiceStubSettings) getStubSettings()).exportDataOperationSettings();
98+
}
99+
100+
/** Returns the object with the settings used for calls to deleteAnnotationSpecSet. */
101+
public UnaryCallSettings<DeleteAnnotationSpecSetRequest, Empty>
102+
deleteAnnotationSpecSetSettings() {
103+
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteAnnotationSpecSetSettings();
104+
}
105+
106+
/** Returns the object with the settings used for calls to deleteInstruction. */
107+
public UnaryCallSettings<DeleteInstructionRequest, Empty> deleteInstructionSettings() {
108+
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteInstructionSettings();
109+
}
110+
111+
/** Returns the object with the settings used for calls to deleteEvaluationJob. */
112+
public UnaryCallSettings<DeleteEvaluationJobRequest, Empty> deleteEvaluationJobSettings() {
113+
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteEvaluationJobSettings();
114+
}
115+
81116
/** Returns the object with the settings used for calls to createDataset. */
82117
public UnaryCallSettings<CreateDatasetRequest, Dataset> createDatasetSettings() {
83118
return ((DataLabelingServiceStubSettings) getStubSettings()).createDatasetSettings();
@@ -94,11 +129,6 @@ public UnaryCallSettings<GetDatasetRequest, Dataset> getDatasetSettings() {
94129
return ((DataLabelingServiceStubSettings) getStubSettings()).listDatasetsSettings();
95130
}
96131

97-
/** Returns the object with the settings used for calls to deleteDataset. */
98-
public UnaryCallSettings<DeleteDatasetRequest, Empty> deleteDatasetSettings() {
99-
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteDatasetSettings();
100-
}
101-
102132
/** Returns the object with the settings used for calls to importData. */
103133
public UnaryCallSettings<ImportDataRequest, Operation> importDataSettings() {
104134
return ((DataLabelingServiceStubSettings) getStubSettings()).importDataSettings();
@@ -113,20 +143,6 @@ public UnaryCallSettings<ImportDataRequest, Operation> importDataSettings() {
113143
return ((DataLabelingServiceStubSettings) getStubSettings()).importDataOperationSettings();
114144
}
115145

116-
/** Returns the object with the settings used for calls to exportData. */
117-
public UnaryCallSettings<ExportDataRequest, Operation> exportDataSettings() {
118-
return ((DataLabelingServiceStubSettings) getStubSettings()).exportDataSettings();
119-
}
120-
121-
/** Returns the object with the settings used for calls to exportData. */
122-
@BetaApi(
123-
"The surface for long-running operations is not stable yet and may change in the future.")
124-
public OperationCallSettings<
125-
ExportDataRequest, ExportDataOperationResponse, ExportDataOperationMetadata>
126-
exportDataOperationSettings() {
127-
return ((DataLabelingServiceStubSettings) getStubSettings()).exportDataOperationSettings();
128-
}
129-
130146
/** Returns the object with the settings used for calls to getDataItem. */
131147
public UnaryCallSettings<GetDataItemRequest, DataItem> getDataItemSettings() {
132148
return ((DataLabelingServiceStubSettings) getStubSettings()).getDataItemSettings();
@@ -229,12 +245,6 @@ public UnaryCallSettings<GetExampleRequest, Example> getExampleSettings() {
229245
return ((DataLabelingServiceStubSettings) getStubSettings()).listAnnotationSpecSetsSettings();
230246
}
231247

232-
/** Returns the object with the settings used for calls to deleteAnnotationSpecSet. */
233-
public UnaryCallSettings<DeleteAnnotationSpecSetRequest, Empty>
234-
deleteAnnotationSpecSetSettings() {
235-
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteAnnotationSpecSetSettings();
236-
}
237-
238248
/** Returns the object with the settings used for calls to createInstruction. */
239249
public UnaryCallSettings<CreateInstructionRequest, Operation> createInstructionSettings() {
240250
return ((DataLabelingServiceStubSettings) getStubSettings()).createInstructionSettings();
@@ -261,11 +271,6 @@ public UnaryCallSettings<GetInstructionRequest, Instruction> getInstructionSetti
261271
return ((DataLabelingServiceStubSettings) getStubSettings()).listInstructionsSettings();
262272
}
263273

264-
/** Returns the object with the settings used for calls to deleteInstruction. */
265-
public UnaryCallSettings<DeleteInstructionRequest, Empty> deleteInstructionSettings() {
266-
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteInstructionSettings();
267-
}
268-
269274
/** Returns the object with the settings used for calls to getEvaluation. */
270275
public UnaryCallSettings<GetEvaluationRequest, Evaluation> getEvaluationSettings() {
271276
return ((DataLabelingServiceStubSettings) getStubSettings()).getEvaluationSettings();
@@ -314,11 +319,6 @@ public UnaryCallSettings<ResumeEvaluationJobRequest, Empty> resumeEvaluationJobS
314319
return ((DataLabelingServiceStubSettings) getStubSettings()).resumeEvaluationJobSettings();
315320
}
316321

317-
/** Returns the object with the settings used for calls to deleteEvaluationJob. */
318-
public UnaryCallSettings<DeleteEvaluationJobRequest, Empty> deleteEvaluationJobSettings() {
319-
return ((DataLabelingServiceStubSettings) getStubSettings()).deleteEvaluationJobSettings();
320-
}
321-
322322
/** Returns the object with the settings used for calls to listEvaluationJobs. */
323323
public PagedCallSettings<
324324
ListEvaluationJobsRequest, ListEvaluationJobsResponse, ListEvaluationJobsPagedResponse>
@@ -423,6 +423,42 @@ public Builder applyToAllUnaryMethods(
423423
return this;
424424
}
425425

426+
/** Returns the builder for the settings used for calls to deleteDataset. */
427+
public UnaryCallSettings.Builder<DeleteDatasetRequest, Empty> deleteDatasetSettings() {
428+
return getStubSettingsBuilder().deleteDatasetSettings();
429+
}
430+
431+
/** Returns the builder for the settings used for calls to exportData. */
432+
public UnaryCallSettings.Builder<ExportDataRequest, Operation> exportDataSettings() {
433+
return getStubSettingsBuilder().exportDataSettings();
434+
}
435+
436+
/** Returns the builder for the settings used for calls to exportData. */
437+
@BetaApi(
438+
"The surface for long-running operations is not stable yet and may change in the future.")
439+
public OperationCallSettings.Builder<
440+
ExportDataRequest, ExportDataOperationResponse, ExportDataOperationMetadata>
441+
exportDataOperationSettings() {
442+
return getStubSettingsBuilder().exportDataOperationSettings();
443+
}
444+
445+
/** Returns the builder for the settings used for calls to deleteAnnotationSpecSet. */
446+
public UnaryCallSettings.Builder<DeleteAnnotationSpecSetRequest, Empty>
447+
deleteAnnotationSpecSetSettings() {
448+
return getStubSettingsBuilder().deleteAnnotationSpecSetSettings();
449+
}
450+
451+
/** Returns the builder for the settings used for calls to deleteInstruction. */
452+
public UnaryCallSettings.Builder<DeleteInstructionRequest, Empty> deleteInstructionSettings() {
453+
return getStubSettingsBuilder().deleteInstructionSettings();
454+
}
455+
456+
/** Returns the builder for the settings used for calls to deleteEvaluationJob. */
457+
public UnaryCallSettings.Builder<DeleteEvaluationJobRequest, Empty>
458+
deleteEvaluationJobSettings() {
459+
return getStubSettingsBuilder().deleteEvaluationJobSettings();
460+
}
461+
426462
/** Returns the builder for the settings used for calls to createDataset. */
427463
public UnaryCallSettings.Builder<CreateDatasetRequest, Dataset> createDatasetSettings() {
428464
return getStubSettingsBuilder().createDatasetSettings();
@@ -440,11 +476,6 @@ public UnaryCallSettings.Builder<GetDatasetRequest, Dataset> getDatasetSettings(
440476
return getStubSettingsBuilder().listDatasetsSettings();
441477
}
442478

443-
/** Returns the builder for the settings used for calls to deleteDataset. */
444-
public UnaryCallSettings.Builder<DeleteDatasetRequest, Empty> deleteDatasetSettings() {
445-
return getStubSettingsBuilder().deleteDatasetSettings();
446-
}
447-
448479
/** Returns the builder for the settings used for calls to importData. */
449480
public UnaryCallSettings.Builder<ImportDataRequest, Operation> importDataSettings() {
450481
return getStubSettingsBuilder().importDataSettings();
@@ -459,20 +490,6 @@ public UnaryCallSettings.Builder<ImportDataRequest, Operation> importDataSetting
459490
return getStubSettingsBuilder().importDataOperationSettings();
460491
}
461492

462-
/** Returns the builder for the settings used for calls to exportData. */
463-
public UnaryCallSettings.Builder<ExportDataRequest, Operation> exportDataSettings() {
464-
return getStubSettingsBuilder().exportDataSettings();
465-
}
466-
467-
/** Returns the builder for the settings used for calls to exportData. */
468-
@BetaApi(
469-
"The surface for long-running operations is not stable yet and may change in the future.")
470-
public OperationCallSettings.Builder<
471-
ExportDataRequest, ExportDataOperationResponse, ExportDataOperationMetadata>
472-
exportDataOperationSettings() {
473-
return getStubSettingsBuilder().exportDataOperationSettings();
474-
}
475-
476493
/** Returns the builder for the settings used for calls to getDataItem. */
477494
public UnaryCallSettings.Builder<GetDataItemRequest, DataItem> getDataItemSettings() {
478495
return getStubSettingsBuilder().getDataItemSettings();
@@ -580,12 +597,6 @@ public UnaryCallSettings.Builder<GetExampleRequest, Example> getExampleSettings(
580597
return getStubSettingsBuilder().listAnnotationSpecSetsSettings();
581598
}
582599

583-
/** Returns the builder for the settings used for calls to deleteAnnotationSpecSet. */
584-
public UnaryCallSettings.Builder<DeleteAnnotationSpecSetRequest, Empty>
585-
deleteAnnotationSpecSetSettings() {
586-
return getStubSettingsBuilder().deleteAnnotationSpecSetSettings();
587-
}
588-
589600
/** Returns the builder for the settings used for calls to createInstruction. */
590601
public UnaryCallSettings.Builder<CreateInstructionRequest, Operation>
591602
createInstructionSettings() {
@@ -613,11 +624,6 @@ public UnaryCallSettings.Builder<GetInstructionRequest, Instruction> getInstruct
613624
return getStubSettingsBuilder().listInstructionsSettings();
614625
}
615626

616-
/** Returns the builder for the settings used for calls to deleteInstruction. */
617-
public UnaryCallSettings.Builder<DeleteInstructionRequest, Empty> deleteInstructionSettings() {
618-
return getStubSettingsBuilder().deleteInstructionSettings();
619-
}
620-
621627
/** Returns the builder for the settings used for calls to getEvaluation. */
622628
public UnaryCallSettings.Builder<GetEvaluationRequest, Evaluation> getEvaluationSettings() {
623629
return getStubSettingsBuilder().getEvaluationSettings();
@@ -669,12 +675,6 @@ public UnaryCallSettings.Builder<GetEvaluationRequest, Evaluation> getEvaluation
669675
return getStubSettingsBuilder().resumeEvaluationJobSettings();
670676
}
671677

672-
/** Returns the builder for the settings used for calls to deleteEvaluationJob. */
673-
public UnaryCallSettings.Builder<DeleteEvaluationJobRequest, Empty>
674-
deleteEvaluationJobSettings() {
675-
return getStubSettingsBuilder().deleteEvaluationJobSettings();
676-
}
677-
678678
/** Returns the builder for the settings used for calls to listEvaluationJobs. */
679679
public PagedCallSettings.Builder<
680680
ListEvaluationJobsRequest, ListEvaluationJobsResponse, ListEvaluationJobsPagedResponse>

google-cloud-datalabeling/src/main/java/com/google/cloud/datalabeling/v1beta1/package-info.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,8 @@
2828
* <pre>
2929
* <code>
3030
* try (DataLabelingServiceClient dataLabelingServiceClient = DataLabelingServiceClient.create()) {
31-
* ProjectName parent = ProjectName.of("[PROJECT]");
32-
* Dataset dataset = Dataset.newBuilder().build();
33-
* Dataset response = dataLabelingServiceClient.createDataset(parent, dataset);
31+
* DatasetName name = DatasetName.of("[PROJECT]", "[DATASET]");
32+
* dataLabelingServiceClient.deleteDataset(name);
3433
* }
3534
* </code>
3635
* </pre>

google-cloud-datalabeling/src/main/java/com/google/cloud/datalabeling/v1beta1/stub/DataLabelingServiceStub.java

+27-27
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,33 @@ public OperationsStub getOperationsStub() {
106106
throw new UnsupportedOperationException("Not implemented: getOperationsStub()");
107107
}
108108

109+
public UnaryCallable<DeleteDatasetRequest, Empty> deleteDatasetCallable() {
110+
throw new UnsupportedOperationException("Not implemented: deleteDatasetCallable()");
111+
}
112+
113+
@BetaApi("The surface for use by generated code is not stable yet and may change in the future.")
114+
public OperationCallable<
115+
ExportDataRequest, ExportDataOperationResponse, ExportDataOperationMetadata>
116+
exportDataOperationCallable() {
117+
throw new UnsupportedOperationException("Not implemented: exportDataOperationCallable()");
118+
}
119+
120+
public UnaryCallable<ExportDataRequest, Operation> exportDataCallable() {
121+
throw new UnsupportedOperationException("Not implemented: exportDataCallable()");
122+
}
123+
124+
public UnaryCallable<DeleteAnnotationSpecSetRequest, Empty> deleteAnnotationSpecSetCallable() {
125+
throw new UnsupportedOperationException("Not implemented: deleteAnnotationSpecSetCallable()");
126+
}
127+
128+
public UnaryCallable<DeleteInstructionRequest, Empty> deleteInstructionCallable() {
129+
throw new UnsupportedOperationException("Not implemented: deleteInstructionCallable()");
130+
}
131+
132+
public UnaryCallable<DeleteEvaluationJobRequest, Empty> deleteEvaluationJobCallable() {
133+
throw new UnsupportedOperationException("Not implemented: deleteEvaluationJobCallable()");
134+
}
135+
109136
public UnaryCallable<CreateDatasetRequest, Dataset> createDatasetCallable() {
110137
throw new UnsupportedOperationException("Not implemented: createDatasetCallable()");
111138
}
@@ -122,10 +149,6 @@ public UnaryCallable<ListDatasetsRequest, ListDatasetsResponse> listDatasetsCall
122149
throw new UnsupportedOperationException("Not implemented: listDatasetsCallable()");
123150
}
124151

125-
public UnaryCallable<DeleteDatasetRequest, Empty> deleteDatasetCallable() {
126-
throw new UnsupportedOperationException("Not implemented: deleteDatasetCallable()");
127-
}
128-
129152
@BetaApi("The surface for use by generated code is not stable yet and may change in the future.")
130153
public OperationCallable<
131154
ImportDataRequest, ImportDataOperationResponse, ImportDataOperationMetadata>
@@ -137,17 +160,6 @@ public UnaryCallable<ImportDataRequest, Operation> importDataCallable() {
137160
throw new UnsupportedOperationException("Not implemented: importDataCallable()");
138161
}
139162

140-
@BetaApi("The surface for use by generated code is not stable yet and may change in the future.")
141-
public OperationCallable<
142-
ExportDataRequest, ExportDataOperationResponse, ExportDataOperationMetadata>
143-
exportDataOperationCallable() {
144-
throw new UnsupportedOperationException("Not implemented: exportDataOperationCallable()");
145-
}
146-
147-
public UnaryCallable<ExportDataRequest, Operation> exportDataCallable() {
148-
throw new UnsupportedOperationException("Not implemented: exportDataCallable()");
149-
}
150-
151163
public UnaryCallable<GetDataItemRequest, DataItem> getDataItemCallable() {
152164
throw new UnsupportedOperationException("Not implemented: getDataItemCallable()");
153165
}
@@ -243,10 +255,6 @@ public UnaryCallable<ListExamplesRequest, ListExamplesResponse> listExamplesCall
243255
throw new UnsupportedOperationException("Not implemented: listAnnotationSpecSetsCallable()");
244256
}
245257

246-
public UnaryCallable<DeleteAnnotationSpecSetRequest, Empty> deleteAnnotationSpecSetCallable() {
247-
throw new UnsupportedOperationException("Not implemented: deleteAnnotationSpecSetCallable()");
248-
}
249-
250258
@BetaApi("The surface for use by generated code is not stable yet and may change in the future.")
251259
public OperationCallable<CreateInstructionRequest, Instruction, CreateInstructionMetadata>
252260
createInstructionOperationCallable() {
@@ -272,10 +280,6 @@ public UnaryCallable<GetInstructionRequest, Instruction> getInstructionCallable(
272280
throw new UnsupportedOperationException("Not implemented: listInstructionsCallable()");
273281
}
274282

275-
public UnaryCallable<DeleteInstructionRequest, Empty> deleteInstructionCallable() {
276-
throw new UnsupportedOperationException("Not implemented: deleteInstructionCallable()");
277-
}
278-
279283
public UnaryCallable<GetEvaluationRequest, Evaluation> getEvaluationCallable() {
280284
throw new UnsupportedOperationException("Not implemented: getEvaluationCallable()");
281285
}
@@ -321,10 +325,6 @@ public UnaryCallable<ResumeEvaluationJobRequest, Empty> resumeEvaluationJobCalla
321325
throw new UnsupportedOperationException("Not implemented: resumeEvaluationJobCallable()");
322326
}
323327

324-
public UnaryCallable<DeleteEvaluationJobRequest, Empty> deleteEvaluationJobCallable() {
325-
throw new UnsupportedOperationException("Not implemented: deleteEvaluationJobCallable()");
326-
}
327-
328328
public UnaryCallable<ListEvaluationJobsRequest, ListEvaluationJobsPagedResponse>
329329
listEvaluationJobsPagedCallable() {
330330
throw new UnsupportedOperationException("Not implemented: listEvaluationJobsPagedCallable()");

0 commit comments

Comments
 (0)