Jruby compatibility

Switched from "curb" to "rest_client" in order to make it compatible with JRuby.