In EWS, when build fails, we provide a filtered log for errors. In that log, apart from filtering lines containign the word Error, we also include few lines before that to provide additional context. However, sometimes, those additional context line might be pretty large (almost the whole log). For e.g.: in https://ews-build.webkit.org/#/builders/36/builds/42029 overall stdio logs were 9171 lines, while filtered error log was 9150 lines (almost same length as complete logs). This defeats the purpose of filtering. Also adding large number of lines in the filtered error logs slow down the build (e.g.: in https://ews-build.webkit.org/#/builders/36/builds/42029 in step 15 the actual script took ~3 minutes (183 seconds), while the step took ~5 minutes). I have noticed few times that after the step is finished, adding logs in error view takes long time when there are large amount of lines being added to errors log. We should limit the number of additional lines we add in errors log.
Created attachment 435134 [details] Patch
Tested on uat instance. With this patch: https://ews-build.webkit-uat.org/#/builders/35/builds/105397 (see errors log in step 11) Without this patch: https://ews-build.webkit-uat.org/#/builders/35/builds/105398 (see errors log in step 11)
<rdar://problem/81657334>
Committed r280763 (240348@main): <https://commits.webkit.org/240348@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 435134 [details].
Restarted buildbot to pick up this fix