Pass error and stack trace for request failure log (#3149)
Pass error and stack trace for request failure log (#3149)

Correct the `_logger.severe` call to pass the error (instead of a
hardcode `true`) and stack trace to the log record instead of manually
formatting a full message.

Refactor the logging middleware to async/await for better readability,
and to allow using `rethrow` which does not need an ignore for only
throwing subtypes of Error or Exception.

Rename `_getMessage` to `_requestLabel` to be more descriptive about the
message it creates.
dart-lang/build,dart-lang/build,dart-lang/build,dart-lang/build