fixes(redis): shutdown and metrics fix

- Don't shutdown the connection until we have sent and gathered the metrics
- trim the newlines out of the key and value