SQOOP-1733: Port SQOOP-1728 to sqoop2 branch

(Abraham Elmahrek via Jarek Jarcec Cecho)
SQOOP-1741: Port SQOOP-1736 to sqoop2 branch

(Abraham Elmahrek via Jarek Jarcec Cecho)