SpringSource/spring-data-services — comment on commit bfd5449375148d0e1f05021eed954d3475c5b1e3
File:  line 0
By markpollack:

As this is for Spring Data Repositories, why the reference to 'service', in particular in the usage {"link": {"rel": "service",...

Shouldn't this be prefaced by saying, assume PersonRepository, AccountRepository Spring Data Repositories exist. Then a request without an accept header to the root will return

HTTP/1.1 200 OK
Date: ...
Server: Spring Data Services Web Exporter/1.0.0.BUILD-SNAPSHOT

http://localhost:8080/baseurl/person
http://localhost:8080/baseurl/account

and with an Accept Header something other than "rel:" "service" would be used...

At a high level i think the mapping looks good but we need to drill in on details. The discussions I remember floating around were

1. A get on /baseurl/person/1 would return the non-collection elements marshalled into JSON but any relationships would be represented as links in the body (not header - also not a fan of putting it in the header). Basically a discussion on what our 'default' representation should be with the assumption that the primary consumer of the representation is the browser via a javascript library like jquery.

2. A put on /baseurl/person/1 would not allow only the update of the entity corresponding to the ID=1. If the JSON body had ID=2 that would be an error and the update would fail.

Jon, can you add a separate section for action under /baseurl/domain/id. for example, what are required formats, what error codes can be returned for each request.