Hi Bert!

Are you sure you have understood the difference between service orientation
and resource orientation? The background chapter in our paper I referred to
earlier briefly touches upon what a resource is, Fielding's dissertation
explains it in detail.

Why do you see the status 404 as an evil error status but 200 as some
totally other kind of status? Both are normal status codes telling
different things. If you consider 404 being an error or just a plain "there
is no such resource/patient-id"-message depends on context and your
perspective and what you expected to find at that uri. If you are sending
an invalid call to the resource/service you'll most likely get another
status code than 404. 404 often indicates that you sent a proper valid
request to a fully functional server server but asked for something that is
not there.

http://example.org/registry-x/id/123456 is a pointer to a specific
resource, either it exists or not. 404 says it does not. In the
implementation you describe it seems like patient IDs are modelled as
resources.

Most (good) REST designs will let you get information about usage and
status/availability of the containing resource (probably a or registry
id-query resource/"service" in your case) by chopping of the last piece of
the URL, for example http://example.org/registry-x/ or
http://example.org/registry-x/id/ if that is what you want to know the
status/availability of.

Best regards,
Erik Sundvall
Ph.D. Medical Informatics. Information Architect. Tel: +46-72-524 54 55 (or
010-1036252 in Sweden)
Region ?sterg?tland: erik.sundvall at regionostergotland.se (previously lio.se)
http://www.regionostergotland.se/cmit/
Link?ping University: erik.sundvall at liu.se, http://www.imt.liu.se/~erisu/

On Sun, Jan 18, 2015 at 11:21 AM, Bert Verhees <bert.verhees at rosa.nl> wrote:

>
>  https://developers.google.com/drive/web/handle-errors
>>
>>
> This is exactly my point, 404 is for handling errors, someone not being in
> a hospital-register is not an error. To check if someone is, and he isn't,
> that is not necessarily an error.
> It may even be a good thing, that someone never has been ill in a specific
> hospital.
> The only thing that a computer, without value judgment can say, is that
> the call iss successful (HTTP-status 200), and the answer is "No, he is not
> in the register". That is information.
>
> To call an non-existing service, that is an error, and should return 404.
> That is what Restlet also has implemented.
>
> Bert
>
>
> _______________________________________________
> openEHR-technical mailing list
> openEHR-technical at lists.openehr.org
> http://lists.openehr.org/mailman/listinfo/openehr-
> technical_lists.openehr.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<http://lists.openehr.org/pipermail/openehr-technical_lists.openehr.org/attachments/20150118/ef185396/attachment-0001.html>

Reply via email to