Add logging of failures and denials messages for CI jobs
This change will make some needed debugging data available to SRE via logs. This is fairly urgent as it can have an impact on availability. It is a follow-up from "Implement external validation during pipeline creation", where the following discussion from !21134 (merged) should be addressed:
-
@ayufan started a discussion: (+3 comments)
I just wonder, if we should log all validations results @matteeyah. WDYT?
Maybe this is something not really required? Will this be a problem for the production team to debug when something will not work? Will Sentry/exceptions log be enough?
-
It depends on what is being debugged - if it's the validation mechanism itself (e.g. we expect a pipeline to pass validation but it doesn't) then this is related to debugging the external service. This should be logged in the external service and debugged there.
It's highly unlikely that the external service validates properly but we don't parse the response properly since we don't really do anything other than read the response code. If there's a configuration error, the URL doesn't exist or its timing out, this will be caught and logged in Sentry.
Either way we could add additional logging later on if we decide what we have here isn't enough.