Code Monkey home page Code Monkey logo

Comments (17)

jeffeastman avatar jeffeastman commented on September 26, 2024

Here's the latest catalina.out log. More output that all looks normal.

2017-11-30 18:04:02.163 [http-nio-8080-exec-3] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[Java/1.8.0_92] Params[]
2017-11-30 18:04:02.176 [http-nio-8080-exec-10] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:02.209 [http-nio-8080-exec-10] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:02.247 [http-nio-8080-exec-10] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OpioidCdsStu3 in 3ms
2017-11-30 18:04:02.324 [http-nio-8080-exec-10] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:02.329 [http-nio-8080-exec-10] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on cdc-opioid-guidance in 3ms
2017-11-30 18:04:02.362 [http-nio-8080-exec-10] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OMTKLogic in 3ms
2017-11-30 18:04:02.558 [http-nio-8080-exec-4] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[Java/1.8.0_92] Params[]
2017-11-30 18:04:02.572 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:02.607 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:02.646 [http-nio-8080-exec-1] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OpioidCdsStu3 in 2ms
2017-11-30 18:04:02.719 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:02.723 [http-nio-8080-exec-1] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on cdc-opioid-guidance in 2ms
2017-11-30 18:04:02.763 [http-nio-8080-exec-1] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OMTKLogic in 3ms
2017-11-30 18:04:03.031 [http-nio-8080-exec-9] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[Java/1.8.0_92] Params[]
2017-11-30 18:04:03.046 [http-nio-8080-exec-5] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.117 [http-nio-8080-exec-8] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[HAPI-FHIR/3.1.0-SNAPSHOT (FHIR Client; FHIR 3.0.1/DSTU3; apache)] Params[]
2017-11-30 18:04:03.141 [http-nio-8080-exec-2] INFO  c.u.f.j.s.SearchCoordinatorSvcImpl [SearchCoordinatorSvcImpl.java:333] Search initial phase completed in 1ms
2017-11-30 18:04:03.149 [search_coord_2] INFO  ca.uhn.fhir.jpa.dao.SearchBuilder [SearchBuilder.java:2196] Initial query result returned in 6ms for query 228e461f-9284-4ab4-a27a-c22e06b74210
2017-11-30 18:04:03.149 [search_coord_2] INFO  ca.uhn.fhir.jpa.dao.SearchBuilder [SearchBuilder.java:2201] Query found 0 matches in 6ms for query 228e461f-9284-4ab4-a27a-c22e06b74210
2017-11-30 18:04:03.152 [search_coord_2] INFO  c.u.f.j.s.SearchCoordinatorSvcImpl [SearchCoordinatorSvcImpl.java:478] Completed search for 0 resources in 11ms
2017-11-30 18:04:03.152 [http-nio-8080-exec-2] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[search-type MedicationRequest] UA[HAPI-FHIR/3.1.0-SNAPSHOT (FHIR Client; FHIR 3.0.1/DSTU3; apache)] Params[?patient=Patient-1121&status=active]
2017-11-30 18:04:03.157 [http-nio-8080-exec-5] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.168 [http-nio-8080-exec-5] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.196 [http-nio-8080-exec-5] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.209 [http-nio-8080-exec-5] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OpioidCdsStu3 in 1ms
2017-11-30 18:04:03.269 [http-nio-8080-exec-5] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.273 [http-nio-8080-exec-5] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on cdc-opioid-guidance in 2ms
2017-11-30 18:04:03.310 [http-nio-8080-exec-5] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OMTKLogic in 2ms
2017-11-30 18:04:03.498 [http-nio-8080-exec-7] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[Java/1.8.0_92] Params[]
2017-11-30 18:04:03.512 [http-nio-8080-exec-6] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.542 [http-nio-8080-exec-6] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.603 [http-nio-8080-exec-6] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OpioidCdsStu3 in 2ms
2017-11-30 18:04:03.664 [http-nio-8080-exec-6] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.667 [http-nio-8080-exec-6] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on cdc-opioid-guidance in 1ms
2017-11-30 18:04:03.701 [http-nio-8080-exec-6] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OMTKLogic in 3ms
2017-11-30 18:04:03.876 [http-nio-8080-exec-4] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[Java/1.8.0_92] Params[]
2017-11-30 18:04:03.887 [http-nio-8080-exec-10] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.915 [http-nio-8080-exec-10] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:03.955 [http-nio-8080-exec-10] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OpioidCdsStu3 in 2ms
2017-11-30 18:04:04.014 [http-nio-8080-exec-10] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:04.017 [http-nio-8080-exec-10] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on cdc-opioid-guidance in 1ms
2017-11-30 18:04:04.049 [http-nio-8080-exec-10] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OMTKLogic in 3ms
2017-11-30 18:04:04.224 [http-nio-8080-exec-9] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[Java/1.8.0_92] Params[]
2017-11-30 18:04:04.235 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:04.294 [http-nio-8080-exec-8] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[metadata ] UA[HAPI-FHIR/3.1.0-SNAPSHOT (FHIR Client; FHIR 3.0.1/DSTU3; apache)] Params[]
2017-11-30 18:04:04.314 [http-nio-8080-exec-2] INFO  c.u.f.j.s.SearchCoordinatorSvcImpl [SearchCoordinatorSvcImpl.java:283] Reusing search 228e461f-9284-4ab4-a27a-c22e06b74210 from cache
2017-11-30 18:04:04.316 [http-nio-8080-exec-2] INFO  logging.accesslog [LoggingInterceptor.java:170] Source[127.0.0.1] Operation[search-type MedicationRequest] UA[HAPI-FHIR/3.1.0-SNAPSHOT (FHIR Client; FHIR 3.0.1/DSTU3; apache)] Params[?patient=Patient-1121&status=active]
2017-11-30 18:04:04.320 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:04.329 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:04.359 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:04.371 [http-nio-8080-exec-1] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OpioidCdsStu3 in 1ms
2017-11-30 18:04:04.426 [http-nio-8080-exec-1] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:162] Creating new FHIR context for FHIR version [DSTU3]
2017-11-30 18:04:04.430 [http-nio-8080-exec-1] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on cdc-opioid-guidance in 2ms
2017-11-30 18:04:04.469 [http-nio-8080-exec-1] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OMTKLogic in 3ms

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

