Hacker News new | past | comments | ask | show | jobs | submit login

http://tools.ietf.org/html/rfc5789

HTTP PUT is for in place entire entity updates. HTTP PATCH is for partial updates.

This isn't some opinion these guys came up with. It's HTTP standards.

Also if you don't like what save does. Write your own Backbone.sync and be done with it. Still super flexible.




Fair enough, I agree with the spec here, but we know that in the wild many companies don't conform to HTTP.


For what it's worth... "PATCH is going to be the primary method for updates in Rails 4.0." http://weblog.rubyonrails.org/2012/2/25/edge-rails-patch-is-...

That's not intended to be a counterpoint. In the wild, many companies don't use Rails. :)


It doesn't matter what Rails decides to do if your HTTP server doesn't support it.

With that said, it looks like many do already support it (from the same article you linked): Apache, nginx, Phusion Passenger, Unicorn, Thin, and WEBrick.


Also, Rails supports an override as well, so you can send it as a POST but specify a different verb in a header, and it will treat it as a native request with the correct verb.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: