Skip to content

Commit 66d765f

Browse files
committed
Prepare v0.1.389 release
Signed-off-by: Maggie Chen <[email protected]>
1 parent 1c0b3ee commit 66d765f

File tree

6 files changed

+18550
-18402
lines changed

6 files changed

+18550
-18402
lines changed

CHANGES.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
This document describes the relevant changes between releases of the OCM API
44
SDK.
55

6+
## 0.1.389
7+
- Update model version v0.0.342
8+
- Add `Search` and `Order` methods to List `/api/clusters_mgmt/v1/clusters/{id}/node_pools`
69

710
## 0.1.388
811
- Update model version v0.0.341

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export PATH := $(LOCAL_BIN_PATH):$(PATH)
2727
export CGO_ENABLED=0
2828

2929
# Details of the model to use:
30-
model_version:=v0.0.341
30+
model_version:=v0.0.342
3131
model_url:=https://github.com/openshift-online/ocm-api-model.git
3232

3333
# Details of the metamodel to use:

clustersmgmt/v1/node_pools_client.go

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,9 @@ type NodePoolsListRequest struct {
235235
path string
236236
query url.Values
237237
header http.Header
238+
order *string
238239
page *int
240+
search *string
239241
size *int
240242
}
241243

@@ -258,6 +260,26 @@ func (r *NodePoolsListRequest) Impersonate(user string) *NodePoolsListRequest {
258260
return r
259261
}
260262

263+
// Order sets the value of the 'order' parameter.
264+
//
265+
// Order criteria.
266+
//
267+
// The syntax of this parameter is similar to the syntax of the _order by_ clause of
268+
// a SQL statement, but using the names of the attributes of the node pools instead of
269+
// the names of the columns of a table. For example, in order to sort the node pools
270+
// descending by identifier the value should be:
271+
//
272+
// ```sql
273+
// id desc
274+
// ```
275+
//
276+
// If the parameter isn't provided, or if the value is empty, then the order of the
277+
// results is undefined.
278+
func (r *NodePoolsListRequest) Order(value string) *NodePoolsListRequest {
279+
r.order = &value
280+
return r
281+
}
282+
261283
// Page sets the value of the 'page' parameter.
262284
//
263285
// Index of the requested page, where one corresponds to the first page.
@@ -266,6 +288,26 @@ func (r *NodePoolsListRequest) Page(value int) *NodePoolsListRequest {
266288
return r
267289
}
268290

291+
// Search sets the value of the 'search' parameter.
292+
//
293+
// Search criteria.
294+
//
295+
// The syntax of this parameter is similar to the syntax of the _where_ clause of a
296+
// SQL statement, but using the names of the attributes of the node pools instead of
297+
// the names of the columns of a table. For example, in order to retrieve all the
298+
// node pools with replicas of two the following is required:
299+
//
300+
// ```sql
301+
// replicas = 2
302+
// ```
303+
//
304+
// If the parameter isn't provided, or if the value is empty, then all the
305+
// node pools that the user has permission to see will be returned.
306+
func (r *NodePoolsListRequest) Search(value string) *NodePoolsListRequest {
307+
r.search = &value
308+
return r
309+
}
310+
269311
// Size sets the value of the 'size' parameter.
270312
//
271313
// Number of items contained in the returned page.
@@ -285,9 +327,15 @@ func (r *NodePoolsListRequest) Send() (result *NodePoolsListResponse, err error)
285327
// SendContext sends this request, waits for the response, and returns it.
286328
func (r *NodePoolsListRequest) SendContext(ctx context.Context) (result *NodePoolsListResponse, err error) {
287329
query := helpers.CopyQuery(r.query)
330+
if r.order != nil {
331+
helpers.AddValue(&query, "order", *r.order)
332+
}
288333
if r.page != nil {
289334
helpers.AddValue(&query, "page", *r.page)
290335
}
336+
if r.search != nil {
337+
helpers.AddValue(&query, "search", *r.search)
338+
}
291339
if r.size != nil {
292340
helpers.AddValue(&query, "size", *r.size)
293341
}

0 commit comments

Comments
 (0)