Skip to content
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

ValueSets not expanded in queries to EHR #676

Open
aeyates opened this issue Nov 30, 2022 · 1 comment
Open

ValueSets not expanded in queries to EHR #676

aeyates opened this issue Nov 30, 2022 · 1 comment

Comments

@aeyates
Copy link

aeyates commented Nov 30, 2022

I'm attempting to upgrade from 0.5.0 and am finding that queries to the EHR no longer expand the valueset. Is there some change in configuration I am missing? I've attached a test case to highlight the issue. When I execute the plan definition in 0.5.0, I see in the logs the request being made to the EHR FHIR server:

coach-cqfruler-1 | 2022-11-30 18:41:26.448 [http-nio-8080-exec-5] INFO c.u.f.r.c.i.LoggingInterceptor [LoggingInterceptor.java:82] Client request: GET https://api.logicahealth.org/htnu18r42/open/Observation?code=http%3A%2F%2Floinc.org%7C8480-6%2Chttp%3A%2F%2Fsnomed.info%2Fsct%7C271649006%2Chttp%3A%2F%2Fsnomed.info%2Fsct%7C399304008&subject=Patient%2FP-AdvancingTreatment HTTP/1.1

Here, it has expanded the valueset 2.16.840.1.113762.1.4.1104.2 into the codes that comprise it.

If I execute the same plan definition in 0.5.1, I get the following error:

coach-cqfruler-1 | 2022-11-29 22:00:43.448 [http-nio-8080-exec-6] ERROR o.o.c.r.cdshooks.r4.CdsHooksServlet [CdsHooksServlet.java:193] org.opencds.cqf.cql.engine.exception.CqlException: ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException: HTTP 404 Not Found: Unknown ValueSet: http%3A%2F%2Fcts.nlm.nih.gov%2Ffhir%2FValueSet%2F2.16.840.1.113762.1.4.1104.2

The log does not indicate what query is being made to the EHR, but if I disconnect from the internet so that the EHR can't be reached, it becomes clear that the query is not expanding the valueset:

ERROR: Exception in CQL Execution. ca.uhn.fhir.rest.client.exceptions.FhirClientConnectionException: Failed to parse response from server when performing GET to URL https://api.logicahealth.org/htnu18r42/open/Observation?code%3Ain=http%3A%2F%2Fcts.nlm.nih.gov%2Ffhir%2FValueSet%2F2.16.840.1.113762.1.4.1104.2&subject=Patient%2FP-AdvancingTreatment - java.net.UnknownHostException: api.logicahealth.org: Name or service not known

Since the EHR FHIR server doesn't contain this value set, the execution of the plan definition fails.

The attached zip file contains the cql, plan definition, valueset, and a json file containing the POST body used in execution of the plan definition.

@aeyates
Copy link
Author

aeyates commented Nov 30, 2022

test-case.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant