mysql prepared statements cleaned up and mysql connections disconnected when RW shutdowns