should close the connection before exit.
Revert "should close the connection before exit."

This reverts commit e81470b2755a84c1040995732a8ddaab32b42d57.
should close the connection before exit.