Can't resolve the 404 error
I have build the module in IntelliJ and have the ROOT.war file. Deployed the WAR in Apache Tomcat, and while accessing http://localhost:8080/fhir/metadata, I am getting:
HTTP Status 404 – Not Found Type Status Report
Message The requested resource [/fhir/metadata] is not available
Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.
Do I need to update any source code or configuration? Thankn you.
Can you try with below path, I also face the same problem http://localhost:8080/ROOT/fhir/metadata
Try this:
http://localhost:8080/metadata
On Tue, Feb 23, 2021 at 6:53 AM Shubham Parikh [email protected] wrote:
Can you try with below path, I also face the same problem http://localhost:8080/ROOT/fhir/metadata
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/hapifhir/hapi-fhir-jpaserver-starter/issues/213#issuecomment-784147062, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARFQKGKN2N67TSXWJYCD3WLTAOJKJANCNFSM4X6IFCKQ .
Tried both, but still same issue.
Under the http://localhost:8080/manager/html/, I can see the following:
Path: / Version:None Specified
Any idea, why it is not showing? It got deployed.
The Dockerfile actually deploys the war file to Tomcat (https://github.com/hapifhir/hapi-fhir-jpaserver-starter/blob/master/Dockerfile#L28). I don't see any errors when running the service from Docker @krisdas73
Could you please share your configurations?
I am facing the same issue. I just pulled the docker and ran the command.. server is up but I am seeing 404 no matter what resource endpoint or /metdata i try.
Check the screenshot

and in CLI i have noticed this some URLMalformed error :

Some class format Exception :

I guess you need to keep coherence in several configurations:
- In the application.yaml: server.servlet.context-path, hapi.fhir.server_address and hapi.fhir.tester.home.server_address, packaging war/jar...
- In the pom you could set the target generated WAR file other that the default ROOT.war
- build>finalName>${project.artifactId}
- If using jetty to boot it, jetty-maven-plugin:configuration>webApp>contextPath>/${project.artifactId}
- If using just spring boot, the previous context-path should be ok, note there is a re-build! when using the boot profile, that changes the structure of the generated artifact
- In the Dockerfile, depending on how you boot later the app (spring boot? placing the war in a tomcat?), rename and place the proper file: COPY --from=build-hapi --chown=1001:1001 /tmp/hdh-cdr/target/{theProjectArtifactId}.war /opt/bitnami/tomcat/webapps/theProjectArtifactId}.war CMD ["java", "-jar", "/app/{theProjectArtifactId}.war"]
Hi, I am facing the same issue. I can run the application locally with Jetty and Spring Boot. However after I do a clean build with "mvn clean install" or "mvn clean package" and drop the ROOT.war to webapps in standalone Tomcat, I keep getting the 404 for localhost:8080 or localhost:8080/fhir. I am deploying it to the root in Tomcat so I am guessing I do not need to any configurative changes in any of the files (such as application.yaml). I am also using he default settings for the H2 DB.
Unlike the OP, I don't get any errors / stack traces on deployment to Tomcat, nothing in the server logs too.
Any one know how to resolve this 404?
Closing as stale