Skip to content

Commit daca4a6

Browse files
authored
chore(serverless_jobs): rename id to job_definition_id and id to job_run_id (#1030)
1 parent 3b8add9 commit daca4a6

File tree

2 files changed

+26
-14
lines changed

2 files changed

+26
-14
lines changed

packages/clients/src/api/jobs/v1alpha1/api.gen.ts

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,10 @@ export class API extends ParentAPI {
7777
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam(
7878
'region',
7979
request.region ?? this.client.settings.defaultRegion,
80-
)}/job-definitions/${validatePathParam('id', request.id)}`,
80+
)}/job-definitions/${validatePathParam(
81+
'jobDefinitionId',
82+
request.jobDefinitionId,
83+
)}`,
8184
},
8285
unmarshalJobDefinition,
8386
)
@@ -123,7 +126,10 @@ export class API extends ParentAPI {
123126
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam(
124127
'region',
125128
request.region ?? this.client.settings.defaultRegion,
126-
)}/job-definitions/${validatePathParam('id', request.id)}`,
129+
)}/job-definitions/${validatePathParam(
130+
'jobDefinitionId',
131+
request.jobDefinitionId,
132+
)}`,
127133
},
128134
unmarshalJobDefinition,
129135
)
@@ -134,7 +140,10 @@ export class API extends ParentAPI {
134140
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam(
135141
'region',
136142
request.region ?? this.client.settings.defaultRegion,
137-
)}/job-definitions/${validatePathParam('id', request.id)}`,
143+
)}/job-definitions/${validatePathParam(
144+
'jobDefinitionId',
145+
request.jobDefinitionId,
146+
)}`,
138147
})
139148

140149
startJobDefinition = (request: Readonly<StartJobDefinitionRequest>) =>
@@ -146,7 +155,10 @@ export class API extends ParentAPI {
146155
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam(
147156
'region',
148157
request.region ?? this.client.settings.defaultRegion,
149-
)}/job-definitions/${validatePathParam('id', request.id)}/start`,
158+
)}/job-definitions/${validatePathParam(
159+
'jobDefinitionId',
160+
request.jobDefinitionId,
161+
)}/start`,
150162
},
151163
unmarshalJobRun,
152164
)
@@ -158,7 +170,7 @@ export class API extends ParentAPI {
158170
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam(
159171
'region',
160172
request.region ?? this.client.settings.defaultRegion,
161-
)}/job-runs/${validatePathParam('id', request.id)}`,
173+
)}/job-runs/${validatePathParam('jobRunId', request.jobRunId)}`,
162174
},
163175
unmarshalJobRun,
164176
)
@@ -172,7 +184,7 @@ export class API extends ParentAPI {
172184
path: `/serverless-jobs/v1alpha1/regions/${validatePathParam(
173185
'region',
174186
request.region ?? this.client.settings.defaultRegion,
175-
)}/job-runs/${validatePathParam('id', request.id)}/stop`,
187+
)}/job-runs/${validatePathParam('jobRunId', request.jobRunId)}/stop`,
176188
},
177189
unmarshalJobRun,
178190
)
@@ -186,7 +198,7 @@ export class API extends ParentAPI {
186198
request.region ?? this.client.settings.defaultRegion,
187199
)}/job-runs`,
188200
urlParams: urlParams(
189-
['id', request.id],
201+
['job_definition_id', request.jobDefinitionId],
190202
['order_by', request.orderBy],
191203
['page', request.page],
192204
[

packages/clients/src/api/jobs/v1alpha1/types.gen.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export type DeleteJobDefinitionRequest = {
7777
* config.
7878
*/
7979
region?: Region
80-
id: string
80+
jobDefinitionId: string
8181
}
8282

8383
export type GetJobDefinitionRequest = {
@@ -86,7 +86,7 @@ export type GetJobDefinitionRequest = {
8686
* config.
8787
*/
8888
region?: Region
89-
id: string
89+
jobDefinitionId: string
9090
}
9191

9292
export type GetJobRunRequest = {
@@ -95,7 +95,7 @@ export type GetJobRunRequest = {
9595
* config.
9696
*/
9797
region?: Region
98-
id: string
98+
jobRunId: string
9999
}
100100

101101
export type GetServiceInfoRequest = {
@@ -132,7 +132,7 @@ export type ListJobRunsRequest = {
132132
page?: number
133133
pageSize?: number
134134
orderBy?: ListJobRunsRequestOrderBy
135-
id?: string
135+
jobDefinitionId?: string
136136
projectId?: string
137137
}
138138

@@ -147,7 +147,7 @@ export type StartJobDefinitionRequest = {
147147
* config.
148148
*/
149149
region?: Region
150-
id: string
150+
jobDefinitionId: string
151151
}
152152

153153
export type StopJobRunRequest = {
@@ -156,7 +156,7 @@ export type StopJobRunRequest = {
156156
* config.
157157
*/
158158
region?: Region
159-
id: string
159+
jobRunId: string
160160
}
161161

162162
export type UpdateJobDefinitionRequest = {
@@ -165,7 +165,7 @@ export type UpdateJobDefinitionRequest = {
165165
* config.
166166
*/
167167
region?: Region
168-
id: string
168+
jobDefinitionId: string
169169
name?: string
170170
cpuLimit?: number
171171
memoryLimit?: number

0 commit comments

Comments
 (0)