Tomcat upgrade to 8.5 didn't solve this one

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

Latest cqf-ruler build still throws e500 on all hooks requests. Any progress on this?

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

Finally figured out how to get a stack dump while debugging this on Tomcat:

2018-01-20 15:15:35.220 [http-nio-8080-exec-1] INFO  c.u.f.j.dao.BaseHapiFhirResourceDao [BaseHapiFhirResourceDao.java:782] Processed read on OMTKLogic in 2ms
java.lang.RuntimeException: No suitable driver found for jdbc:sqlite:///Users/jeff/apache-tomcat-8.5.24/bin/src/main/resources/cds/OpioidManagementTerminologyKnowledge.db
	at org.opencds.cqf.opioidcds.OmtkDataProvider.getNewConnection(OmtkDataProvider.java:52)
	at org.opencds.cqf.opioidcds.OmtkDataProvider.getConnection(OmtkDataProvider.java:31)
	at org.opencds.cqf.opioidcds.OmtkDataProvider.retrieve(OmtkDataProvider.java:63)
	at org.opencds.cqf.cql.elm.execution.RetrieveEvaluator.evaluate(RetrieveEvaluator.java:52)
	at org.opencds.cqf.cql.elm.execution.SingletonFromEvaluator.evaluate(SingletonFromEvaluator.java:41)
	at org.opencds.cqf.cql.elm.execution.PropertyEvaluator.evaluate(PropertyEvaluator.java:16)
	at org.opencds.cqf.cql.elm.execution.FunctionRefEvaluator.evaluate(FunctionRefEvaluator.java:30)
	at org.opencds.cqf.cql.elm.execution.QueryLetRefEvaluator.evaluate(QueryLetRefEvaluator.java:12)
	at org.opencds.cqf.cql.elm.execution.ConcatenateEvaluator.evaluate(ConcatenateEvaluator.java:31)
	at org.opencds.cqf.cql.elm.execution.ConcatenateEvaluator.evaluate(ConcatenateEvaluator.java:31)
	at org.opencds.cqf.cql.elm.execution.IfEvaluator.evaluate(IfEvaluator.java:18)
	at org.opencds.cqf.cql.elm.execution.TupleEvaluator.evaluate(TupleEvaluator.java:15)
	at org.opencds.cqf.cql.elm.execution.QueryEvaluator.resolveResult(QueryEvaluator.java:73)
	at org.opencds.cqf.cql.elm.execution.QueryEvaluator.evaluate(QueryEvaluator.java:239)
	at org.opencds.cqf.cql.elm.execution.ExpressionDefEvaluator.evaluate(ExpressionDefEvaluator.java:20)
	at org.opencds.cqf.cql.elm.execution.ExpressionRefEvaluator.evaluate(ExpressionRefEvaluator.java:14)
	at org.opencds.cqf.cql.elm.execution.QueryEvaluator.evaluate(QueryEvaluator.java:226)
	at org.opencds.cqf.cql.elm.execution.ExpressionDefEvaluator.evaluate(ExpressionDefEvaluator.java:20)
	at org.opencds.cqf.cql.elm.execution.ExpressionRefEvaluator.evaluate(ExpressionRefEvaluator.java:14)
	at org.opencds.cqf.cql.elm.execution.QueryEvaluator.evaluate(QueryEvaluator.java:226)
	at org.opencds.cqf.cql.elm.execution.SumEvaluator.evaluate(SumEvaluator.java:72)
	at org.opencds.cqf.cql.elm.execution.InstanceEvaluator.evaluate(InstanceEvaluator.java:14)
	at org.opencds.cqf.cql.elm.execution.ExpressionDefEvaluator.evaluate(ExpressionDefEvaluator.java:20)
	at org.opencds.cqf.cql.elm.execution.ExpressionRefEvaluator.evaluate(ExpressionRefEvaluator.java:14)
	at org.opencds.cqf.cql.elm.execution.GreaterOrEqualEvaluator.evaluate(GreaterOrEqualEvaluator.java:78)
	at org.opencds.cqf.providers.FHIRPlanDefinitionResourceProvider.resolveActions(FHIRPlanDefinitionResourceProvider.java:273)
	at org.opencds.cqf.providers.FHIRPlanDefinitionResourceProvider.resolveCdsHooksPlanDefinition(FHIRPlanDefinitionResourceProvider.java:252)
	at org.opencds.cqf.providers.FHIRPlanDefinitionResourceProvider.resolveCdsHooksPlanDefinition(FHIRPlanDefinitionResourceProvider.java:221)
	at org.opencds.cqf.cds.CdsRequestProcessor.resolveActions(CdsRequestProcessor.java:38)
	at org.opencds.cqf.cds.OpioidGuidanceProcessor.process(OpioidGuidanceProcessor.java:96)
	at org.opencds.cqf.servlet.CdsServicesServlet.doPost(CdsServicesServlet.java:103)
	at ca.uhn.fhir.rest.server.RestfulServer.service(RestfulServer.java:1435)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.ebaysf.web.cors.CORSFilter.handleNonCORS(CORSFilter.java:437)
	at org.ebaysf.web.cors.CORSFilter.doFilter(CORSFilter.java:172)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
	at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:650)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)
	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:803)
	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:790)
	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1459)
	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
	at java.lang.Thread.run(Thread.java:745)
