Better Rails 4 support

This is similar to how connection_specification.rb was fixed in f455443
Merge pull request #14 from bquorning/more-rails-4-support

More Rails 4 support
Rails 4.1 compatibility
Pass symbols to .establish_connection

Passing a String for a configuration lookup is deprecated in Rails 4.1
Fix deprecations and remove Rails 2 code
HasAndBelongsToMany is gone from Rails 4.1
tmp