I currently have 2 pieces of middleware RequestLoggingMiddleware and ResponseLoggingMiddleware.
Could you combine these into a single piece of middleware that does exactly the same job on the request logging and response logging.
One additional requirement, if the response going back to the caller is not a 2xx status code can the request and the response be logged out at warning level overriding the passed in config log level.
If possible can some unit tests be built for this as well?
I currently have 2 pieces of middleware RequestLoggingMiddleware and ResponseLoggingMiddleware.
Could you combine these into a single piece of middleware that does exactly the same job on the request logging and response logging.
One additional requirement, if the response going back to the caller is not a 2xx status code can the request and the response be logged out at warning level overriding the passed in config log level.
If possible can some unit tests be built for this as well?