Caused by: java.sql.SQLException: No suitable driver found for jdbc:sqlite:///Users/jeff/apache-tomcat-8.5.24/bin/src/main/resources/cds/OpioidManagementTerminologyKnowledge.db
	at java.sql.DriverManager.getConnection(DriverManager.java:689)
	at java.sql.DriverManager.getConnection(DriverManager.java:270)
	at org.opencds.cqf.opioidcds.OmtkDataProvider.getNewConnection(OmtkDataProvider.java:50)
	... 57 more

from cqf-ruler.

c-schuler avatar c-schuler commented on September 26, 2024

Add sqlite-jdbc-3.15.1.jar to the libexec/lib directory. You also may need to add src/main/resources/cds/OpioidManagementTerminologyKnowledge.db to the libexec/bin directory.

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

Where is libexec? Not in cqf-ruler, not in Tomcat, not even in ~/ on my Mac.

from cqf-ruler.

c-schuler avatar c-schuler commented on September 26, 2024

I installed Tomcat with homebrew. Perhaps the directory structure is different than yours... I have tomcat/8.5.24/libexec/lib. You do have a lib directory, right? It should be at the same level as the webapps directory.

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

Interesting. I only have a lib directory but its the same tomcat version. I copied the sqlite jar into lib and restarted Tomcat but I still get the same error. Must be some obscure class loader difference. Continuing to investigate.

