SoC and HTTP REST

2008-04-22 @ 16:01#

while not an actual pillar of HTTP REST, SoC is one of the possible benefits of a REST-ful implementation for Web applications. if you implement your Web app using unconstrained URI, constrained content-types and constrained methods you will find it much easier to implement solutions that keep a clear SoC.

that's because the server is focused on returning representations to the client in the requested format and the client is focused on rendering and interacting with those representations. also, when the methods are constrained to GET, HEAD, POST, PUT, DELETE, OPTION it's much more likely that both client and server understand the meaning and implication of the actions. finally, when you implement a server that decouples representation formats (Atom, XML, JSON, XHTML) from the resource, you're much more likely to focus on a consistency across formats and that improve the clarity of the SoC 'line' between client and server.

code