On my Mac (10.12.6 (16G29)), if I leave DataGrip idle for more than a few minutes, DataGrip disconnects from my Redshift cluster... or more precisely, DataGrip frequently thinks its connected when it is not and only lets you know when trying to run a query you recieve an error... it doesn't seem able to figure out how to reconnect and I have to close DataGrip and reopen the program to reconnect.
This is mildly frustrating... however the real block has now come from long running copy processes... I run a copy command that takes a couple hours. Datagrip appears to sustain an active connection... but just as the copy reaches 100% in the Amazon Interface, it drops the connection (maybe it thinks its successful) but apparently leaves Redshift hanging... so Redshift panics and unloads all the data it spent 2hrs sending to the cluster.
The comment from Redshift Support was:
I got the reply the internal team, they were suspecting the problem
to be with the client from which you were running the COPY command,
the client might have got disconnected from the redshift without
COMMITing the COPY command.
What client you were using to run the COPY command?
Make sure that you have enabled the "autocommit" to "on",
so that the COPY command commit all the changes to the tables.
In the DataGrip UI, yes, Tx: is set to "Auto"... unless it should be something else?
Hopefully the solution fixes both of my problems that are apparently rooted in premature disconnects.