HUE-2043 [core] database options keys have unicode keys

Moved the dictionary logic from librdbms to python_util.