spark icon indicating copy to clipboard operation
spark copied to clipboard

$everything is not implemented

Open whyfate opened this issue 5 years ago • 1 comments

I think that's the same reason as #236

whyfate avatar Jun 24 '20 03:06 whyfate

It's actually much worse than not implemented.

Background: using the provided docker images (sparkfhir/spark:r4-latest)

{
  "resourceType": "CapabilityStatement",
  "version": "1.5",
  "name": "Spark",
  "experimental": true,
  "date": "2021-01-20",
  "publisher": "Kufu",
  "description": "This FHIR SERVER is a reference Implementation server built in C# on HL7.Fhir.Core (nuget) by Furore and others",
  "kind": "capability",
  "fhirVersion": "4.0.0",
  "format": [
    "xml",
    "json"
  ]
...
}

The capability statement does include the $everything operation. If it's not supported, it should not be there:

        {
          "name": "Fetch Patient Record",
          "definition": "http://localhost:5555/fhir/OperationDefinition/Patient-everything"
        }

The result of $everything operation is incorrect in few aspects. When calling curl http://localhost:5555/fhir/Patient/ID/\$everything:

  • It doesn't matter if Patient with ID exists
  • The returned results include Patients which ids start with the regular expression ^ID
  • The ID is not escaped for regular expression and therefore curl http://localhost:5555/fhir/Patient/./\$everything returns all the patients
  • The result has no other resources besides unrelated patients

ilyash-b avatar Jan 20 '21 15:01 ilyash-b