Restresources plugin has incorrect PUT/POST semantics

Issue #10 new
Michael Granger
repo owner created an issue

The :restresources plugin currently generates a 'PUT /resources/{id}' endpoint for "updating an instance".

According to RFC2616, the PUT method should be idempotent, but updating an instance is not an idempotent operation.

The solution is to implement the (currently unimplemented) 'POST /resources/{id}' method for updates, since POST is not idempotent, and modify the PUT endpoint to be an idempotent replace operation instead.

Comments (0)

  1. Log in to comment