Skip to content

Commit 0e78fa9

Browse files
fix(client): remove @MustBeClosed for future returning methods
1 parent d1cacea commit 0e78fa9

File tree

11 files changed

+0
-97
lines changed

11 files changed

+0
-97
lines changed

openlayer-java-core/src/main/kotlin/com/openlayer/api/services/async/CommitServiceAsync.kt

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
package com.openlayer.api.services.async
44

5-
import com.google.errorprone.annotations.MustBeClosed
65
import com.openlayer.api.core.RequestOptions
76
import com.openlayer.api.core.http.HttpResponseFor
87
import com.openlayer.api.models.commits.CommitRetrieveParams
@@ -66,14 +65,12 @@ interface CommitServiceAsync {
6665
* Returns a raw HTTP response for `get /versions/{projectVersionId}`, but is otherwise the
6766
* same as [CommitServiceAsync.retrieve].
6867
*/
69-
@MustBeClosed
7068
fun retrieve(
7169
projectVersionId: String
7270
): CompletableFuture<HttpResponseFor<CommitRetrieveResponse>> =
7371
retrieve(projectVersionId, CommitRetrieveParams.none())
7472

7573
/** @see [retrieve] */
76-
@MustBeClosed
7774
fun retrieve(
7875
projectVersionId: String,
7976
params: CommitRetrieveParams = CommitRetrieveParams.none(),
@@ -82,29 +79,25 @@ interface CommitServiceAsync {
8279
retrieve(params.toBuilder().projectVersionId(projectVersionId).build(), requestOptions)
8380

8481
/** @see [retrieve] */
85-
@MustBeClosed
8682
fun retrieve(
8783
projectVersionId: String,
8884
params: CommitRetrieveParams = CommitRetrieveParams.none(),
8985
): CompletableFuture<HttpResponseFor<CommitRetrieveResponse>> =
9086
retrieve(projectVersionId, params, RequestOptions.none())
9187

9288
/** @see [retrieve] */
93-
@MustBeClosed
9489
fun retrieve(
9590
params: CommitRetrieveParams,
9691
requestOptions: RequestOptions = RequestOptions.none(),
9792
): CompletableFuture<HttpResponseFor<CommitRetrieveResponse>>
9893

9994
/** @see [retrieve] */
100-
@MustBeClosed
10195
fun retrieve(
10296
params: CommitRetrieveParams
10397
): CompletableFuture<HttpResponseFor<CommitRetrieveResponse>> =
10498
retrieve(params, RequestOptions.none())
10599

106100
/** @see [retrieve] */
107-
@MustBeClosed
108101
fun retrieve(
109102
projectVersionId: String,
110103
requestOptions: RequestOptions,

openlayer-java-core/src/main/kotlin/com/openlayer/api/services/async/InferencePipelineServiceAsync.kt

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
package com.openlayer.api.services.async
44

5-
import com.google.errorprone.annotations.MustBeClosed
65
import com.openlayer.api.core.RequestOptions
76
import com.openlayer.api.core.http.HttpResponse
87
import com.openlayer.api.core.http.HttpResponseFor
@@ -160,14 +159,12 @@ interface InferencePipelineServiceAsync {
160159
* Returns a raw HTTP response for `get /inference-pipelines/{inferencePipelineId}`, but is
161160
* otherwise the same as [InferencePipelineServiceAsync.retrieve].
162161
*/
163-
@MustBeClosed
164162
fun retrieve(
165163
inferencePipelineId: String
166164
): CompletableFuture<HttpResponseFor<InferencePipelineRetrieveResponse>> =
167165
retrieve(inferencePipelineId, InferencePipelineRetrieveParams.none())
168166

169167
/** @see [retrieve] */
170-
@MustBeClosed
171168
fun retrieve(
172169
inferencePipelineId: String,
173170
params: InferencePipelineRetrieveParams = InferencePipelineRetrieveParams.none(),
@@ -179,29 +176,25 @@ interface InferencePipelineServiceAsync {
179176
)
180177

181178
/** @see [retrieve] */
182-
@MustBeClosed
183179
fun retrieve(
184180
inferencePipelineId: String,
185181
params: InferencePipelineRetrieveParams = InferencePipelineRetrieveParams.none(),
186182
): CompletableFuture<HttpResponseFor<InferencePipelineRetrieveResponse>> =
187183
retrieve(inferencePipelineId, params, RequestOptions.none())
188184

189185
/** @see [retrieve] */
190-
@MustBeClosed
191186
fun retrieve(
192187
params: InferencePipelineRetrieveParams,
193188
requestOptions: RequestOptions = RequestOptions.none(),
194189
): CompletableFuture<HttpResponseFor<InferencePipelineRetrieveResponse>>
195190

196191
/** @see [retrieve] */
197-
@MustBeClosed
198192
fun retrieve(
199193
params: InferencePipelineRetrieveParams
200194
): CompletableFuture<HttpResponseFor<InferencePipelineRetrieveResponse>> =
201195
retrieve(params, RequestOptions.none())
202196

203197
/** @see [retrieve] */
204-
@MustBeClosed
205198
fun retrieve(
206199
inferencePipelineId: String,
207200
requestOptions: RequestOptions,
@@ -212,14 +205,12 @@ interface InferencePipelineServiceAsync {
212205
* Returns a raw HTTP response for `put /inference-pipelines/{inferencePipelineId}`, but is
213206
* otherwise the same as [InferencePipelineServiceAsync.update].
214207
*/
215-
@MustBeClosed
216208
fun update(
217209
inferencePipelineId: String
218210
): CompletableFuture<HttpResponseFor<InferencePipelineUpdateResponse>> =
219211
update(inferencePipelineId, InferencePipelineUpdateParams.none())
220212

221213
/** @see [update] */
222-
@MustBeClosed
223214
fun update(
224215
inferencePipelineId: String,
225216
params: InferencePipelineUpdateParams = InferencePipelineUpdateParams.none(),
@@ -231,29 +222,25 @@ interface InferencePipelineServiceAsync {
231222
)
232223

233224
/** @see [update] */
234-
@MustBeClosed
235225
fun update(
236226
inferencePipelineId: String,
237227
params: InferencePipelineUpdateParams = InferencePipelineUpdateParams.none(),
238228
): CompletableFuture<HttpResponseFor<InferencePipelineUpdateResponse>> =
239229
update(inferencePipelineId, params, RequestOptions.none())
240230

241231
/** @see [update] */
242-
@MustBeClosed
243232
fun update(
244233
params: InferencePipelineUpdateParams,
245234
requestOptions: RequestOptions = RequestOptions.none(),
246235
): CompletableFuture<HttpResponseFor<InferencePipelineUpdateResponse>>
247236

248237
/** @see [update] */
249-
@MustBeClosed
250238
fun update(
251239
params: InferencePipelineUpdateParams
252240
): CompletableFuture<HttpResponseFor<InferencePipelineUpdateResponse>> =
253241
update(params, RequestOptions.none())
254242

255243
/** @see [update] */
256-
@MustBeClosed
257244
fun update(
258245
inferencePipelineId: String,
259246
requestOptions: RequestOptions,
@@ -264,12 +251,10 @@ interface InferencePipelineServiceAsync {
264251
* Returns a raw HTTP response for `delete /inference-pipelines/{inferencePipelineId}`, but
265252
* is otherwise the same as [InferencePipelineServiceAsync.delete].
266253
*/
267-
@MustBeClosed
268254
fun delete(inferencePipelineId: String): CompletableFuture<HttpResponse> =
269255
delete(inferencePipelineId, InferencePipelineDeleteParams.none())
270256

271257
/** @see [delete] */
272-
@MustBeClosed
273258
fun delete(
274259
inferencePipelineId: String,
275260
params: InferencePipelineDeleteParams = InferencePipelineDeleteParams.none(),
@@ -281,27 +266,23 @@ interface InferencePipelineServiceAsync {
281266
)
282267

283268
/** @see [delete] */
284-
@MustBeClosed
285269
fun delete(
286270
inferencePipelineId: String,
287271
params: InferencePipelineDeleteParams = InferencePipelineDeleteParams.none(),
288272
): CompletableFuture<HttpResponse> =
289273
delete(inferencePipelineId, params, RequestOptions.none())
290274

291275
/** @see [delete] */
292-
@MustBeClosed
293276
fun delete(
294277
params: InferencePipelineDeleteParams,
295278
requestOptions: RequestOptions = RequestOptions.none(),
296279
): CompletableFuture<HttpResponse>
297280

298281
/** @see [delete] */
299-
@MustBeClosed
300282
fun delete(params: InferencePipelineDeleteParams): CompletableFuture<HttpResponse> =
301283
delete(params, RequestOptions.none())
302284

303285
/** @see [delete] */
304-
@MustBeClosed
305286
fun delete(
306287
inferencePipelineId: String,
307288
requestOptions: RequestOptions,

openlayer-java-core/src/main/kotlin/com/openlayer/api/services/async/ProjectServiceAsync.kt

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
package com.openlayer.api.services.async
44

5-
import com.google.errorprone.annotations.MustBeClosed
65
import com.openlayer.api.core.RequestOptions
76
import com.openlayer.api.core.http.HttpResponseFor
87
import com.openlayer.api.models.projects.ProjectCreateParams
@@ -70,14 +69,12 @@ interface ProjectServiceAsync {
7069
* Returns a raw HTTP response for `post /projects`, but is otherwise the same as
7170
* [ProjectServiceAsync.create].
7271
*/
73-
@MustBeClosed
7472
fun create(
7573
params: ProjectCreateParams
7674
): CompletableFuture<HttpResponseFor<ProjectCreateResponse>> =
7775
create(params, RequestOptions.none())
7876

7977
/** @see [create] */
80-
@MustBeClosed
8178
fun create(
8279
params: ProjectCreateParams,
8380
requestOptions: RequestOptions = RequestOptions.none(),
@@ -87,26 +84,22 @@ interface ProjectServiceAsync {
8784
* Returns a raw HTTP response for `get /projects`, but is otherwise the same as
8885
* [ProjectServiceAsync.list].
8986
*/
90-
@MustBeClosed
9187
fun list(): CompletableFuture<HttpResponseFor<ProjectListResponse>> =
9288
list(ProjectListParams.none())
9389

9490
/** @see [list] */
95-
@MustBeClosed
9691
fun list(
9792
params: ProjectListParams = ProjectListParams.none(),
9893
requestOptions: RequestOptions = RequestOptions.none(),
9994
): CompletableFuture<HttpResponseFor<ProjectListResponse>>
10095

10196
/** @see [list] */
102-
@MustBeClosed
10397
fun list(
10498
params: ProjectListParams = ProjectListParams.none()
10599
): CompletableFuture<HttpResponseFor<ProjectListResponse>> =
106100
list(params, RequestOptions.none())
107101

108102
/** @see [list] */
109-
@MustBeClosed
110103
fun list(
111104
requestOptions: RequestOptions
112105
): CompletableFuture<HttpResponseFor<ProjectListResponse>> =

openlayer-java-core/src/main/kotlin/com/openlayer/api/services/async/commits/TestResultServiceAsync.kt

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
package com.openlayer.api.services.async.commits
44

5-
import com.google.errorprone.annotations.MustBeClosed
65
import com.openlayer.api.core.RequestOptions
76
import com.openlayer.api.core.http.HttpResponseFor
87
import com.openlayer.api.models.commits.testresults.TestResultListParams
@@ -62,14 +61,12 @@ interface TestResultServiceAsync {
6261
* Returns a raw HTTP response for `get /versions/{projectVersionId}/results`, but is
6362
* otherwise the same as [TestResultServiceAsync.list].
6463
*/
65-
@MustBeClosed
6664
fun list(
6765
projectVersionId: String
6866
): CompletableFuture<HttpResponseFor<TestResultListResponse>> =
6967
list(projectVersionId, TestResultListParams.none())
7068

7169
/** @see [list] */
72-
@MustBeClosed
7370
fun list(
7471
projectVersionId: String,
7572
params: TestResultListParams = TestResultListParams.none(),
@@ -78,29 +75,25 @@ interface TestResultServiceAsync {
7875
list(params.toBuilder().projectVersionId(projectVersionId).build(), requestOptions)
7976

8077
/** @see [list] */
81-
@MustBeClosed
8278
fun list(
8379
projectVersionId: String,
8480
params: TestResultListParams = TestResultListParams.none(),
8581
): CompletableFuture<HttpResponseFor<TestResultListResponse>> =
8682
list(projectVersionId, params, RequestOptions.none())
8783

8884
/** @see [list] */
89-
@MustBeClosed
9085
fun list(
9186
params: TestResultListParams,
9287
requestOptions: RequestOptions = RequestOptions.none(),
9388
): CompletableFuture<HttpResponseFor<TestResultListResponse>>
9489

9590
/** @see [list] */
96-
@MustBeClosed
9791
fun list(
9892
params: TestResultListParams
9993
): CompletableFuture<HttpResponseFor<TestResultListResponse>> =
10094
list(params, RequestOptions.none())
10195

10296
/** @see [list] */
103-
@MustBeClosed
10497
fun list(
10598
projectVersionId: String,
10699
requestOptions: RequestOptions,

openlayer-java-core/src/main/kotlin/com/openlayer/api/services/async/inferencepipelines/DataServiceAsync.kt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
package com.openlayer.api.services.async.inferencepipelines
44

5-
import com.google.errorprone.annotations.MustBeClosed
65
import com.openlayer.api.core.RequestOptions
76
import com.openlayer.api.core.http.HttpResponseFor
87
import com.openlayer.api.models.inferencepipelines.data.DataStreamParams
@@ -49,15 +48,13 @@ interface DataServiceAsync {
4948
* /inference-pipelines/{inferencePipelineId}/data-stream`, but is otherwise the same as
5049
* [DataServiceAsync.stream].
5150
*/
52-
@MustBeClosed
5351
fun stream(
5452
inferencePipelineId: String,
5553
params: DataStreamParams,
5654
): CompletableFuture<HttpResponseFor<DataStreamResponse>> =
5755
stream(inferencePipelineId, params, RequestOptions.none())
5856

5957
/** @see [stream] */
60-
@MustBeClosed
6158
fun stream(
6259
inferencePipelineId: String,
6360
params: DataStreamParams,
@@ -69,14 +66,12 @@ interface DataServiceAsync {
6966
)
7067

7168
/** @see [stream] */
72-
@MustBeClosed
7369
fun stream(
7470
params: DataStreamParams
7571
): CompletableFuture<HttpResponseFor<DataStreamResponse>> =
7672
stream(params, RequestOptions.none())
7773

7874
/** @see [stream] */
79-
@MustBeClosed
8075
fun stream(
8176
params: DataStreamParams,
8277
requestOptions: RequestOptions = RequestOptions.none(),

openlayer-java-core/src/main/kotlin/com/openlayer/api/services/async/inferencepipelines/RowServiceAsync.kt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
package com.openlayer.api.services.async.inferencepipelines
44

5-
import com.google.errorprone.annotations.MustBeClosed
65
import com.openlayer.api.core.RequestOptions
76
import com.openlayer.api.core.http.HttpResponseFor
87
import com.openlayer.api.models.inferencepipelines.rows.RowUpdateParams
@@ -48,15 +47,13 @@ interface RowServiceAsync {
4847
* Returns a raw HTTP response for `put /inference-pipelines/{inferencePipelineId}/rows`,
4948
* but is otherwise the same as [RowServiceAsync.update].
5049
*/
51-
@MustBeClosed
5250
fun update(
5351
inferencePipelineId: String,
5452
params: RowUpdateParams,
5553
): CompletableFuture<HttpResponseFor<RowUpdateResponse>> =
5654
update(inferencePipelineId, params, RequestOptions.none())
5755

5856
/** @see [update] */
59-
@MustBeClosed
6057
fun update(
6158
inferencePipelineId: String,
6259
params: RowUpdateParams,
@@ -68,12 +65,10 @@ interface RowServiceAsync {
6865
)
6966

7067
/** @see [update] */
71-
@MustBeClosed
7268
fun update(params: RowUpdateParams): CompletableFuture<HttpResponseFor<RowUpdateResponse>> =
7369
update(params, RequestOptions.none())
7470

7571
/** @see [update] */
76-
@MustBeClosed
7772
fun update(
7873
params: RowUpdateParams,
7974
requestOptions: RequestOptions = RequestOptions.none(),

0 commit comments

Comments
 (0)