Hi, I’m new to OpenEHR & EHRBase. I have studied the OpenEHR specification. I found that many concepts are interesting. I want to make a proof of concept to use Spring Boot with EHRBase as a backend with some business logic.
I have already tried angular-SDK-example. I now want to start my own API development using Java, following the example but with different package versions. (I’m not Java Developer. I usually use Typescript.). Here is my stack
- Java 11
- Spring Boot v2.7.1
- EHRBase SDK Client v1.19.0
After running a repo, I found that the service cannot upload new OPT with following error,
Caused by: org.ehrbase.client.exception.WrongStatusCodeException: Wrong Status code. Expected: [200, 201, 204]. Got: 404. Error message: <!doctype html><html lang="en"><head><title>HTTP Status 404 – Not Found</title><style type="text/css">body {font-family:Tahoma,Arial,sans-serif;} h1, h2, h3, b {color:white;background-color:#525D76;} h1 {font-size:22px;} h2 {font-size:16px;} h3 {font-size:14px;} p {font-size:12px;} a {color:black;} .line {height:1px;background-color:#525D76;border:none;}</style></head><body><h1>HTTP Status 404 – Not Found</h1></body></html>
at org.ehrbase.client.openehrclient.defaultrestclient.DefaultRestClient.checkStatus(DefaultRestClient.java:283) ~[client-1.18.0.jar:na]
at org.ehrbase.client.openehrclient.defaultrestclient.DefaultRestClient.internalPost(DefaultRestClient.java:167) ~[client-1.18.0.jar:na]
at org.ehrbase.client.openehrclient.defaultrestclient.DefaultRestTemplateEndpoint.upload(DefaultRestTemplateEndpoint.java:132) ~[client-1.18.0.jar:na]
at org.ehrbase.client.openehrclient.defaultrestclient.DefaultRestTemplateEndpoint.ensureExistence(DefaultRestTemplateEndpoint.java:113) ~[client-1.18.0.jar:na]
at com.example.democpoe.config.ClientConfig.lambda$afterPropertiesSet$0(ClientConfig.java:63) ~[classes/:na]
at java.base/java.util.ArrayList.forEach(ArrayList.java:1541) ~[na:na]
at com.example.democpoe.config.ClientConfig.afterPropertiesSet(ClientConfig.java:60) ~[classes/:na]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1863) ~[spring-beans-5.3.21.jar:5.3.21]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1800) ~[spring-beans-5.3.21.jar:5.3.21]
... 21 common frames omitted
Here is my POC repo GitHub POC Repo.
Can anyone suggest what should I do next?
Best regards
Pawat