How to start a FHIR server?

843 views
Skip to first unread message

Ivan

unread,
Mar 4, 2021, 6:24:00 PM3/4/21
to HAPI FHIR
Hi everyone, I can't find a way to launch a working FHIR server. I read the doc and the guide several times but it didn't help. I'm using Eclipse, I only need a working FHIR server that I can run easilly.

Thank you very much

James Agnew

unread,
Mar 4, 2021, 7:11:22 PM3/4/21
to Ivan, HAPI FHIR
The JPA Starter project is the recommended easiest way to start with HAPI FHIR: https://github.com/hapifhir/hapi-fhir-jpaserver-starter

Cheers,
James

On Thu, Mar 4, 2021 at 6:24 PM Ivan <ivan.ma...@gmail.com> wrote:
Hi everyone, I can't find a way to launch a working FHIR server. I read the doc and the guide several times but it didn't help. I'm using Eclipse, I only need a working FHIR server that I can run easilly.

Thank you very much

--
You received this message because you are subscribed to the Google Groups "HAPI FHIR" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hapi-fhir+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/hapi-fhir/ba171f6a-39ea-4601-87e4-0eb52ee625e4n%40googlegroups.com.

Jens Villadsen

unread,
Mar 5, 2021, 5:24:57 AM3/5/21
to HAPI FHIR
Just run 'docker run -p 8080:8080 hapiproject/hapi:latest' and you have a full running HAPI FHIR server

Jay Gauthier

unread,
May 28, 2021, 6:20:47 PM5/28/21
to HAPI FHIR
Just got a new iMac with the Apple M1 chip. Installed Docker, can run simple docker containers. Tried the instructions for running HAPI FHIR server:
docker pull hapiproject/hapi:latest
docker run -p 8080:8080 hapiproject/hapi:latest

The pull is fine, the run starts up a server, but the log is full of exceptions and after waiting some minutes, http://localhost:8080 sends back a 404 error.

Any hints? Is that first warning (in bold) a showstopper because I'm running Docker on iMac? Is there a workaround, or will I have to build the server locally and make my own docker image? I was trying to avoid that since I just want a reference implementation locally, I won't need to modify it other than what is available through configuration.

Thanks in advance,
Jay

Sample logs:
jaygauthier-Jays-iMac Work % docker run -p 8080:8080 hapiproject/hapi:latest
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
NOTE: Picked up JDK_JAVA_OPTIONS:  --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED
28-May-2021 21:53:59.554 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server version name:   Apache Tomcat/9.0.38
28-May-2021 21:53:59.584 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server built:          Sep 10 2020 08:20:30 UTC
28-May-2021 21:53:59.585 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server version number: 9.0.38.0
28-May-2021 21:53:59.586 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log OS Name:               Linux
28-May-2021 21:53:59.586 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log OS Version:            5.10.25-linuxkit
28-May-2021 21:53:59.587 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Architecture:          amd64
28-May-2021 21:53:59.588 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Java Home:             /usr/local/openjdk-11
28-May-2021 21:53:59.588 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Version:           11.0.8+10
28-May-2021 21:53:59.589 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Vendor:            Oracle Corporation
28-May-2021 21:53:59.590 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_BASE:         /usr/local/tomcat
28-May-2021 21:53:59.590 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_HOME:         /usr/local/tomcat
28-May-2021 21:53:59.695 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: --add-opens=java.base/java.lang=ALL-UNNAMED
28-May-2021 21:53:59.697 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: --add-opens=java.base/java.io=ALL-UNNAMED
28-May-2021 21:53:59.698 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED
28-May-2021 21:53:59.698 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.config.file=/usr/local/tomcat/conf/logging.properties
28-May-2021 21:53:59.699 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
28-May-2021 21:53:59.699 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djdk.tls.ephemeralDHKeySize=2048
28-May-2021 21:53:59.700 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.protocol.handler.pkgs=org.apache.catalina.webresources
28-May-2021 21:53:59.700 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dorg.apache.catalina.security.SecurityListener.UMASK=0027
28-May-2021 21:53:59.700 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dignore.endorsed.dirs=
28-May-2021 21:53:59.701 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.base=/usr/local/tomcat
28-May-2021 21:53:59.701 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.home=/usr/local/tomcat
28-May-2021 21:53:59.701 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=/usr/local/tomcat/temp
28-May-2021 21:53:59.743 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded Apache Tomcat Native library [1.2.25] using APR version [1.6.5].
28-May-2021 21:53:59.744 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true].
28-May-2021 21:53:59.745 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
28-May-2021 21:53:59.781 INFO [main] org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL successfully initialized [OpenSSL 1.1.1d  10 Sep 2019]
28-May-2021 21:54:01.315 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8080"]
28-May-2021 21:54:01.484 INFO [main] org.apache.catalina.startup.Catalina.load Server initialization in [2903] milliseconds
28-May-2021 21:54:01.788 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina]
28-May-2021 21:54:01.789 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/9.0.38]
28-May-2021 21:54:01.862 INFO [main] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive [/usr/local/tomcat/webapps/ROOT.war]
28-May-2021 21:54:27.692 INFO [main] org.apache.jasper.servlet.TldScanner.scanJars At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::                (v2.4.4)

2021-05-28 21:54:32.110 [background-preinit] INFO  o.h.validator.internal.util.Version [Version.java:21] HV000001: Hibernate Validator 6.1.5.Final
2021-05-28 21:54:32.252 [main] INFO  ca.uhn.fhir.jpa.starter.Application [StartupInfoLogger.java:55] Starting Application using Java 11.0.8 on cc2ee5a8c7aa with PID 1 (/usr/local/tomcat/webapps/ROOT/WEB-INF/classes started by root in /usr/local/tomcat)
2021-05-28 21:54:32.266 [main] INFO  ca.uhn.fhir.jpa.starter.Application [SpringApplication.java:662] No active profile set, falling back to default profiles: default
2021-05-28 21:54:35.836 [background-preinit] WARN  o.s.h.c.j.Jackson2ObjectMapperBuilder [CompositeLog.java:127] For Jackson Kotlin classes support please add "com.fasterxml.jackson.module:jackson-module-kotlin" to the classpath
2021-05-28 21:54:37.177 [main] INFO  o.s.d.r.c.RepositoryConfigurationDelegate [RepositoryConfigurationDelegate.java:132] Bootstrapping Spring Data JPA repositories in DEFAULT mode.
2021-05-28 21:54:38.589 [main] INFO  o.s.d.r.c.RepositoryConfigurationDelegate [RepositoryConfigurationDelegate.java:201] Finished Spring Data repository scanning in 1353 ms. Found 50 JPA repository interfaces.
2021-05-28 21:54:42.829 [main] INFO  ca.uhn.fhir.util.VersionUtil [VersionUtil.java:84] HAPI FHIR version 5.4.0 - Rev b463b072c8
2021-05-28 21:54:42.843 [main] INFO  ca.uhn.fhir.context.FhirContext [FhirContext.java:204] Creating new FHIR context for FHIR version [R4]
2021-05-28 21:54:43.549 [main] WARN  o.s.b.w.s.c.AnnotationConfigServletWebServerApplicationContext [AbstractApplicationContext.java:591] Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'fhirServerConfigR4': Unsatisfied dependency expressed through field 'myDaoRegistry'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'myDaoRegistry' defined in class path resource [ca/uhn/fhir/jpa/starter/FhirServerConfigR4.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [ca.uhn.fhir.jpa.api.dao.DaoRegistry]: Circular reference involving containing bean 'fhirServerConfigR4' - consider declaring the factory method as static for independence from its containing instance. Factory method 'daoRegistry' threw exception; nested exception is org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
2021-05-28 21:54:43.610 [main] INFO  o.s.b.a.l.ConditionEvaluationReportLoggingListener [ConditionEvaluationReportLoggingListener.java:136] 

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2021-05-28 21:54:43.692 [main] ERROR o.s.boot.SpringApplication [SpringApplication.java:858] Application run failed
org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'fhirServerConfigR4': Unsatisfied dependency expressed through field 'myDaoRegistry'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'myDaoRegistry' defined in class path resource [ca/uhn/fhir/jpa/starter/FhirServerConfigR4.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [ca.uhn.fhir.jpa.api.dao.DaoRegistry]: Circular reference involving containing bean 'fhirServerConfigR4' - consider declaring the factory method as static for independence from its containing instance. Factory method 'daoRegistry' threw exception; nested exception is org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
        at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.resolveFieldValue(AutowiredAnnotationBeanPostProcessor.java:660)
        at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:640)
        at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:119)
        at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessProperties(AutowiredAnnotationBeanPostProcessor.java:399)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1413)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:601)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
        at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
        at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
        at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:410)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1334)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
        at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
        at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:213)
        at org.springframework.context.support.PostProcessorRegistrationDelegate.registerBeanPostProcessors(PostProcessorRegistrationDelegate.java:258)
        at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:762)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:567)
        at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:144)
        at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:769)
        at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:761)
        at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:426)
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:326)
        at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:173)
        at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:153)
        at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:95)
        at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174)
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5128)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:717)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:690)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:706)
        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:978)
        at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1848)
        at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
        at java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:118)
        at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:773)
        at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:427)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1576)
        at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:309)
        at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
        at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:423)
        at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:366)
        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:936)
        at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:843)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1384)
        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1374)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
        at java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:140)
        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:909)
        at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
        at org.apache.catalina.core.StandardService.startInternal(StandardService.java:421)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
        at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:930)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:772)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:342)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:473)
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'myDaoRegistry' defined in class path resource [ca/uhn/fhir/jpa/starter/FhirServerConfigR4.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [ca.uhn.fhir.jpa.api.dao.DaoRegistry]: Circular reference involving containing bean 'fhirServerConfigR4' - consider declaring the factory method as static for independence from its containing instance. Factory method 'daoRegistry' threw exception; nested exception is org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
        at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:658)
        at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:486)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1334)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
        at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
        at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
        at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:276)
        at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1380)
        at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1300)
        at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.resolveFieldValue(AutowiredAnnotationBeanPostProcessor.java:657)
        ... 71 common frames omitted
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [ca.uhn.fhir.jpa.api.dao.DaoRegistry]: Circular reference involving containing bean 'fhirServerConfigR4' - consider declaring the factory method as static for independence from its containing instance. Factory method 'daoRegistry' threw exception; nested exception is org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
        at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185)
        at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:653)
        ... 84 common frames omitted
Caused by: org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
        at org.springframework.cglib.core.ReflectUtils.defineClass(ReflectUtils.java:514)
        at org.springframework.cglib.core.AbstractClassGenerator.generate(AbstractClassGenerator.java:363)
        at org.springframework.cglib.core.AbstractClassGenerator$ClassLoaderData$3.apply(AbstractClassGenerator.java:110)
        at org.springframework.cglib.core.AbstractClassGenerator$ClassLoaderData$3.apply(AbstractClassGenerator.java:108)
        at org.springframework.cglib.core.internal.LoadingCache$2.call(LoadingCache.java:54)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at org.springframework.cglib.core.internal.LoadingCache.createEntry(LoadingCache.java:61)
        at org.springframework.cglib.core.internal.LoadingCache.get(LoadingCache.java:34)
        at org.springframework.cglib.core.AbstractClassGenerator$ClassLoaderData.get(AbstractClassGenerator.java:134)
        at org.springframework.cglib.core.AbstractClassGenerator.create(AbstractClassGenerator.java:319)
        at org.springframework.cglib.reflect.FastClass$Generator.create(FastClass.java:65)
        at org.springframework.cglib.proxy.MethodProxy.helper(MethodProxy.java:135)
        at org.springframework.cglib.proxy.MethodProxy.init(MethodProxy.java:76)
        at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:242)
        at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:331)
        at ca.uhn.fhir.jpa.starter.FhirServerConfigR4$$EnhancerBySpringCGLIB$$a9b957ad.daoRegistry(<generated>)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
        ... 85 common frames omitted
Caused by: java.lang.ClassFormatError: Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
        at java.base/java.lang.ClassLoader.defineClass1(Native Method)
        at java.base/java.lang.System$2.defineClass(System.java:2131)
        at java.base/java.lang.invoke.MethodHandles$Lookup.defineClass(MethodHandles.java:962)
        at java.base/jdk.internal.reflect.GeneratedMethodAccessor62.invoke(Unknown Source)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.springframework.cglib.core.ReflectUtils.defineClass(ReflectUtils.java:509)
        ... 105 common frames omitted
28-May-2021 21:54:43.699 SEVERE [main] org.apache.catalina.startup.HostConfig.deployWAR Error deploying web application archive [/usr/local/tomcat/webapps/ROOT.war]
        java.lang.IllegalStateException: Error starting child
                at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:720)
                at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:690)
                at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:706)
                at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:978)
                at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1848)
                at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
                at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
                at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
                at java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:118)
                at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:773)
                at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:427)
                at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1576)
                at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:309)
                at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
                at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:423)
                at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:366)
                at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:936)
                at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:843)
                at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
                at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1384)
                at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1374)
                at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
                at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
                at java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:140)
                at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:909)
                at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)
                at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
                at org.apache.catalina.core.StandardService.startInternal(StandardService.java:421)
                at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
                at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:930)
                at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
                at org.apache.catalina.startup.Catalina.start(Catalina.java:772)
                at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
                at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
                at java.base/java.lang.reflect.Method.invoke(Method.java:566)
                at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:342)
                at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:473)
        Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[]]
                at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:440)
                at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:198)
                at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:717)
                ... 37 more
        Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'fhirServerConfigR4': Unsatisfied dependency expressed through field 'myDaoRegistry'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'myDaoRegistry' defined in class path resource [ca/uhn/fhir/jpa/starter/FhirServerConfigR4.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [ca.uhn.fhir.jpa.api.dao.DaoRegistry]: Circular reference involving containing bean 'fhirServerConfigR4' - consider declaring the factory method as static for independence from its containing instance. Factory method 'daoRegistry' threw exception; nested exception is org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
                at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.resolveFieldValue(AutowiredAnnotationBeanPostProcessor.java:660)
                at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:640)
                at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:119)
                at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessProperties(AutowiredAnnotationBeanPostProcessor.java:399)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1413)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:601)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
                at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
                at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
                at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
                at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
                at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:410)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1334)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
                at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
                at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
                at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
                at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:213)
                at org.springframework.context.support.PostProcessorRegistrationDelegate.registerBeanPostProcessors(PostProcessorRegistrationDelegate.java:258)
                at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:762)
                at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:567)
                at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:144)
                at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:769)
                at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:761)
                at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:426)
                at org.springframework.boot.SpringApplication.run(SpringApplication.java:326)
                at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:173)
                at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:153)
                at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:95)
                at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174)
                at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5128)
                at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
                ... 38 more
        Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'myDaoRegistry' defined in class path resource [ca/uhn/fhir/jpa/starter/FhirServerConfigR4.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [ca.uhn.fhir.jpa.api.dao.DaoRegistry]: Circular reference involving containing bean 'fhirServerConfigR4' - consider declaring the factory method as static for independence from its containing instance. Factory method 'daoRegistry' threw exception; nested exception is org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
                at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:658)
                at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:486)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1334)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564)
                at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
                at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
                at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
                at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
                at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
                at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:276)
                at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1380)
                at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1300)
                at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.resolveFieldValue(AutowiredAnnotationBeanPostProcessor.java:657)
                ... 71 more
        Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [ca.uhn.fhir.jpa.api.dao.DaoRegistry]: Circular reference involving containing bean 'fhirServerConfigR4' - consider declaring the factory method as static for independence from its containing instance. Factory method 'daoRegistry' threw exception; nested exception is org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
                at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185)
                at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:653)
                ... 84 more
        Caused by: org.springframework.cglib.core.CodeGenerationException: java.lang.ClassFormatError-->Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
                at org.springframework.cglib.core.ReflectUtils.defineClass(ReflectUtils.java:514)
                at org.springframework.cglib.core.AbstractClassGenerator.generate(AbstractClassGenerator.java:363)
                at org.springframework.cglib.core.AbstractClassGenerator$ClassLoaderData$3.apply(AbstractClassGenerator.java:110)
                at org.springframework.cglib.core.AbstractClassGenerator$ClassLoaderData$3.apply(AbstractClassGenerator.java:108)
                at org.springframework.cglib.core.internal.LoadingCache$2.call(LoadingCache.java:54)
                at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
                at org.springframework.cglib.core.internal.LoadingCache.createEntry(LoadingCache.java:61)
                at org.springframework.cglib.core.internal.LoadingCache.get(LoadingCache.java:34)
                at org.springframework.cglib.core.AbstractClassGenerator$ClassLoaderData.get(AbstractClassGenerator.java:134)
                at org.springframework.cglib.core.AbstractClassGenerator.create(AbstractClassGenerator.java:319)
                at org.springframework.cglib.reflect.FastClass$Generator.create(FastClass.java:65)
                at org.springframework.cglib.proxy.MethodProxy.helper(MethodProxy.java:135)
                at org.springframework.cglib.proxy.MethodProxy.init(MethodProxy.java:76)
                at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:242)
                at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:331)
                at ca.uhn.fhir.jpa.starter.FhirServerConfigR4$$EnhancerBySpringCGLIB$$a9b957ad.daoRegistry(<generated>)
                at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
                at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
                at java.base/java.lang.reflect.Method.invoke(Method.java:566)
                at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
                ... 85 more
        Caused by: java.lang.ClassFormatError: Class name is empty or contains illegal character in descriptor in class file ca/uhn/fhir/jpa/config/BaseConfig$$FastClassBySpringCGLIB$$278fc94c
                at java.base/java.lang.ClassLoader.defineClass1(Native Method)
                at java.base/java.lang.System$2.defineClass(System.java:2131)
                at java.base/java.lang.invoke.MethodHandles$Lookup.defineClass(MethodHandles.java:962)
                at java.base/jdk.internal.reflect.GeneratedMethodAccessor62.invoke(Unknown Source)
                at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
                at java.base/java.lang.reflect.Method.invoke(Method.java:566)
                at org.springframework.cglib.core.ReflectUtils.defineClass(ReflectUtils.java:509)
                ... 105 more
