Skip to content

Commit

Permalink
Port to Jetty 12
Browse files Browse the repository at this point in the history
  • Loading branch information
akurtakov committed Oct 11, 2023
1 parent 1c48d5a commit bd0524c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions tycho-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<name>Tycho Core</name>
<description>Core Tycho components</description>
<properties>
<jetty.version>11.0.17</jetty.version>
<jetty.version>12.0.2</jetty.version>
</properties>

<build>
Expand Down Expand Up @@ -306,8 +306,8 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-servlet</artifactId>
<groupId>org.eclipse.jetty.ee10</groupId>
<artifactId>jetty-ee10-servlet</artifactId>
<version>${jetty.version}</version>
<scope>test</scope>
</dependency>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2008, 2013 Sonatype Inc. and others.
* Copyright (c) 2008, 2023 Sonatype Inc. and others.
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
* which accompanies this distribution, and is available at
Expand All @@ -22,10 +22,10 @@
import java.util.Random;
import java.util.concurrent.TimeUnit;

import org.eclipse.jetty.ee10.servlet.ServletContextHandler;
import org.eclipse.jetty.ee10.servlet.ServletHolder;
import org.eclipse.jetty.server.Server;
import org.eclipse.jetty.server.ServerConnector;
import org.eclipse.jetty.servlet.ServletContextHandler;
import org.eclipse.jetty.servlet.ServletHolder;
import org.junit.rules.ExternalResource;

public class HttpServer extends ExternalResource {
Expand Down Expand Up @@ -97,8 +97,8 @@ private static RunningServer startServerOnPort(int port) throws Exception {
connector.setPort(port);
jetty.addConnector(connector);

ServletContextHandler context;
context = new ServletContextHandler(jetty, "/", 0);
ServletContextHandler context = new ServletContextHandler("/", 0);
jetty.setHandler(context);
jetty.start();

return new RunningServer(port, jetty, context);
Expand Down

0 comments on commit bd0524c

Please sign in to comment.