Closed stapelberg closed 12 years ago
Sounds like a good idea. Thanks! I'm going to try this out a little bit first before merging.
Actually, this is noticeably faster. If you fix the above (minor) issues I will merge. Thanks!
Updated the code and commented on your comments. Can you have a look again please?
Updated again. Can you have a look again, please?
There is much copy-paste with the @curl
object parameterization and its error management, which should be managed by handle_errors
In fact I really liked the previous syntax :
helper[path].get
helper[path].get :params => params
helpert[path].post :params => params
which could be refactored into something like
get_binary path, :params => params
to look like the other one-liners
@rakoo: I would prefer a cleaner syntax too. I've merged it in. Additional cleanup commits are welcome. :)
Curl supports persistent HTTP connection and thus speeds up the communication with Heliotrope. This is especially noticable on slow links.