Bug #98438 Can we have a shortcut for reconnecting the shell?
Submitted: 30 Jan 2020 9:00 Modified: 12 Feb 2020 18:28
Reporter: IGG t Email Updates:
Status: Won't fix Impact on me:
None 
Category:Shell General / Core Client Severity:S4 (Feature request)
Version:8.0.19 OS:Any
Assigned to: CPU Architecture:Any
Tags: reconnect, shell, shortcuts

[30 Jan 2020 9:00] IGG t
Description:
At the moment when MySQL Shell disconnects due to lack of activity you have to reconnect the session by typing "\reconnect"

Would it be possible to add a shortcut option to do this such as "\r", in the same way that "\connect" has a shortcut of "\c".

It's a small change, but feel it would save a lot of time.

How to repeat:
connect to a shell session:

\c user@1.2.3.4:3306

wait for it to timeout:

MySQL  1.2.3.4:3306 ssl  JS > cluster.status()
Cluster.status: Lost connection to MySQL server during query (RuntimeError)

You now need to reconnect your session by typing:

\reconnect

Suggested fix:
Include a shortcut for the "\reconnect" option, maybe simply "\r"
[31 Jan 2020 6:37] MySQL Verification Team
Hello!

Thank you for the feature request.

Thanks,
Umesh
[12 Feb 2020 18:28] Miguel Araujo
Posted by developer:
 
This enhancement request is actually a bug fix that has already been reported: BUG#30884646.

In other words, the cluster objects will use the session to the primary member and reconnect automatically and transparently whenever necessary. 
The user will not have to manually reconnect the sessions and obtain new cluster object handlers.

That behavior is already seen in the ReplicaSet objects.