Stream: implementers
Topic: Compartments
René Spronk (Apr 13 2016 at 14:09):
I'm trying to find out the concept behind the 'compartment' idea. I'm aware that it has something to do with access control. The compartment documentation in the continuous build is missing, e.g. http://hl7-fhir.github.io/compartments.html. So what's the main idea behind assigning Resource types to compartments?
John Moehrke (Apr 13 2016 at 14:28):
Compartments are not an access control concept. They are an API friendlyness concept. From an Access Control perspective one must consider the use of a compartment simply as a deterministic use of a query parameter. The API friendliness concept is that it is far more logical to be navigating a branch, than conceptually to be continuously adding deterministic query parameters. The result 'looks' more clean. as David explains on his blog https://fhirblog.com/tag/compartment/ it is syntactic sugar.
John Moehrke (Apr 13 2016 at 14:31):
That said.. there is an Access Control methodology that uses the same English word "compartment"; and this does show up in the security_labels, and is the focal point of Attribute Based Access Control (ABAC). And there is a bit of overlap as ABAC can be implemented using RESTful compartments. However that is not the main focal point of compartment based access control.
Lloyd McKenzie (Apr 13 2016 at 15:21):
Compartments are used as part of the $everything process. They can also be relevant for access control - some systems may use membership of a resource in a particular patient's, practitioner's and/or organization's compartment as part of their enforcement of access control rules - but FHIR definitely doesn't say you must/should do this.
Grahame Grieve (Apr 13 2016 at 20:16):
the correct reference is http://hl7-fhir.github.io/compartmentdefinition.html - did you find a pointer pointing to the old page anywhere?
Vadim Peretokin (Apr 17 2016 at 19:48):
Every page's header "Compartments: Not linked to any defined compartments" has the wrong link
Vadim Peretokin (Apr 17 2016 at 19:48):
Are there any servers that implement compartments? Checked a few popular ones and none seem to declare it in their conformance
Lloyd McKenzie (Apr 17 2016 at 22:57):
Vadim, can you submit a change request?
Grahame Grieve (Apr 17 2016 at 22:58):
he did! Seems some message were lost...
Vadim Peretokin (Apr 17 2016 at 23:23):
Yeah it's in the bug? topic. I wrote in one of the topics before finding another one that was also discussing the same thing
Vadim Peretokin (Jul 11 2016 at 04:28):
Confused about compartments. Have they been deleted?
Vadim Peretokin (Jul 11 2016 at 04:29):
Nevermind, still there - https://hl7-fhir.github.io/compartmentdefinition.html#use
Kenneth Chapple (Aug 17 2016 at 21:06):
Greetings, I am trying to find a test server that implements Patient compartment for Appointment. I tried http://spark.furore.com and http://fhirtest.uhn.ca/baseDstu2/ endpoints, but I get errors when I try a URL like [base]/Patient/{id}/Appointment. Am I formatting my URL incorrectly, or are compartments not fully implemented? I am researching because I am implementing a server-side booking system and would like to get a list of patient appointments, and it seemed that compartments were the best fit for my needs. Thanks,
Kenneth Chapple (Aug 17 2016 at 21:06):
Ken
Kenneth Chapple (Aug 17 2016 at 21:06):
For example:
http://fhirtest.uhn.ca/baseDstu2/Patient/107195/Appointment
http://spark.furore.com/fhir/Patient/spark3/Appointment
Grahame Grieve (Aug 17 2016 at 22:08):
my server supports compartments. But note that compartments are really just a syntax trick.
Grahame Grieve (Aug 17 2016 at 22:09):
http://fhirtest.uhn.ca/baseDstu2/Appointment?subject=107195
Grahame Grieve (Aug 17 2016 at 22:09):
same thing
Kenneth Chapple (Aug 17 2016 at 23:07):
Gotcha! Thanks!
Saraswathi Ramachandran (May 25 2017 at 11:18):
Hello All!!
Are compartment type URLs to be use only for GET? Or can we use compartment URLs for POST and PUT? FHIR documentation doesn't say anything on this, however the examples mentioned are using only GET.
Grahame Grieve (May 26 2017 at 21:16):
I'm not sure what the point of this would be?
Ken Sinn (Oct 01 2018 at 19:56):
Hi Graham,
Following up on Sarawathi's question, I noticed the 2018Sep version of the spec notes that the POST [base]/Patient/[patient-id]/Condition "is not defined by this specification". If a server enabled this "operation", would the server still be considered FHIR-conformant, since FHIR makes no claims on this operation?
Grahame Grieve (Oct 01 2018 at 22:24):
it's ok to add additional interactions, yes.
Last updated: Apr 12 2022 at 19:14 UTC