Add jdk12 build in Jenkinsfile (#3376)
* add jdk12 build stage * test last release of infinispan for jdk12 build * fix upperBound dependency for jboss logging * upgrade juniper to 5.4.0 and disable infinispan test if JRE.JAVA_12 * Fixed annotations to exclude any JDK > 11 for 3 tests. Signed-off-by: olivier lamy <oliver.lamy@gmail.com> Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
This commit is contained in:
parent
ea3339d395
commit
c3719b2bab
|
@ -50,6 +50,16 @@ pipeline {
|
|||
}
|
||||
}
|
||||
|
||||
stage("Build / Test - JDK12") {
|
||||
agent { node { label 'linux' } }
|
||||
options { timeout(time: 120, unit: 'MINUTES') }
|
||||
steps {
|
||||
mavenBuild("jdk12", "-Pmongodb install", "maven3", false)
|
||||
warnings consoleParsers: [[parserName: 'Maven'], [parserName: 'Java']]
|
||||
maven_invoker reportsFilenamePattern: "**/target/invoker-reports/BUILD*.xml", invokerBuildDir: "**/target/it"
|
||||
}
|
||||
}
|
||||
|
||||
stage("Build Javadoc") {
|
||||
agent { node { label 'linux' } }
|
||||
options { timeout(time: 30, unit: 'MINUTES') }
|
||||
|
|
|
@ -50,7 +50,7 @@ import org.eclipse.jetty.util.thread.ExecutorThreadPool;
|
|||
import org.eclipse.jetty.util.thread.QueuedThreadPool;
|
||||
import org.junit.jupiter.api.AfterEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.junit.jupiter.api.condition.DisabledOnJre;
|
||||
import org.junit.jupiter.api.condition.EnabledOnJre;
|
||||
import org.junit.jupiter.api.condition.JRE;
|
||||
|
||||
import static org.hamcrest.MatcherAssert.assertThat;
|
||||
|
@ -139,12 +139,10 @@ public class HttpClientTLSTest
|
|||
});
|
||||
|
||||
assertThrows(ExecutionException.class, () ->
|
||||
{
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send();
|
||||
});
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send());
|
||||
|
||||
assertTrue(serverLatch.await(1, TimeUnit.SECONDS));
|
||||
assertTrue(clientLatch.await(1, TimeUnit.SECONDS));
|
||||
|
@ -182,12 +180,10 @@ public class HttpClientTLSTest
|
|||
});
|
||||
|
||||
assertThrows(ExecutionException.class, () ->
|
||||
{
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send();
|
||||
});
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send());
|
||||
|
||||
assertTrue(serverLatch.await(1, TimeUnit.SECONDS));
|
||||
assertTrue(clientLatch.await(1, TimeUnit.SECONDS));
|
||||
|
@ -226,24 +222,21 @@ public class HttpClientTLSTest
|
|||
});
|
||||
|
||||
assertThrows(ExecutionException.class, () ->
|
||||
{
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send();
|
||||
});
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send());
|
||||
|
||||
assertTrue(serverLatch.await(1, TimeUnit.SECONDS));
|
||||
assertTrue(clientLatch.await(1, TimeUnit.SECONDS));
|
||||
}
|
||||
|
||||
// In JDK 11, a mismatch on the client does not generate any bytes towards
|
||||
// the server, while in TLS 1.2 the client sends to the server the close_notify.
|
||||
@DisabledOnJre(JRE.JAVA_11)
|
||||
// In JDK 11+, a mismatch on the client does not generate any bytes towards
|
||||
// the server, while in previous JDKs the client sends to the server the close_notify.
|
||||
@EnabledOnJre({JRE.JAVA_8, JRE.JAVA_9, JRE.JAVA_10})
|
||||
@Test
|
||||
public void testMismatchBetweenTLSProtocolAndTLSCiphersOnClient() throws Exception
|
||||
{
|
||||
|
||||
SslContextFactory serverTLSFactory = createSslContextFactory();
|
||||
startServer(serverTLSFactory, new EmptyServerHandler());
|
||||
|
||||
|
@ -274,12 +267,10 @@ public class HttpClientTLSTest
|
|||
});
|
||||
|
||||
assertThrows(ExecutionException.class, () ->
|
||||
{
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send();
|
||||
});
|
||||
client.newRequest("localhost", connector.getLocalPort())
|
||||
.scheme(HttpScheme.HTTPS.asString())
|
||||
.timeout(5, TimeUnit.SECONDS)
|
||||
.send());
|
||||
|
||||
assertTrue(serverLatch.await(1, TimeUnit.SECONDS));
|
||||
assertTrue(clientLatch.await(1, TimeUnit.SECONDS));
|
||||
|
@ -321,8 +312,9 @@ public class HttpClientTLSTest
|
|||
assertTrue(clientLatch.await(1, TimeUnit.SECONDS));
|
||||
}
|
||||
|
||||
// Excluded because of a bug in JDK 11+27 where session resumption does not work.
|
||||
@DisabledOnJre(JRE.JAVA_11)
|
||||
// Excluded in JDK 11+ because resumed sessions cannot be compared
|
||||
// using their session IDs even though they are resumed correctly.
|
||||
@EnabledOnJre({JRE.JAVA_8, JRE.JAVA_9, JRE.JAVA_10})
|
||||
@Test
|
||||
public void testHandshakeSucceededWithSessionResumption() throws Exception
|
||||
{
|
||||
|
@ -400,8 +392,9 @@ public class HttpClientTLSTest
|
|||
assertTrue(clientLatch.await(1, TimeUnit.SECONDS));
|
||||
}
|
||||
|
||||
// Excluded because of a bug in JDK 11+27 where session resumption does not work.
|
||||
@DisabledOnJre(JRE.JAVA_11)
|
||||
// Excluded in JDK 11+ because resumed sessions cannot be compared
|
||||
// using their session IDs even though they are resumed correctly.
|
||||
@EnabledOnJre({JRE.JAVA_8, JRE.JAVA_9, JRE.JAVA_10})
|
||||
@Test
|
||||
public void testClientRawCloseDoesNotInvalidateSession() throws Exception
|
||||
{
|
||||
|
|
|
@ -651,7 +651,6 @@
|
|||
<dependency>
|
||||
<groupId>org.jboss.logging</groupId>
|
||||
<artifactId>jboss-logging</artifactId>
|
||||
<version>3.3.0.Final</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.eclipse.jetty.cdi</groupId>
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<url>http://www.eclipse.org/jetty</url>
|
||||
<properties>
|
||||
<bundle-symbolic-name>${project.groupId}.infinispan</bundle-symbolic-name>
|
||||
<infinispan.version>9.1.0.Final</infinispan.version>
|
||||
<infinispan.version>9.4.8.Final</infinispan.version>
|
||||
</properties>
|
||||
<build>
|
||||
<defaultGoal>install</defaultGoal>
|
||||
|
@ -36,19 +36,23 @@
|
|||
</build>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.infinispan</groupId>
|
||||
<artifactId>infinispan-core</artifactId>
|
||||
<version>${infinispan.version}</version>
|
||||
<groupId>org.infinispan</groupId>
|
||||
<artifactId>infinispan-core</artifactId>
|
||||
<version>${infinispan.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.infinispan.protostream</groupId>
|
||||
<artifactId>protostream</artifactId>
|
||||
<version>4.1.0.Final</version>
|
||||
<groupId>org.infinispan.protostream</groupId>
|
||||
<artifactId>protostream</artifactId>
|
||||
<version>4.2.2.Final</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.eclipse.jetty</groupId>
|
||||
<artifactId>jetty-server</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<groupId>org.eclipse.jetty</groupId>
|
||||
<artifactId>jetty-server</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jboss.logging</groupId>
|
||||
<artifactId>jboss-logging</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.infinispan</groupId>
|
||||
|
|
|
@ -152,19 +152,19 @@ public class LazyListTest
|
|||
Object list=null;
|
||||
list=LazyList.add(list, null);
|
||||
assertEquals(1,LazyList.size(list));
|
||||
assertEquals(null,LazyList.get(list,0));
|
||||
assertNull(LazyList.get(list,0));
|
||||
|
||||
list="a";
|
||||
list=LazyList.add(list, null);
|
||||
assertEquals(2,LazyList.size(list));
|
||||
assertEquals(LazyList.get(list, 0), "a");
|
||||
assertEquals(null,LazyList.get(list,1));
|
||||
assertNull(LazyList.get(list,1));
|
||||
|
||||
list=LazyList.add(list, null);
|
||||
assertEquals(3,LazyList.size(list));
|
||||
assertEquals(LazyList.get(list, 0), "a");
|
||||
assertEquals(null,LazyList.get(list,1));
|
||||
assertEquals(null,LazyList.get(list,2));
|
||||
assertNull(LazyList.get(list,1));
|
||||
assertNull(LazyList.get(list,2));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -254,7 +254,7 @@ public class LazyListTest
|
|||
Object list = LazyList.add(input, 0, null);
|
||||
assertNotNull(list);
|
||||
assertEquals(2,LazyList.size(list));
|
||||
assertEquals(null, LazyList.get(list,0));
|
||||
assertNull( LazyList.get(list,0));
|
||||
assertEquals(LazyList.get(list, 1), "a");
|
||||
}
|
||||
|
||||
|
|
7
pom.xml
7
pom.xml
|
@ -33,7 +33,7 @@
|
|||
<jmhjar.name>benchmarks</jmhjar.name>
|
||||
<tycho-version>1.2.0</tycho-version>
|
||||
<cbi-plugins.version>1.1.5</cbi-plugins.version>
|
||||
<junit.version>5.3.1</junit.version>
|
||||
<junit.version>5.4.0</junit.version>
|
||||
<maven.version>3.6.0</maven.version>
|
||||
<maven.resolver.version>1.3.1</maven.resolver.version>
|
||||
<javax.servlet.api.version>3.1.0</javax.servlet.api.version>
|
||||
|
@ -1042,6 +1042,11 @@
|
|||
<artifactId>slf4j-simple</artifactId>
|
||||
<version>${slf4j.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jboss.logging</groupId>
|
||||
<artifactId>jboss-logging</artifactId>
|
||||
<version>3.3.2.Final</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.github.jnr</groupId>
|
||||
<artifactId>jnr-unixsocket</artifactId>
|
||||
|
|
|
@ -22,6 +22,8 @@ package org.eclipse.jetty.server.session;
|
|||
import org.eclipse.jetty.session.infinispan.InfinispanSessionDataStoreFactory;
|
||||
import org.junit.jupiter.api.AfterAll;
|
||||
import org.junit.jupiter.api.BeforeAll;
|
||||
import org.junit.jupiter.api.condition.DisabledOnJre;
|
||||
import org.junit.jupiter.api.condition.JRE;
|
||||
|
||||
/**
|
||||
* ClusteredSessionScavengingTest
|
||||
|
@ -52,6 +54,7 @@ public class ClusteredSessionScavengingTest extends AbstractClusteredSessionScav
|
|||
* @see org.eclipse.jetty.server.session.AbstractTestBase#createSessionDataStoreFactory()
|
||||
*/
|
||||
@Override
|
||||
@DisabledOnJre( JRE.JAVA_12 )
|
||||
public SessionDataStoreFactory createSessionDataStoreFactory()
|
||||
{
|
||||
InfinispanSessionDataStoreFactory factory = new InfinispanSessionDataStoreFactory();
|
||||
|
|
Loading…
Reference in New Issue