| 1 |
<?xml version="1.0" encoding="UTF-8"?> |
| 2 |
<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/maven-v4_0_0.xsd"> |
| 3 |
<modelVersion>4.0.0</modelVersion> |
| 4 |
<parent> |
| 5 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 6 |
<artifactId>jetty-ee10-demos</artifactId> |
| 7 |
<version>12.0.33</version> |
| 8 |
<relativePath>../../pom.xml</relativePath> |
| 9 |
</parent> |
| 10 |
<artifactId>jetty-ee10-demo-spec-webapp</artifactId> |
| 11 |
<packaging>war</packaging> |
| 12 |
<name>EE10 :: Demo :: Servlet Spec :: WebApp</name> |
| 13 |
<properties> |
| 14 |
<bundle-symbolic-name>${project.groupId}.spec.webapp</bundle-symbolic-name> |
| 15 |
</properties> |
| 16 |
|
| 17 |
<dependencies> |
| 18 |
<dependency> |
| 19 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 20 |
<artifactId>jetty-ee10-demo-container-initializer</artifactId> |
| 21 |
</dependency> |
| 22 |
<dependency> |
| 23 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 24 |
<artifactId>jetty-ee10-demo-web-fragment</artifactId> |
| 25 |
</dependency> |
| 26 |
<dependency> |
| 27 |
<groupId>jakarta.annotation</groupId> |
| 28 |
<artifactId>jakarta.annotation-api</artifactId> |
| 29 |
<scope>provided</scope> |
| 30 |
</dependency> |
| 31 |
<dependency> |
| 32 |
<groupId>jakarta.servlet</groupId> |
| 33 |
<artifactId>jakarta.servlet-api</artifactId> |
| 34 |
<scope>provided</scope> |
| 35 |
</dependency> |
| 36 |
<dependency> |
| 37 |
<groupId>jakarta.transaction</groupId> |
| 38 |
<artifactId>jakarta.transaction-api</artifactId> |
| 39 |
<scope>provided</scope> |
| 40 |
</dependency> |
| 41 |
<dependency> |
| 42 |
<groupId>org.eclipse.jetty</groupId> |
| 43 |
<artifactId>jetty-client</artifactId> |
| 44 |
<scope>test</scope> |
| 45 |
</dependency> |
| 46 |
<dependency> |
| 47 |
<groupId>org.eclipse.jetty</groupId> |
| 48 |
<artifactId>jetty-slf4j-impl</artifactId> |
| 49 |
<scope>test</scope> |
| 50 |
</dependency> |
| 51 |
<dependency> |
| 52 |
<groupId>org.eclipse.jetty.ee10</groupId> |
| 53 |
<artifactId>jetty-ee10-annotations</artifactId> |
| 54 |
<scope>test</scope> |
| 55 |
</dependency> |
| 56 |
<dependency> |
| 57 |
<groupId>org.eclipse.jetty.ee10</groupId> |
| 58 |
<artifactId>jetty-ee10-webapp</artifactId> |
| 59 |
<scope>test</scope> |
| 60 |
</dependency> |
| 61 |
<dependency> |
| 62 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 63 |
<artifactId>jetty-ee10-demo-mock-resources</artifactId> |
| 64 |
<scope>test</scope> |
| 65 |
</dependency> |
| 66 |
</dependencies> |
| 67 |
<build> |
| 68 |
<pluginManagement> |
| 69 |
<plugins> |
| 70 |
<plugin> |
| 71 |
<groupId>org.eclipse.jetty.ee10</groupId> |
| 72 |
<artifactId>jetty-ee10-maven-plugin</artifactId> |
| 73 |
<version>${project.version}</version> |
| 74 |
<configuration> |
| 75 |
<scan>10</scan> |
| 76 |
<contextXml>src/main/templates/plugin-context.xml</contextXml> |
| 77 |
<webApp> |
| 78 |
<war>src/main/webapp</war> |
| 79 |
<descriptor>src/main/webapp/WEB-INF/web.xml</descriptor> |
| 80 |
<contextPath>/test-spec</contextPath> |
| 81 |
<containerIncludeJarPattern>.*/jakarta.servlet-api-[^/]*\.jar$</containerIncludeJarPattern> |
| 82 |
<configurationDiscovered>true</configurationDiscovered> |
| 83 |
<jettyEnvXml>${basedir}/src/main/webapp/WEB-INF/jetty-env.xml</jettyEnvXml> |
| 84 |
</webApp> |
| 85 |
<loginServices> |
| 86 |
<loginService implementation="org.eclipse.jetty.security.HashLoginService"> |
| 87 |
<name>Test Realm</name> |
| 88 |
<config implementation="org.eclipse.jetty.maven.MavenResource"> |
| 89 |
<resourceAsString>src/etc/realm.properties</resourceAsString> |
| 90 |
</config> |
| 91 |
</loginService> |
| 92 |
</loginServices> |
| 93 |
</configuration> |
| 94 |
<dependencies> |
| 95 |
<dependency> |
| 96 |
<groupId>org.eclipse.jetty.ee10</groupId> |
| 97 |
<artifactId>jetty-ee10-jndi</artifactId> |
| 98 |
<version>${project.version}</version> |
| 99 |
</dependency> |
| 100 |
<dependency> |
| 101 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 102 |
<artifactId>jetty-ee10-demo-mock-resources</artifactId> |
| 103 |
<version>${project.version}</version> |
| 104 |
</dependency> |
| 105 |
</dependencies> |
| 106 |
</plugin> |
| 107 |
</plugins> |
| 108 |
</pluginManagement> |
| 109 |
<plugins> |
| 110 |
|
| 111 |
<plugin> |
| 112 |
<groupId>org.apache.felix</groupId> |
| 113 |
<artifactId>maven-bundle-plugin</artifactId> |
| 114 |
<extensions>true</extensions> |
| 115 |
<configuration> |
| 116 |
<supportedProjectTypes> |
| 117 |
<supportedProjectType>war</supportedProjectType> |
| 118 |
</supportedProjectTypes> |
| 119 |
<instructions> |
| 120 |
<Bundle-Description>Test Webapp for Servlet 6.0 Features</Bundle-Description> |
| 121 |
<Import-Package>jakarta.transaction*;version="2.0.0", jakarta.servlet*;version="[6,7)", org.eclipse.jetty*;version="[$(version;===;${parsedVersion.osgiVersion}),$(version;==+;${parsedVersion.osgiVersion}))", org.eclipse.jetty.webapp;version="[$(version;===;${parsedVersion.osgiVersion}),$(version;==+;${parsedVersion.osgiVersion}))";resolution:="optional", org.eclipse.jetty.plus.jndi;version="[$(version;===;${parsedVersion.osgiVersion}),$(version;==+;${parsedVersion.osgiVersion}))";resolution:="optional", org.example;version="${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}", *</Import-Package> |
| 122 |
<_nouses/> |
| 123 |
<Export-Package>org.example.test;version="${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}";-noimport:=true</Export-Package> |
| 124 |
<Web-ContextPath>/ee10-demo-spec</Web-ContextPath> |
| 125 |
<Bundle-ClassPath>.,WEB-INF/classes,WEB-INF/lib</Bundle-ClassPath> |
| 126 |
<Jetty-ContextFilePath>META-INF/plugin-context.xml</Jetty-ContextFilePath> |
| 127 |
<Jetty-Environment>ee10</Jetty-Environment> |
| 128 |
</instructions> |
| 129 |
</configuration> |
| 130 |
</plugin> |
| 131 |
|
| 132 |
<plugin> |
| 133 |
<groupId>org.apache.maven.plugins</groupId> |
| 134 |
<artifactId>maven-assembly-plugin</artifactId> |
| 135 |
<executions> |
| 136 |
<execution> |
| 137 |
<id>web-bundle-assembly</id> |
| 138 |
<goals> |
| 139 |
<goal>single</goal> |
| 140 |
</goals> |
| 141 |
<phase>package</phase> |
| 142 |
<configuration> |
| 143 |
<descriptors> |
| 144 |
<descriptor>src/main/assembly/web-bundle.xml</descriptor> |
| 145 |
</descriptors> |
| 146 |
<archive> |
| 147 |
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile> |
| 148 |
</archive> |
| 149 |
</configuration> |
| 150 |
</execution> |
| 151 |
</executions> |
| 152 |
</plugin> |
| 153 |
<plugin> |
| 154 |
<groupId>org.apache.maven.plugins</groupId> |
| 155 |
<artifactId>maven-dependency-plugin</artifactId> |
| 156 |
<executions> |
| 157 |
<execution> |
| 158 |
<id>unpack-jetty-ee10-demo-container-initializer</id> |
| 159 |
<goals> |
| 160 |
<goal>copy</goal> |
| 161 |
</goals> |
| 162 |
<phase>process-test-resources</phase> |
| 163 |
<configuration> |
| 164 |
<artifactItems> |
| 165 |
<artifactItem> |
| 166 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 167 |
<artifactId>jetty-ee10-demo-container-initializer</artifactId> |
| 168 |
<type>jar</type> |
| 169 |
<overWrite>false</overWrite> |
| 170 |
<outputDirectory>${project.build.directory}/</outputDirectory> |
| 171 |
<destFileName>jetty-ee10-demo-container-initializer.jar</destFileName> |
| 172 |
</artifactItem> |
| 173 |
</artifactItems> |
| 174 |
<overWriteSnapshots>true</overWriteSnapshots> |
| 175 |
</configuration> |
| 176 |
</execution> |
| 177 |
<execution> |
| 178 |
<id>unpack-jetty-ee10-demo-web-fragment</id> |
| 179 |
<goals> |
| 180 |
<goal>copy</goal> |
| 181 |
</goals> |
| 182 |
<phase>process-test-resources</phase> |
| 183 |
<configuration> |
| 184 |
<artifactItems> |
| 185 |
<artifactItem> |
| 186 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 187 |
<artifactId>jetty-ee10-demo-web-fragment</artifactId> |
| 188 |
<type>jar</type> |
| 189 |
<overWrite>false</overWrite> |
| 190 |
<outputDirectory>${project.build.directory}/</outputDirectory> |
| 191 |
<destFileName>jetty-ee10-demo-web-fragment.jar</destFileName> |
| 192 |
</artifactItem> |
| 193 |
</artifactItems> |
| 194 |
<overWriteSnapshots>true</overWriteSnapshots> |
| 195 |
</configuration> |
| 196 |
</execution> |
| 197 |
<execution> |
| 198 |
<goals> |
| 199 |
<goal>copy</goal> |
| 200 |
</goals> |
| 201 |
<phase>package</phase> |
| 202 |
<configuration> |
| 203 |
<artifactItems> |
| 204 |
<artifactItem> |
| 205 |
<groupId>org.eclipse.jetty.ee10.demos</groupId> |
| 206 |
<artifactId>jetty-ee10-demo-mock-resources</artifactId> |
| 207 |
<version>${project.version}</version> |
| 208 |
<type>jar</type> |
| 209 |
<includes>**</includes> |
| 210 |
<overWrite>true</overWrite> |
| 211 |
<outputDirectory>${project.build.directory}/lib/jndi</outputDirectory> |
| 212 |
</artifactItem> |
| 213 |
</artifactItems> |
| 214 |
</configuration> |
| 215 |
</execution> |
| 216 |
</executions> |
| 217 |
</plugin> |
| 218 |
<plugin> |
| 219 |
<groupId>org.apache.maven.plugins</groupId> |
| 220 |
<artifactId>maven-enforcer-plugin</artifactId> |
| 221 |
<executions> |
| 222 |
<execution> |
| 223 |
<id>enforce-java</id> |
| 224 |
<goals> |
| 225 |
<goal>enforce</goal> |
| 226 |
</goals> |
| 227 |
<configuration> |
| 228 |
<rules> |
| 229 |
<requireUpperBoundDeps> |
| 230 |
<excludes combine.children="append"> |
| 231 |
<exclude>org.eclipse.jetty:jetty-util</exclude> |
| 232 |
</excludes> |
| 233 |
</requireUpperBoundDeps> |
| 234 |
</rules> |
| 235 |
</configuration> |
| 236 |
</execution> |
| 237 |
</executions> |
| 238 |
</plugin> |
| 239 |
<!-- also make this webapp an osgi bundle --> |
| 240 |
<plugin> |
| 241 |
<artifactId>maven-war-plugin</artifactId> |
| 242 |
<configuration> |
| 243 |
<archive> |
| 244 |
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile> |
| 245 |
</archive> |
| 246 |
<webResources> |
| 247 |
<resource> |
| 248 |
<directory>target</directory> |
| 249 |
<includes> |
| 250 |
<include>plugin-context.xml</include> |
| 251 |
</includes> |
| 252 |
<targetPath>META-INF</targetPath> |
| 253 |
</resource> |
| 254 |
</webResources> |
| 255 |
</configuration> |
| 256 |
</plugin> |
| 257 |
</plugins> |
| 258 |
</build> |
| 259 |
</project> |