For example:
let client1 = new Client(); // it can do client1.connect() and other methods
await redis.hset('client1', JSON.stringify(client1));
client1 = await redis.get('client1');
client1 = JSON.parse(client1);
await client1.connect();
Is it safe that if you were ever to get the value back and JSON.parse() it, that it would still work properly?