Skip to content

Commit

Permalink
Issue eclipse-ee4j#2016 Possibility to run tests with different JSSE …
Browse files Browse the repository at this point in the history
…implementations

- default is none (uses JDK's impl)
- profile npn uses grizzly-npn-bootstrap
- profile openjsse uses openjsse
- versions can be overriden from command line (to compare results)

Signed-off-by: David Matějček <dmatej@seznam.cz>
  • Loading branch information
dmatej committed Nov 20, 2020
1 parent 787c99a commit 0a0b242
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 14 deletions.
3 changes: 1 addition & 2 deletions modules/bundles/http/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -52,14 +52,13 @@
<dependency>
<groupId>org.glassfish.grizzly</groupId>
<artifactId>grizzly-npn-api</artifactId>
<version>${grizzly.alpn.version}</version>
<version>${grizzly.npn.api.version}</version>
</dependency>
<dependency>
<groupId>org.glassfish.grizzly</groupId>
<artifactId>grizzly-http-server-multipart</artifactId>
</dependency>
</dependencies>

<build>
<defaultGoal>install</defaultGoal>
<plugins>
Expand Down
44 changes: 38 additions & 6 deletions modules/http2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@
<artifactId>grizzly-http2</artifactId>

<name>grizzly-http2</name>
<properties>
<bootClasspath></bootClasspath>
</properties>

<dependencies>
<dependency>
Expand All @@ -39,18 +42,17 @@
<dependency>
<groupId>org.glassfish.grizzly</groupId>
<artifactId>grizzly-http-server</artifactId>
<!-- These dependencies aren't needed in the client case. Only if the project is using the Http2Addon or the
<!-- These dependencies aren't needed in the client case. Only if the project is using the Http2Addon or the
GlassFish integration code -->
<scope>provided</scope>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.glassfish.grizzly</groupId>
<artifactId>grizzly-npn-api</artifactId>
<version>${grizzly.alpn.version}</version>
<version>${grizzly.npn.api.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
Expand Down Expand Up @@ -107,9 +109,7 @@
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<argLine>
-XX:+HeapDumpOnOutOfMemoryError
</argLine>
<argLine>-XX:+HeapDumpOnOutOfMemoryError ${bootClasspath}</argLine>
</configuration>
</plugin>
</plugins>
Expand All @@ -126,4 +126,36 @@
</plugin>
</plugins>
</reporting>

<profiles>
<!-- Compatibility tests with other implementations of ALPN. New JDK implementations have their own. -->
<profile>
<id>openjsse</id>
<properties>
<bootClasspath>-Xbootclasspath/p:${settings.localRepository}/org/openjsse/openjsse/${openjsse.version}/openjsse-${openjsse.version}.jar</bootClasspath>
</properties>
<dependencies>
<dependency>
<groupId>org.openjsse</groupId>
<artifactId>openjsse</artifactId>
<version>${openjsse.version}</version>
<scope>provided</scope>
</dependency>
</dependencies>
</profile>
<profile>
<id>npn</id>
<properties>
<bootClasspath>-Xbootclasspath/p:${settings.localRepository}/org/glassfish/grizzly/grizzly-npn-bootstrap/${grizzly.npn.bootstrap.version}/grizzly-npn-bootstrap-${grizzly.npn.bootstrap.version}.jar</bootClasspath>
</properties>
<dependencies>
<dependency>
<groupId>org.glassfish.grizzly</groupId>
<artifactId>grizzly-npn-api</artifactId>
<version>${grizzly.npn.bootstrap.version}</version>
<scope>provided</scope>
</dependency>
</dependencies>
</profile>
</profiles>
</project>
14 changes: 8 additions & 6 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,10 @@
<felix-version>4.2.1</felix-version>
<cobertura.version>2.4</cobertura.version>
<gmbal.version>4.0.0</gmbal.version>
<grizzly.npn.api.version>1.9</grizzly.npn.api.version>
<grizzly.npn.bootstrap.version>1.9</grizzly.npn.bootstrap.version>
<openjsse.version>1.1.4</openjsse.version>
<osgi.version>4.2.0</osgi.version>
<grizzly.alpn.version>1.9</grizzly.alpn.version>
<release.arguments></release.arguments>
</properties>

Expand Down Expand Up @@ -218,7 +220,7 @@
</execution>
</executions>
</plugin>

<!-- Restricts the Java version to 1.8 -->
<plugin>
<inherited>true</inherited>
Expand All @@ -230,7 +232,7 @@
<compilerArgument>-Xlint:unchecked,deprecation,fallthrough,finally,cast,dep-ann,empty,overrides</compilerArgument>
</configuration>
</plugin>

<plugin><inherited>true</inherited>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
Expand All @@ -246,7 +248,7 @@
</archive>
</configuration>
</plugin>

<plugin><inherited>true</inherited>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
Expand All @@ -259,7 +261,7 @@
</execution>
</executions>
</plugin>

<!-- Configure the jar with the javadoc -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Expand All @@ -271,7 +273,7 @@
<doctitle>${project.name} ${project.version}</doctitle>
</configuration>
</plugin>

<plugin>
<groupId>org.glassfish.copyright</groupId>
<artifactId>glassfish-copyright-maven-plugin</artifactId>
Expand Down

0 comments on commit 0a0b242

Please sign in to comment.