Skip to content

Commit f7c3f98

Browse files
committed
id lowercse
1 parent da28316 commit f7c3f98

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

cmd/pipelines/run.go

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -136,40 +136,40 @@ func displayProgressEvents(ctx context.Context, events []pipelines.PipelineEvent
136136
}
137137

138138
// fetchAndDisplayPipelineUpdate fetches the update and the update's associated update_progress events' durations.
139-
func fetchAndDisplayPipelineUpdate(ctx context.Context, w *databricks.WorkspaceClient, pipelineID, updateID string) error {
140-
if pipelineID == "" {
139+
func fetchAndDisplayPipelineUpdate(ctx context.Context, w *databricks.WorkspaceClient, pipelineId, updateId string) error {
140+
if pipelineId == "" {
141141
return errors.New("no pipeline ID provided")
142142
}
143-
if updateID == "" {
143+
if updateId == "" {
144144
return errors.New("no update ID provided")
145145
}
146146

147147
getUpdateResponse, err := w.Pipelines.GetUpdate(ctx, pipelines.GetUpdateRequest{
148-
PipelineId: pipelineID,
149-
UpdateId: updateID,
148+
PipelineId: pipelineId,
149+
UpdateId: updateId,
150150
})
151151
if err != nil {
152152
return err
153153
}
154154

155155
if getUpdateResponse.Update == nil {
156-
return fmt.Errorf("no update found with id %s for pipeline %s", updateID, pipelineID)
156+
return fmt.Errorf("no update found with id %s for pipeline %s", updateId, pipelineId)
157157
}
158158

159159
latestUpdate := *getUpdateResponse.Update
160160

161161
params := &PipelineEventsQueryParams{
162-
Filter: fmt.Sprintf("update_id='%s' AND event_type='update_progress'", updateID),
162+
Filter: fmt.Sprintf("update_id='%s' AND event_type='update_progress'", updateId),
163163
OrderBy: "timestamp asc",
164164
}
165165

166-
events, err := fetchAllPipelineEvents(ctx, w, pipelineID, params)
166+
events, err := fetchAllPipelineEvents(ctx, w, pipelineId, params)
167167
if err != nil {
168168
return err
169169
}
170170

171171
if latestUpdate.State == pipelines.UpdateInfoStateCompleted {
172-
err = displayPipelineUpdate(ctx, latestUpdate, pipelineID, events)
172+
err = displayPipelineUpdate(ctx, latestUpdate, pipelineId, events)
173173
if err != nil {
174174
return err
175175
}
@@ -197,9 +197,9 @@ func getLastEventTime(events []pipelines.PipelineEvent) string {
197197
return parsedTime.Format("2006-01-02T15:04:05Z")
198198
}
199199

200-
func displayPipelineUpdate(ctx context.Context, update pipelines.UpdateInfo, pipelineID string, events []pipelines.PipelineEvent) error {
200+
func displayPipelineUpdate(ctx context.Context, update pipelines.UpdateInfo, pipelineId string, events []pipelines.PipelineEvent) error {
201201
data := PipelineUpdateData{
202-
PipelineId: pipelineID,
202+
PipelineId: pipelineId,
203203
Update: update,
204204
LastEventTime: getLastEventTime(events),
205205
}

0 commit comments

Comments
 (0)