Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass CustomInfo metadata through ArrayNode ExternalResourceInfo (#591) #6116

Merged
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions flytepropeller/pkg/controller/nodes/array/event_recorder.go
Original file line number Diff line number Diff line change
Expand Up @@ -136,14 +136,21 @@
log.Name = fmt.Sprintf("%s-%d", log.GetName(), index)
}

e.externalResources = append(e.externalResources, &event.ExternalResourceInfo{
externalResourceInfo := event.ExternalResourceInfo{
ExternalId: externalResourceID,
Index: uint32(index), // #nosec G115
Logs: taskExecutionEvent.GetLogs(),
RetryAttempt: retryAttempt,
Phase: taskExecutionEvent.GetPhase(),
CacheStatus: cacheStatus,
})
CustomInfo: taskExecutionEvent.CustomInfo,
}

if taskExecutionEvent.GetMetadata() != nil && len(taskExecutionEvent.GetMetadata().ExternalResources) == 1 {
externalResourceInfo.CustomInfo = taskExecutionEvent.GetMetadata().ExternalResources[0].CustomInfo
}

Check warning on line 151 in flytepropeller/pkg/controller/nodes/array/event_recorder.go

View check run for this annotation

Codecov / codecov/patch

flytepropeller/pkg/controller/nodes/array/event_recorder.go#L150-L151

Added lines #L150 - L151 were not covered by tests

e.externalResources = append(e.externalResources, &externalResourceInfo)
}

// clear nodeEvents and taskEvents
Expand Down
Loading