Action results may contain sensible data that should not be logged. There is a system configuration flag (writeResultToFile) that can be used to switch on or off the result inclusion in logs. But this is a global switch that holds for all activations. In our case we want to able to decide per activation whether or not the result should be included in the log or not. In our special case we want results to be included in case of errors (in other words, our predicate function for the decision is: 'Does the result contain an error field?'). But also other decision logic may be applicable.
This PR https://github.com/apache/openwhisk/pull/4604 is a small change that extends ActivationFileStorage. Please help and comment on the PR. Thank you, Ruediger