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

error importing LOINC terminology with hapi-fhir-cli #1629

Open
sandrozbinden opened this issue Dec 12, 2019 · 8 comments
Open

error importing LOINC terminology with hapi-fhir-cli #1629

sandrozbinden opened this issue Dec 12, 2019 · 8 comments

Comments

@sandrozbinden
Copy link

Describe the bug
We tried to import LOINC terminologies to our hapi-fhir server using the hapi-fhir-cli but unfortunately received a HTTP 400 Bad Request.

To Reproduce

  1. Download hapi-fhir-cli 4.1.0 from https://github.com/jamesagnew/hapi-fhir/releases
  2. Execute the following command:
    hapi-fhir-cli upload-terminology -d Downloads/Loinc_2.66.zip -v r4 -t https://localhost:8081/hapi-fhir-jpaserver/fhir/ -u https://loinc.org
  3. We receive the following error on cli:
    ca.uhn.fhir.rest.server.exceptions.InvalidRequestException: HTTP 400 Bad Request: Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[CodeSystem/$upload-external-code-system] with parameters [[]]

Expected behavior
The LOINC terminology should be imported.

Environment:

  • HAPI FHIR Version: 4.1.0
  • HAPI FHIR CLI: 4.1.0
  • OS: Windows 10
  • LOINC: Loinc_2_66

JSON Response:

{
  "resourceType": "OperationOutcome",
  "text": {
    "status": "generated",
    "div": "...Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[CodeSystem/$upload-external-code-system] with parameters [[]]..."
  },
  "issue": [
    {
      "severity": "error",
      "code": "processing",
      "diagnostics": "Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[CodeSystem/$upload-external-code-system] with parameters [[]]"
    }
  ]
}
@jamesagnew
Copy link
Collaborator

A fix has just been committed that should also address this issue.

Can you please try building HAPI FHIR locally and confirming whether you still see this issue?

@sandrozbinden
Copy link
Author

sandrozbinden commented Dec 20, 2019

Hi James

We used the newest HAPI FHIR Server and also updated the CLI but still got the same issue. What we did was running the jpa-server-starter locally with on the newest master branch. Did you mean something elese with building the HAPI FHIR Server?

@jamesagnew
Copy link
Collaborator

jamesagnew commented Dec 20, 2019 via email

@HananAwwad
Copy link
Contributor

i have pulled branch rel_4_2_0 from https://github.com/hapifhir/hapi-fhir-jpaserver-starter
and run the server but sill i have the same error

@HananAwwad
Copy link
Contributor

HananAwwad commented Jan 8, 2020

FYI, this is not a problem in any hapi fhir jpa starter; just you need to enable register TerminologyUploaderProvider

@djvreeman
Copy link

Unfortunately I'm having the same issues with the following setup:

HAPI FHIR Server - 4.2.0
HAPI FHIR 4.3.0-SNAPSHOT - Command Line Tool
Loinc_2.67.zip

Command:
sudo java -Xmx2G -jar hapi-fhir-cli.jar upload-terminology -d loinc/Loinc_2.67.zip -v r4 -t https://localhost:8080/hapi-fhir-jpaserver/fhir/ -v r4 -u https://loinc.org

I'm using the CLI to update the terminology resources on the local server (which is deployed with the recent 4.2.0 release). Since the release notes mention support for LOINC v2.67, I was expecting this to work.

Instead I get the same error as @sandrozbinden :

{
  "resourceType": "OperationOutcome",
  "text": {
    "status": "generated",
    "div": "<div xmlns=\"https://www.w3.org/1999/xhtml\"><h1>Operation Outcome</h1><table border=\"0\"><tr><td style=\"font-weight: bold;\">ERROR</td><td>[]</td><td><pre>Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[CodeSystem/$upload-external-code-system] with parameters [[]]</pre></td>\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t</tr>\n\t\t</table>\n\t</div>"
  },
  "issue": [
    {
      "severity": "error",
      "code": "processing",
      "diagnostics": "Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[CodeSystem/$upload-external-code-system] with parameters [[]]"
    }
  ]
}

@HananAwwad
Copy link
Contributor

Hello djvreeman,

This error come up when the TerminologyUploaderProvider is not registered in the server it self; its disabled by default; you need to enable registering it at the startup

Its working with me; feel free to call me at skype "hanan.s.awwad" if you need any help;

@Supratentorial
Copy link

Supratentorial commented Jul 24, 2020

This still comes up high in Google search results. @HananAwwad is correct, the configuration line can be found in BaseJparestfulServer.java:

if (false) { // <-- DISABLED RIGHT NOW registerProvider(appCtx.getBean(TerminologyUploaderProvider.class)); }

Then use the hapi-fhir-cli tool to upload the terminology of choice.
Can close the issue now but consider improving the documentation.

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

5 participants