from cqf-ruler.

c-schuler avatar c-schuler commented on September 26, 2024

Try putting the following snippet in the OpioidGuidanceProcessor before the OmtkProvider is initialized and rebuild:

try {
        Class.forName("org.sqlite.JDBC");
} catch (ClassNotFoundException e) {
            e.printStackTrace();
}

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

from cqf-ruler.

c-schuler avatar c-schuler commented on September 26, 2024

And updating the war file in Tomcat results in the same error?

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

New exception:

2018-01-21 15:29:58.983 [http-nio-8080-exec-10] INFO  c.u.f.j.s.SearchCoordinatorSvcImpl [SearchCoordinatorSvcImpl.java:283] Reusing search 9663013d-ba48-45bc-a17e-6ff263aa93f1 from cache
2018-01-21 15:29:59.120 [http-nio-8080-exec-10] WARN  c.u.f.r.s.i.ExceptionHandlingInterceptor [ExceptionHandlingInterceptor.java:136] Failure during REST processing: ca.uhn.fhir.rest.server.exceptions.InvalidRequestException: Unable to find imported value set illicit-drug-urine-screening
2018-01-21 15:29:59.121 [http-nio-8080-exec-10] INFO  logging.accesslog [LoggingInterceptor.java:155] ERROR - search-type - Observation
ca.uhn.fhir.rest.server.exceptions.InvalidRequestException: HTTP 400 : Unable to find imported value set illicit-drug-urine-screening
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
	at ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException.newInstance(BaseServerResponseException.java:301)
	at ca.uhn.fhir.rest.client.impl.BaseClient.invokeClient(BaseClient.java:323)
	at ca.uhn.fhir.rest.client.impl.GenericClient$BaseClientExecutable.invoke(GenericClient.java:448)

from cqf-ruler.

c-schuler avatar c-schuler commented on September 26, 2024

Argh...
Load this PlanDefinition and try again:

{
    "resourceType": "PlanDefinition",
    "id": "cdc-opioid-guidance",
    "text": {
      "status": "generated",
      "div": "<div xmlns=\"http://www.w3.org/1999/xhtml\">CDC Opioid Prescribing Guideline Recommendation #5</div>"
    },
    "url": "http://hl7.org/fhir/ig/opioid-cds/PlanDefinition/cdc-opioid-05",
    "identifier": [
      {
        "use": "official",
        "value": "cdc-opioid-guidance"
      }
    ],
    "version": "0.1.0",
    "name": "cdc-opioid-05",
    "title": "CDC Opioid Prescribing Guideline Recommendation #5",
    "type": {
      "coding": [
        {
          "system": "http://hl7.org/fhir/plan-definition-type",
          "code": "eca-rule",
          "display": "ECA Rule"
        }
      ]
    },
    "status": "draft",
    "date": "2017-04-23",
    "publisher": "Centers for Disease Control and Prevention (CDC)",
    "description": "When opioids are started, providers should prescribe the lowest effective dosage.",
    "purpose": "CDC’s Guideline for Prescribing Opioids for Chronic Pain is intended to improve communication between providers and patients about the risks and benefits of opioid therapy for chronic pain, improve the safety and effectiveness of pain treatment, and reduce the risks associated with long-term opioid therapy, including opioid use disorder and overdose. The Guideline is not intended for patients who are in active cancer treatment, palliative care, or end-of-life care.",
    "usage": "Providers should use caution when prescribing opioids at any dosage, should carefully reassess evidence of individual benefits and risks when considering increasing dosage to ≥50 morphine milligram equivalents (MME)/day, and should avoid increasing dosage to ≥90 MME/day or carefully justify a decision to titrate dosage to >90 MME/day",
    "topic": [
      {
        "text": "Opioid Prescribing"
      }
    ],
    "relatedArtifact": [
      {
        "type": "documentation",
        "display": "CDC guideline for prescribing opioids for chronic pain",
        "url": "https://guidelines.gov/summaries/summary/50153/cdc-guideline-for-prescribing-opioids-for-chronic-pain---united-states-2016#420"
      },
      {
        "type": "documentation",
        "display": "MME Conversion Tables",
        "url": "https://www.cdc.gov/drugoverdose/pdf/calculating_total_daily_dose-a.pdf"
      }
    ],
    "library": [
      {
        "reference": "Library/OpioidCdsStu3"
      }
    ],
    "action": [
      {
        "title": "High risk for opioid overdose.",
        "description": "Total morphine milligram equivalent (MME) exceeds recommended amount. Taper to less than 50.",
        "triggerDefinition": [
          {
            "type": "named-event",
            "eventName": "medication-prescribe"
          }
        ],
        "condition": [
          {
            "kind": "applicability",
            "description": "Is total MME >= 50?",
            "language": "text/cql",
            "expression": "IsMME50OrMore"
          }
        ],
        "groupingBehavior": "visual-group",
        "selectionBehavior": "exactly-one",
        "dynamicValue": [
          {
            "path": "action.title",
            "expression": "getSummary"
          },
          {
            "path": "action.description",
            "expression": "getDetail"
          },
          {
            "path": "activity.extension",
            "expression": "getIndicator"
          }
        ]
      }
    ]
}

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

You'll be relieved (I am):

Sending 'POST' request to URL: http://localhost:8080/cqf-ruler/cds-services/cdc-opioid-guidance
{
  "cards": [
    {
      "links": [
        {
          "label": "CDC guideline for prescribing opioids for chronic pain",
          "url": "https://guidelines.gov/summaries/summary/50153/cdc-guideline-for-prescribing-opioids-for-chronic-pain---united-states-2016#420"
        },
        {
          "label": "MME Conversion Tables",
          "url": "https://www.cdc.gov/drugoverdose/pdf/calculating_total_daily_dose-a.pdf"
        }
      ]
    },
    {
      "summary": "Success",
      "indicator": "info",
      "detail": "Prescription satisfies recommendation #5 of the cdc opioid guidance."
    }
  ]
}

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

The only tests that are still failing are the ones with no prefetch, because of the Rx with no dosageInstructions we've discussed before. I'll try to patch them,

from cqf-ruler.

jeffeastman avatar jeffeastman commented on September 26, 2024

Fixed the missing dosageInstructions and the no-prefetch hooks are working too. Closing this issue.

from cqf-ruler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.