dispose method
Closes the Redis connection and cleans up resources.
Call this method when the cache driver is no longer needed to prevent resource leaks and ensure proper connection cleanup.
Implementation
Future<void> dispose() async {
if (_command != null) {
try {
await _command!.get_connection().close();
} catch (e) {
// Ignore errors during cleanup
}
_command = null;
}
}