Skip to content
This repository has been archived by the owner on Oct 9, 2023. It is now read-only.

Make list execution transformer configurable #555

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

pradithya
Copy link
Member

@pradithya pradithya commented May 4, 2023

TL;DR

Add configuration in flyte admin to control the behavior of the list execution transformer with regard to error message trimming.

Type

  • Bug Fix
  • Feature
  • Plugin

Are all requirements met?

  • Code completed

Complete description

A hardcoded value of trimmedErrMessageLen is used to limit the error message shown in the workflow execution list. The current value is too small that the error message in the list execution page is not informative. Users must go to the corresponding execution details to get the entire error message even for a short error message.
This PR add configuration in flyte admin to control whether the error message truncation is enabled and the maximum message length when truncation is enabled. The default is to truncate error messages for list execution API with a maximum error message length of 10240 so that most error messages can be shown properly.

Screen.Recording.2023-05-04.at.4.15.39.PM.mov

Follow-up issue

NA

Signed-off-by: Pradithya Aria <[email protected]>
@pradithya pradithya force-pushed the increase_error_msg_length branch from 08bac41 to 93c4007 Compare May 4, 2023 08:21
@codecov
Copy link

codecov bot commented May 4, 2023

Codecov Report

Merging #555 (59f783e) into master (1026231) will increase coverage by 1.65%.
The diff coverage is 74.54%.

❗ Current head 59f783e differs from pull request most recent head 3adb19b. Consider uploading reports for the commit 3adb19b to get more accurate results

@@            Coverage Diff             @@
##           master     #555      +/-   ##
==========================================
+ Coverage   58.85%   60.51%   +1.65%     
==========================================
  Files         170      172       +2     
  Lines       16068    13309    -2759     
==========================================
- Hits         9457     8054    -1403     
+ Misses       5777     4409    -1368     
- Partials      834      846      +12     
Flag Coverage Δ
unittests ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pkg/runtime/application_config_provider.go 33.33% <ø> (ø)
pkg/common/artifacttype_enumer.go 40.00% <40.00%> (ø)
dataproxy/service.go 57.71% <63.09%> (+4.84%) ⬆️
pkg/common/flyte_url.go 96.00% <96.00%> (ø)
pkg/manager/impl/execution_manager.go 72.66% <100.00%> (+2.66%) ⬆️
pkg/manager/impl/node_execution_manager.go 72.92% <100.00%> (+2.92%) ⬆️
pkg/manager/impl/task_execution_manager.go 72.39% <100.00%> (+3.10%) ⬆️
pkg/repositories/transformers/execution.go 82.68% <100.00%> (+2.75%) ⬆️
pkg/repositories/transformers/node_execution.go 75.20% <100.00%> (+2.65%) ⬆️
pkg/repositories/transformers/task_execution.go 76.03% <100.00%> (+2.24%) ⬆️

... and 149 files with indirect coverage changes

Copy link
Contributor

@pmahindrakar-oss pmahindrakar-oss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The message length limitation was added as part of this PR #523 due to some ListExecution API's reaching the max grpc message limit.
Max grpc limit size is 4MB, with that size even considering just this lenght of the error message , the List Api can return around 400 executions in the listApi but given that per page limit is 100 this should still be ok. More preferable IMO but would be separate trimmedErrMessageLen for list API calls

Copy link
Contributor

@wild-endeavor wild-endeavor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

on second thought @pradithya - can you make this configurable? your new value as the default is fine, but it would be nice to be configurable.

@pradithya
Copy link
Member Author

on second thought @pradithya - can you make this configurable? your new value as the default is fine, but it would be nice to be configurable.

Make sense, let me have a look.

Signed-off-by: Pradithya Aria Pura <[email protected]>
@pradithya pradithya changed the title Increase trimmedErrMessageLen Make list execution transformer configurable May 6, 2023
@pradithya
Copy link
Member Author

@wild-endeavor I updated the PR to make it configurable. But it seems the CI is failing due to Github action rate limit. Can you help retry it?

Copy link
Member

@pingsutw pingsutw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pradithya Thanks, LGTM. Could you resolve branch conflict?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants