Review Board 1.7.22


SQOOP-979 MySQL direct connector is not working correct after moving password to credential cache

Review Request #10322 - Created April 5, 2013 and submitted

Jarek Cecho
SQOOP-979
Reviewers
Sqoop
sqoop-trunk
I've changed the code to use DBConfiguration object to retrieve the password instead of directly using the old properties. I've also done two questionable changes that I would like to highlight:

1) I've removed MySQLUtils.PASSWORD_KEY. This is internal property of MySQL direct connector and should not be used in any dependent code. I would argue that by deleting it, any affected third party code will fail very quickly rather than causing random exceptions later as the property will be always empty.

2) I've change method DBConfiguration.getPassword() to public. I would argue that this method can be called only by Sqoop and connectors do have valid need to get the password so that it can be passed to third party applications like mysqldump.
Failing MySQLAuthTest and DirectMySQLExportTest test cases seems to be working after applying the patch.
Review request changed
Updated (July 22, 2013, 6:42 p.m.)
  • changed from pending to submitted