Clean up stack trace with Workflow Exceptions
Stack traces are important to track errors through layers of code. But in the case of workflows, the groovy logic is usually a very thin layer (just the script, maaaaybe a few functions). Therefore, it’d be much nicer to have only a line or two in the logs when an exception is thrown (and optionally a meaningful message in the UI pop-up).
Have anyone managed to override the WorkflowExceptionHandler class in a meaningful way, or would it be a good proposition that the workflow engine treats workflow exceptions with more delicacy than dumping a 250 lines stack trace for an undeclared variable?
arthurburkhardt
Posted 5 years ago · Edited 1 year ago·Last reply 5 years ago
2 comments
pmahend3
·5 years ago · EditedHi Arthur,
This is certainly a cause and recommendation that all Collibra workflow developers can get behind. I would assume that this would take a decent effort though given the logging is a native capability of the engine. Also, I can picture a few scenarios where a popup may not be feasible. I’ll try to have our engineers weigh in on this and see what they think. Also, thanks for the great value you bring to this community.
Cheers
arthurburkhardt
OP5 years ago · EditedOh the relief! I found a pretty nice way to work around the problem.
All lines of the stacktrace have a specific
log-line--indentedclass.So I wrote a simple tampermonkey userscript to change the CSS of the page to not display all the indented log lines. And boom! clean logs, no more 200 useless lines of stack trace.
Because it changes the CSS:
Before (200 lines)
After (14 lines = 93% reduction)