FHIR Chat · Client Transaction error · implementers

Stream: implementers

Topic: Client Transaction error


view this post on Zulip Ma Sk (Aug 14 2019 at 03:12):

Hi guys, i have a problem with my runnable jar file.

When i run it on a VM, i get the error message :
at ca.uhn.fhir.rest.client.exceptions.NonFhirResponseException.newInstance(NonFhirResponseException.java:63)
at ca.uhn.fhir.rest.client.BaseClient$ResourceResponseHandler.invokeClient(BaseClient.java:483)
at ca.uhn.fhir.rest.client.BaseClient$ResourceResponseHandler.invokeClient(BaseClient.java:441)
at ca.uhn.fhir.rest.client.BaseClient.invokeClient(BaseClient.java:320)
at ca.uhn.fhir.rest.client.GenericClient$BaseClientExecutable.invoke(GenericClient.java:741)
at ca.uhn.fhir.rest.client.GenericClient$TransactionExecutable.execute(GenericClient.java:2377)

The error occurs when my code tries to transfer the fhir bundle to the server:
IGenericClient client = ctx.newRestfulGenericClient("http://hapi.fhir.org/baseDstu3");
Bundle resp = client.transaction().withBundle(bundle).execute(); <----------------- at this line

It works fine on my computer, but not on the VM. At first i thought it has something to do with missing libraries or whatever, but part of the code works fine on the VM.

EDIT: the problem was, i tried to access a DSTU3 server
My code is DSTU2


Last updated: Apr 12 2022 at 19:14 UTC