refactored single query functions in mysql
refactored mysql transaction functions
added basic retry logic
Merge pull request #588 from dannycoates/lessql

refactor mysql.js