-
Notifications
You must be signed in to change notification settings - Fork 157
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Scope whole-system interactions to the intersection of R4 and R4B by default #3242
Comments
This could easily be implemented in the same spot we set the default Accept header to |
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
This changeset adds a JAX-RS RequestFilter that sets a requestContext property, "com.ibm.fhir.server.fhirVersion" with the following order of precedence: 1. "4.3" from the acceptableMediaTypes 2. "4.0" from the acceptableMediaTypes 3. whatever is configured in the fhirServer/core/defaultFhirVersion config property 4. "4.0" Additionally, I updated the Capabilities resource to use the fhirVersion from the request context instead of processing the Accept header itself. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. introduce enums and utilities for working with resource type names and fhirVersion values ('4.0' and '4.3') 2. use those to provide a better abstraction for working with the fhir-server-config `fhirServer/resources` property group (ResourcesConfigAdapter) 3. move fhirVersion MIME-type parameter processing into a new JAX-RS RequestFilter FHIRVersionRequestFilter and update tests accordingly 4. update FHIRPersistenceUtil.parseSystemHistoryParameters to take into account the requested fhirVersion and scope the HistoryContext appropriately 5. update SearchUtil.parseQueryParameters to take into account the requested fhirVersion and scope the SearchContext appropriately Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
1. add the FHIRVersionParam to the OperationContext 2. use that with a ResourcesConfigAdapter to get the list of applicable resource types in EverythingOperation.getDefaultIncludedResourceTypes Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
mostly javadoc updates and a couple minor refactorings Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Previously I was only looking in the Accept header. Now, for PUT and POST requests, I'll check the Content-Type header first. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Acceptance criteria 6 fails it exports the same resources as Acceptance critera 3. |
In the case of export, validate any `_type` parameters against the resource types for the configured fhirVersion. If none was specified, use an appropriate list for that version. In the case of import, validate the input parameters against the supported types for the fhirVersion. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
issue #3242 - use the fhirVersion from the import/export request
AC1: history with fhirVersion=4.3:
AC2: search with fhirVersion=4.3:
AC3: export with fhirVersion=4.3
AC4: history without fhirVersion
AC5: search without fhirVersion:
AC6: export without specifying fhirVersion:
No mention of R4B resources. Summary: in all the above cases the correct set of resources are seen. |
Is your feature request related to a problem? Please describe.
Building on the support added in #3137 ...
For example, for whole-system history:
Similar scenarios exist for whole-system search and $export (and maybe $everything as well?)
Describe the solution you'd like
Introduce a fhir-server-config property that controls the server behavior when no fhirVersion is specified by the client. The default value for this property should result in the server only returning 4.0.1 resource types (but still not ones removed in 4.3.0).
Regardless of the setting, if the client passes an Accept header with a FHIR mime type that includes
fhirVersion=4.3
, and the new resource types are not filtered out in the fhir-server-configresources
section, then include the new resource types introduced in R4B.This is consistent with the CapabilityStatement behavior implemented for #3192 except that we should update that to support changing the default if the user wants something other than 4.0.1 to be the default behavior.
Describe alternatives you've considered
Force the IBM FHIR Server operator to explicitly list the set of supported resource types in their fhir-server-config and use exactly that set when the client doesn't pass any
fhirVersion
in their Accept header.If they only want to server 4.0 resource types, then only list 4.0 resource types and set
open=false
.If the client explicitly asks for
fhirVersion=4.0
we could still omit all the resource types introduced in R4B.If we went with this alternative, we'd need to update the CapabilityStatement behavior to match because, currently, that defaults to omitting the new R4B resource types (unless fhirVersion=4.3 is passed)
Acceptance Criteria
GIVEN a 5.0 IBM FHIR Server with resource type instances of types added in R4B (e.g. Ingredient)
WHEN a whole-system history query is sent with no explicit _type parameter
AND the client sets the Accept header to
application/fhir+[xml/json];fhirVersion=4.3
THEN the history response contains the R4B resource types
GIVEN a 5.0 IBM FHIR Server with resource type instances of types added in R4B (e.g. Ingredient)
WHEN a whole-system search query is sent with no explicit _type parameter
AND the client sets the Accept header to
application/fhir+[xml/json];fhirVersion=4.3
THEN the search response contains the R4B resource types
GIVEN a 5.0 IBM FHIR Server with resource type instances of types added in R4B (e.g. Ingredient)
WHEN a system-level $export interaction with no explicit _type parameter
AND the client sets the Accept header to
application/fhir+[xml/json];fhirVersion=4.3
THEN the $bulkdata-status response contains a download url for the R4B resource types
GIVEN a 5.0 IBM FHIR Server with resource type instances of types added in R4B (e.g. Ingredient)
WHEN a whole-system history query is sent with no explicit _type parameter
AND the client does NOT set the Accept header / sets it to
application/fhir+[xml/json]
THEN the history response does NOT contains the R4B resource types
GIVEN a 5.0 IBM FHIR Server with resource type instances of types added in R4B (e.g. Ingredient)
WHEN a whole-system search query is sent with no explicit _type parameter
AND the client does NOT set the Accept header / sets it to
application/fhir+[xml/json]
THEN the search response does NOT contains the R4B resource types
GIVEN a 5.0 IBM FHIR Server with resource type instances of types added in R4B (e.g. Ingredient)
WHEN a system-level $export interaction with no explicit _type parameter
AND the client does NOT set the Accept header / sets it to
application/fhir+[xml/json]
THEN the $bulkdata-status response does NOT contains a download url for the R4B resource types
Additional context
Similar to #3192 but for system interactions and not just the CapabilityStatement
The text was updated successfully, but these errors were encountered: