hapi-fhir-jpaserver-starter
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-jpaserver-starter</artifactId> <version>5.4.0</version> </dependency>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <!-- one-liner to take you to the cloud with settings form the application.yaml file: --> <!-- 'mvn clean package com.google.cloud.tools:jib-maven-plugin:dockerBuild -Dimage=distroless-hapi && docker run -p 8080:8080 -e spring.batch.job.enabled=false distroless-hapi' --> <!-- Note: HAPI projects use the "hapi-fhir" POM as their base to provide easy management. You do not need to use this in your own projects, so the "parent" tag and it's contents below may be removed if you are using this file as a basis for your own project. --> <parent> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir</artifactId> <version>5.4.0</version> </parent> <artifactId>hapi-fhir-jpaserver-starter</artifactId> <properties> <java.version>8</java.version> </properties> <prerequisites> <maven>3.6.3</maven> </prerequisites> <packaging>war</packaging> <name>HAPI FHIR JPA Server - Starter Project</name> <repositories> <repository> <id>oss-snapshots</id> <snapshots> <enabled>true</enabled> </snapshots> <url>https://oss.sonatype.org/content/repositories/snapshots/</url> </repository> </repositories> <dependencies> <dependency> <groupId>org.eclipse.jetty.websocket</groupId> <artifactId>websocket-api</artifactId> <version>${jetty_version}</version> </dependency> <dependency> <groupId>org.eclipse.jetty.websocket</groupId> <artifactId>websocket-client</artifactId> <version>${jetty_version}</version> </dependency> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>8.0.16</version> </dependency> <!-- https://mvnrepository.com/artifact/org.postgresql/postgresql --> <dependency> <groupId>org.postgresql</groupId> <artifactId>postgresql</artifactId> <version>42.2.9</version> </dependency> <!-- Needed for Email subscriptions --> <dependency> <groupId>com.sun.mail</groupId> <artifactId>javax.mail</artifactId> <exclusions> <exclusion> <groupId>javax.activation</groupId> <artifactId>activation</artifactId> </exclusion> </exclusions> </dependency> <!-- This dependency includes the core HAPI-FHIR classes --> <dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-base</artifactId> <version>${project.version}</version> </dependency> <!-- This dependency includes the JPA server itself, which is packaged separately from the rest of HAPI FHIR --> <dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-jpaserver-base</artifactId> <version>${project.version}</version> <exclusions> <exclusion> <groupId>org.springframework</groupId> <artifactId>spring-jcl</artifactId> </exclusion> <exclusion> <groupId>commons-logging</groupId> <artifactId>commons-logging</artifactId> </exclusion> </exclusions> </dependency> <!-- This dependency includes the JPA CQL Server --> <dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-jpaserver-cql</artifactId> <version>${project.version}</version> </dependency> <!-- This dependency includes the JPA MDM Server --> <dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-jpaserver-mdm</artifactId> <version>${project.version}</version> </dependency> <!-- This dependency is used for the "FHIR Tester" web app overlay --> <dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-testpage-overlay</artifactId> <version>${project.version}</version> <type>war</type> <scope>provided</scope> </dependency> <dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-testpage-overlay</artifactId> <version>${project.version}</version> <classifier>classes</classifier> </dependency> <!-- HAPI-FHIR uses Logback for logging support. The logback library is included automatically by Maven as a part of the hapi-fhir-base dependency, but you also need to include a logging library. Logback is used here, but log4j would also be fine. --> <dependency> <groupId>ch.qos.logback</groupId> <artifactId>logback-classic</artifactId> </dependency> <!-- Needed for JEE/Servlet support --> <dependency> <groupId>javax.servlet</groupId> <artifactId>javax.servlet-api</artifactId> <scope>provided</scope> </dependency> <!-- If you are using HAPI narrative generation, you will need to include Thymeleaf as well. Otherwise the following can be omitted. --> <dependency> <groupId>org.thymeleaf</groupId> <artifactId>thymeleaf</artifactId> </dependency> <!-- Used for CORS support --> <!-- Spring Web is used to deploy the server to a web container. --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-web</artifactId> </dependency> <!-- You may not need this if you are deploying to an application server which provides database connection pools itself. --> <dependency> <groupId>org.apache.commons</groupId> <artifactId>commons-dbcp2</artifactId> <exclusions> <exclusion> <groupId>commons-logging</groupId> <artifactId>commons-logging</artifactId> </exclusion> </exclusions> </dependency> <!-- This example uses H2 embedded database. If you are using another database such as Mysql or Oracle, you may omit the following dependencies and replace them with an appropriate database client dependency for your database platform. --> <dependency> <groupId>com.h2database</groupId> <artifactId>h2</artifactId> </dependency> <!-- webjars --> <dependency> <groupId>org.webjars</groupId> <artifactId>bootstrap</artifactId> <version>3.3.7</version> </dependency> <dependency> <groupId>org.webjars</groupId> <artifactId>Eonasdan-bootstrap-datetimepicker</artifactId> </dependency> <dependency> <groupId>org.webjars</groupId> <artifactId>font-awesome</artifactId> </dependency> <dependency> <groupId>org.webjars.bower</groupId> <artifactId>awesome-bootstrap-checkbox</artifactId> </dependency> <dependency> <groupId>org.webjars</groupId> <artifactId>jstimezonedetect</artifactId> </dependency> <dependency> <groupId>org.webjars</groupId> <artifactId>select2</artifactId> </dependency> <dependency> <groupId>org.webjars.bower</groupId> <artifactId>jquery</artifactId> </dependency> <dependency> <groupId>org.webjars.bower</groupId> <artifactId>moment</artifactId> </dependency> <!-- The following dependencies are only needed for automated unit tests, you do not neccesarily need them to run the example. --> <dependency> <groupId>org.eclipse.jetty</groupId> <artifactId>jetty-servlets</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.jetty</groupId> <artifactId>jetty-servlet</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.jetty.websocket</groupId> <artifactId>websocket-server</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.jetty</groupId> <artifactId>jetty-server</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.jetty</groupId> <artifactId>jetty-util</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.jetty</groupId> <artifactId>jetty-webapp</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> <artifactId>testcontainers</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> <artifactId>elasticsearch</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> <artifactId>junit-jupiter</artifactId> <scope>test</scope> </dependency> <!-- For some reason JavaDoc crashed during site generation unless we have this dependency --> <dependency> <groupId>javax.interceptor</groupId> <artifactId>javax.interceptor-api</artifactId> <scope>provided</scope> </dependency> <dependency> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-test-utilities</artifactId> <version>${project.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.awaitility</groupId> <artifactId>awaitility</artifactId> <version>4.0.0-rc1</version> <scope>test</scope> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-autoconfigure</artifactId> <version>${spring_boot_version}</version> </dependency> <dependency> <groupId>org.junit.jupiter</groupId> <artifactId>junit-jupiter-api</artifactId> <version>5.6.2</version> <scope>test</scope> </dependency> <dependency> <groupId>org.junit.jupiter</groupId> <artifactId>junit-jupiter-engine</artifactId> <version>5.6.2</version> <scope>test</scope> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-test</artifactId> <version>${spring_boot_version}</version> <scope>test</scope> </dependency> </dependencies> <build> <pluginManagement> <plugins> <!-- There is a bug in 3.1.2 that prevents go-offline from working Reported here: https://issues.apache.org/jira/browse/MDEP-739 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-dependency-plugin</artifactId> <version>3.1.1</version> </plugin> </plugins> </pluginManagement> <!-- Tells Maven to name the generated WAR file as ROOT.war --> <finalName>ROOT</finalName> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <executions> <execution> <goals> <goal>repackage</goal> </goals> <configuration> <mainClass>ca.uhn.fhir.jpa.starter.Application</mainClass> </configuration> </execution> </executions> </plugin> <!-- The following is not required for the application to build, but allows you to test it by issuing "mvn package jetty:run -Dspring.batch.job.enabled=false" from the command line. --> <!-- <plugin> <groupId>org.eclipse.jetty</groupId> <artifactId>jetty-maven-plugin</artifactId> <version>${jetty_version}</version> <configuration> <webApp> <contextPath>/hapi-fhir-jpaserver</contextPath> <allowDuplicateFragmentNames>true</allowDuplicateFragmentNames> </webApp> </configuration> </plugin> --> <!-- Tell Maven which Java source version you want to use --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.1</version> <configuration> <release>8</release> </configuration> </plugin> <!-- The configuration here tells the WAR plugin to include the FHIR Tester overlay. You can omit it if you are not using that feature. --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-war-plugin</artifactId> <configuration> <archive> <manifestEntries> <Build-Time>${maven.build.timestamp}</Build-Time> </manifestEntries> </archive> <overlays> <overlay> <groupId>ca.uhn.hapi.fhir</groupId> <artifactId>hapi-fhir-testpage-overlay</artifactId> </overlay> </overlays> <failOnMissingWebXml>false</failOnMissingWebXml> </configuration> </plugin> <!-- This is to run the integration tests --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-failsafe-plugin</artifactId> <configuration> <redirectTestOutputToFile>true</redirectTestOutputToFile> </configuration> <executions> <execution> <goals> <goal>integration-test</goal> <goal>verify</goal> </goals> </execution> </executions> </plugin> <plugin> <groupId>org.basepom.maven</groupId> <artifactId>duplicate-finder-maven-plugin</artifactId> <executions> <execution> <id>default</id> <phase>verify</phase> <goals> <goal>check</goal> </goals> <inherited>true</inherited> </execution> </executions> <configuration> <failBuildInCaseOfConflict>false</failBuildInCaseOfConflict> <checkTestClasspath>false</checkTestClasspath> <!-- <printEqualFiles>false</printEqualFiles> <failBuildInCaseOfDifferentContentConflict>true</failBuildInCaseOfDifferentContentConflict> <failBuildInCaseOfEqualContentConflict>true</failBuildInCaseOfEqualContentConflict> <failBuildInCaseOfConflict>true</failBuildInCaseOfConflict> <checkCompileClasspath>true</checkCompileClasspath> <checkRuntimeClasspath>false</checkRuntimeClasspath> <skip>false</skip> <quiet>false</quiet> <preferLocal>true</preferLocal> <useResultFile>true</useResultFile> <resultFileMinClasspathCount>2</resultFileMinClasspathCount> <resultFile>${project.build.directory}/duplicate-finder-result.xml</resultFile> --> <!-- <ignoredDependencies> <dependency> <groupId>javax.el</groupId> <artifactId>javax.el-api</artifactId> </dependency> <dependency> <groupId>javax.mail</groupId> <artifactId>javax.mail-api</artifactId> </dependency> <dependency> <groupId>javax.activation</groupId> <artifactId>javax.activation-api</artifactId> </dependency> <dependency> <groupId>com.helger</groupId> <artifactId>ph-schematron</artifactId> </dependency> <dependency> <groupId>commons-logging</groupId> <artifactId>commons-logging</artifactId> </dependency> <dependency> <groupId>org.jscience</groupId> <artifactId>jscience</artifactId> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-jcl</artifactId> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-jcl</artifactId> </dependency> <dependency> <groupId>com.google.code.findbugs</groupId> <artifactId>annotations</artifactId> </dependency> <dependency> <groupId>org.apache.derby</groupId> <artifactId>derbyclient</artifactId> </dependency> <dependency> <groupId>org.apache.derby</groupId> <artifactId>derbynet</artifactId> </dependency> <dependency> <groupId>org.apache.derby</groupId> <artifactId>derbyclient</artifactId> </dependency> <dependency> <groupId>org.checkerframework</groupId> <artifactId>checker-compat-qual</artifactId> </dependency> </ignoredDependencies> --> <ignoredResourcePatterns> <ignoredResourcePattern>.*\.txt$</ignoredResourcePattern> <ignoredResourcePattern>.*\.html$</ignoredResourcePattern> <ignoredResourcePattern>config/favicon.ico</ignoredResourcePattern> </ignoredResourcePatterns> </configuration> </plugin> </plugins> </build> <profiles> <!-- Package the war for your preference. Use the boot profile if you prefer a single jar/war that can be started with and embedded application server. Default is jetty as it is assumed that the main users of this project already have an app server. Different profiles are needed as packing it for spring boot, makes the resulting war undeployable due to a class shading issue between tomcat and jetty. (the error is 'java.util.ServiceConfigurationError: org.apache.juli.logging.Log: org.eclipse.jetty.apache.jsp.JuliLog not a subtype') --> <!-- example of how to start the server using spring boot--> <!-- mvn clean package spring-boot:repackage -Pboot && java -jar target/hapi-fhir-jpaserver.war --> <!-- Use the boot profile for development and debugging options when using your IDE --> <profile> <id>boot</id> <dependencies> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> <version>${spring_boot_version}</version> </dependency> </dependencies> </profile> <!-- examples of how to start the server using the default profile--> <!-- mvn clean package jetty:run -Dspring.batch.job.enabled=false --> <!-- java -jar -Dspring.batch.job.enabled=false jetty-runner.jar target/hapi-fhir-jpaserver.war --> <profile> <id>jetty</id> <dependencies> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> <version>${spring_boot_version}</version> <exclusions> <exclusion> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-tomcat</artifactId> </exclusion> </exclusions> </dependency> </dependencies> </profile> </profiles> </project>