28-May-2021 21:54:43.721 INFO [main] org.apache.catalina.startup.HostConfig.deployWAR Deployment of web application archive [/usr/local/tomcat/webapps/ROOT.war] has finished in [41,857] ms
28-May-2021 21:54:43.744 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"]
28-May-2021 21:54:43.790 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in [42305] milliseconds
28-May-2021 21:58:31.202 INFO [http-nio-8080-exec-8] org.apache.coyote.http11.Http11Processor.service Error parsing HTTP request header
 Note: further occurrences of HTTP request parsing errors will be logged at DEBUG level.
        java.lang.IllegalArgumentException: Invalid character found in method name [0x160x030x010x020x000x010x000x010xfc0x030x030x070x82"}0x040x01t0x920xc9%0xb2%x%0xfc'>0xce20xa80x880x850xd60xef0xd0^j/0x960xa0(0xea]. HTTP method names must be tokens
                at org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:413)
                at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:261)
                at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
                at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
                at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1590)
                at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
                at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
                at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
                at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
                at java.base/java.lang.Thread.run(Thread.java:834)


Jay Gauthier

unread,
May 29, 2021, 12:30:22 AM5/29/21
to HAPI FHIR
[SOLVED]

I went ahead and installed all the tools and source, built and ran the server locally and then build and ran the Docker container. Whoever contributes to this project should be proud, this is a fine piece of work! I will find a way to contribute in my own way. This is just the start of my HAPI FHIR journey!

Jay G

Jamiu Ejiwumi

unread,
Nov 2, 2022, 8:15:48 AM11/2/22
to HAPI FHIR
Hi @jayrga, am currently having this same issue, can you help with the list of tools you install to get the Hapi fhir running fine?

Thanks

Jamiu Ejiwumi

unread,
Nov 2, 2022, 8:16:57 AM11/2/22
to HAPI FHIR
Am trying to run HAPI FHIR on my kubernetes cluster but the pods keeps crashing
Reply all
Reply to author
Forward
0 new messages