<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>
	<name>li2b2 : server</name>
	<packaging>jar</packaging>

	<description>
	This project emulates the core components
	of an i2b2 server backend. Basic functionality
	of PM, CRC, ONT and WORK cells allows the
	official i2b2 webclient to connect ot this
	emulated server.
	</description>

	<groupId>de.li2b2.facade</groupId>
	<artifactId>li2b2-server</artifactId>
	<version>0.8</version>

	<parent>
		<groupId>de.li2b2.facade</groupId>
		<artifactId>li2b2-facade</artifactId>
		<version>0.8</version>
	</parent>


	<profiles>
		<profile>
			<id>webclient</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-dependency-plugin</artifactId>
						<version>3.0.2</version>
						<executions>
							<execution>
								<id>unpack</id>
								<phase>generate-resources</phase>
								<goals>
									<goal>unpack</goal>
								</goals>
								<configuration>
									<artifactItems>
										<!-- this is a non-standard dependency bundle with i2b2 webclient. 
											See README.md for instructions. -->
										<artifactItem>
											<groupId>org.i2b2</groupId>
											<artifactId>webclient</artifactId>
											<version>1.7.12.0001</version>
											<type>zip</type>
										</artifactItem>
									</artifactItems>
									<outputDirectory>${project.build.directory}/generated-resources</outputDirectory>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
				<resources>
					<resource>
						<directory>src/main/resources</directory>
					</resource>
					<resource>
						<directory>${project.build.directory}/generated-resources</directory>
					</resource>
				</resources>
			</build>
		</profile>
	</profiles>

	<dependencies>
		<!-- compile time dependencies -->
		<dependency>
			<groupId>de.li2b2.facade</groupId>
			<artifactId>li2b2-api</artifactId>
			<version>0.8</version>
		</dependency>
		<dependency>
			<groupId>de.li2b2.facade</groupId>
			<artifactId>li2b2-xml</artifactId>
			<version>0.8</version>
		</dependency>
		<dependency>
			<groupId>de.li2b2.facade</groupId>
			<artifactId>li2b2-client</artifactId>
			<version>0.8</version>
			<scope>test</scope>
		</dependency>

		<!-- dependencies for annotations provided by the container/application 
			server -->
		<dependency>
			<groupId>javax.enterprise</groupId>
			<artifactId>cdi-api</artifactId>
			<version>1.2</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>javax.ws.rs</groupId>
			<artifactId>javax.ws.rs-api</artifactId>
			<version>2.0.1</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>javax.inject</groupId>
			<artifactId>javax.inject</artifactId>
			<version>1</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>javax.annotation</groupId>
			<artifactId>javax.annotation-api</artifactId>
			<version>1.2</version>
			<scope>provided</scope>
		</dependency>

		<!-- dependencies accounting for java12 removal of javax.activation and jaxb -->
		<dependency>
		    <groupId>javax.activation</groupId>
		    <artifactId>javax.activation-api</artifactId>
		    <version>1.2.0</version>
		</dependency>
		<dependency>
		    <groupId>javax.xml.bind</groupId>
		    <artifactId>jaxb-api</artifactId>
		    <version>2.3.1</version>
		</dependency>
		<dependency>
		    <groupId>com.sun.xml.bind</groupId>
		    <artifactId>jaxb-impl</artifactId>
		    <version>2.3.2</version>
		</dependency>
		<dependency>
		    <groupId>com.sun.xml.bind</groupId>
		    <artifactId>jaxb-core</artifactId>
		    <version>2.3.0.1</version>
		</dependency>

		<!-- test dependencies to run a server for testing -->
		<dependency>
			<groupId>org.eclipse.jetty</groupId>
			<artifactId>jetty-server</artifactId>
			<version>9.4.26.v20200117</version>
			<!-- <scope>test</scope> -->
		</dependency>
		<dependency>
			<groupId>org.eclipse.jetty</groupId>
			<artifactId>jetty-servlet</artifactId>
			<version>9.4.26.v20200117</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.eclipse.jetty</groupId>
			<artifactId>jetty-util</artifactId>
			<version>9.4.26.v20200117</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.glassfish.jersey.core</groupId>
			<artifactId>jersey-server</artifactId>
			<version>2.30</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.glassfish.jersey.containers</groupId>
			<artifactId>jersey-container-servlet-core</artifactId>
			<version>2.30.1</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.glassfish.jersey.inject</groupId>
			<artifactId>jersey-hk2</artifactId>
			<version>2.30.1</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.glassfish.jersey.containers</groupId>
			<artifactId>jersey-container-jetty-http</artifactId>
			<version>2.30.1</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.glassfish.jersey.ext.cdi</groupId>
			<artifactId>jersey-cdi1x-servlet</artifactId>
			<version>2.30.1</version>
			<scope>test</scope>
		</dependency>

		<dependency>
		    <groupId>org.xmlunit</groupId>
		    <artifactId>xmlunit-core</artifactId>
		    <version>2.6.3</version>
		    <scope>test</scope>
		</dependency>
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<scope>test</scope>
		</dependency>
		
	</dependencies>
</project>