Merge remote-tracking branch 'origin/jetty-10.0.x' into jetty-10.0.x-7635-QpackDecoderMaxBlockedStreams
This commit is contained in:
commit
58fadffeb7
|
@ -11,6 +11,7 @@
|
|||
|
||||
<properties>
|
||||
<bundle-symbolic-name>${project.groupId}.apache-jsp</bundle-symbolic-name>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
</properties>
|
||||
|
||||
<build>
|
||||
|
@ -52,13 +53,6 @@
|
|||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
<packaging>jar</packaging>
|
||||
<properties>
|
||||
<bundle-symbolic-name>${project.groupId}.apache.jstl</bundle-symbolic-name>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
</properties>
|
||||
|
||||
<build>
|
||||
|
@ -22,13 +23,6 @@
|
|||
<useSystemClassLoader>false</useSystemClassLoader>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
|
||||
<properties>
|
||||
<bundle-symbolic-name>${project.groupId}.ant</bundle-symbolic-name>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
</properties>
|
||||
<build>
|
||||
<plugins>
|
||||
|
@ -48,13 +49,6 @@
|
|||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
<dependencies>
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
<name>Jetty :: GCloud</name>
|
||||
|
||||
<properties>
|
||||
<gcloud.version>2.2.4</gcloud.version>
|
||||
<gcloud.version>2.2.9</gcloud.version>
|
||||
</properties>
|
||||
|
||||
<modules>
|
||||
|
|
|
@ -136,9 +136,9 @@ started()
|
|||
for ((T = 0; T < $(($3 / 4)); T++))
|
||||
do
|
||||
sleep 4
|
||||
[ -z "$(grep STARTED $1 2>/dev/null)" ] || return 0
|
||||
[ -z "$(grep STOPPED $1 2>/dev/null)" ] || return 1
|
||||
[ -z "$(grep FAILED $1 2>/dev/null)" ] || return 1
|
||||
[ -z "$(tail -1 $1 | grep STARTED 2>/dev/null)" ] || return 0
|
||||
[ -z "$(tail -1 $1 | grep STOPPED 2>/dev/null)" ] || return 1
|
||||
[ -z "$(tail -1 $1 | grep FAILED 2>/dev/null)" ] || return 1
|
||||
local PID=$(cat "$2" 2>/dev/null) || return 1
|
||||
kill -0 "$PID" 2>/dev/null || return 1
|
||||
echo -n ". "
|
||||
|
|
|
@ -1,46 +0,0 @@
|
|||
# DO NOT EDIT - See: https://www.eclipse.org/jetty/documentation/current/startup-modules.html
|
||||
|
||||
[description]
|
||||
Deploys the Jminix JMX Console within the server.
|
||||
|
||||
[tags]
|
||||
3rdparty
|
||||
|
||||
[depend]
|
||||
stats
|
||||
jmx
|
||||
commons-logging
|
||||
|
||||
[xml]
|
||||
etc/jminix.xml
|
||||
|
||||
[files]
|
||||
lib/jminix/
|
||||
maven://org.jminix/jminix/1.1.0|lib/jminix/jminix-1.1.0.jar
|
||||
https://maven.restlet.talend.com/org/restlet/org.restlet/1.1.5/org.restlet-1.1.5.jar|lib/jminix/org.restlet-1.1.5.jar
|
||||
https://maven.restlet.talend.com/org/restlet/org.restlet.ext.velocity/1.1.5/org.restlet.ext.velocity-1.1.5.jar|lib/jminix/org.restlet.ext.velocity-1.1.5.jar
|
||||
maven://org.apache.velocity/velocity/1.5|lib/jminix/velocity-1.5.jar
|
||||
maven://oro/oro/2.0.8|lib/jminix/oro-2.0.8.jar
|
||||
https://maven.restlet.talend.com/com/noelios/restlet/com.noelios.restlet/1.1.5/com.noelios.restlet-1.1.5.jar|lib/jminix/com.noelios.restlet-1.1.5.jar
|
||||
https://maven.restlet.talend.com/com/noelios/restlet/com.noelios.restlet.ext.servlet/1.1.5/com.noelios.restlet.ext.servlet-1.1.5.jar|lib/jminix/com.noelios.restlet.ext.servlet-1.1.5.jar
|
||||
maven://net.sf.json-lib/json-lib/2.2.3/jar/jdk15|lib/jminix/json-lib-2.2.3-jdk15.jar
|
||||
maven://commons-lang/commons-lang/2.4|lib/jminix/commons-lang-2.4.jar
|
||||
maven://commons-beanutils/commons-beanutils/1.7.0|lib/jminix/commons-beanutils-1.7.0.jar
|
||||
maven://commons-collections/commons-collections/3.2|lib/jminix/commons-collections-3.2.jar
|
||||
maven://net.sf.ezmorph/ezmorph/1.0.6|lib/jminix/ezmorph-1.0.6.jar
|
||||
maven://org.jgroups/jgroups/2.12.1.3.Final|lib/jminix/jgroups-2.12.1.3.Final.jar
|
||||
maven://org.jasypt/jasypt/1.8|lib/jminix/jasypt-1.8.jar
|
||||
basehome:modules/jminix/jminix.xml|etc/jminix.xml
|
||||
|
||||
[lib]
|
||||
lib/jminix/**.jar
|
||||
|
||||
[license]
|
||||
JMiniX is a hosted at google code and released under the Apache License 2.0
|
||||
https://code.google.com/p/jminix/
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
[ini-template]
|
||||
## Jminix Configuration
|
||||
# jminix.port=8088
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
<?xml version="1.0"?>
|
||||
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "https://www.eclipse.org/jetty/configure_9_3.dtd">
|
||||
|
||||
<Configure id="Server" class="org.eclipse.jetty.server.Server">
|
||||
<Call name="addBean">
|
||||
<Arg>
|
||||
<New class="org.jminix.console.tool.StandaloneMiniConsole">
|
||||
<Arg type="int"><Property name="jminix.port" default="8088" /></Arg>
|
||||
</New>
|
||||
</Arg>
|
||||
</Call>
|
||||
</Configure>
|
|
@ -10,6 +10,7 @@
|
|||
<properties>
|
||||
<bundle-symbolic-name>${project.groupId}.http.spi</bundle-symbolic-name>
|
||||
<spotbugs.onlyAnalyze>org.eclipse.jetty.http.spi.*</spotbugs.onlyAnalyze>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
|
@ -80,13 +81,6 @@
|
|||
</instructions>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
<profiles>
|
||||
|
|
|
@ -11,16 +11,10 @@
|
|||
<name>Jetty :: Jetty JSPC Maven Plugin</name>
|
||||
<properties>
|
||||
<bundle-symbolic-name>${project.groupId}.jspc.plugin</bundle-symbolic-name>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
</properties>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-plugin-plugin</artifactId>
|
||||
|
@ -35,13 +29,6 @@
|
|||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-invoker-plugin</artifactId>
|
||||
|
@ -133,53 +120,4 @@
|
|||
<artifactId>ant</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<reporting>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-project-info-reports-plugin</artifactId>
|
||||
<configuration>
|
||||
<dependencyLocationsEnabled>false</dependencyLocationsEnabled>
|
||||
</configuration>
|
||||
<reportSets>
|
||||
<reportSet>
|
||||
<reports>
|
||||
<report>team</report>
|
||||
<report>mailing-lists</report>
|
||||
<report>ci-management</report>
|
||||
<report>issue-management</report>
|
||||
<report>licenses</report>
|
||||
<report>scm</report>
|
||||
</reports>
|
||||
</reportSet>
|
||||
</reportSets>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-plugin-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</reporting>
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>eclipse-release</id>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-site-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>site-jar</id>
|
||||
<goals>
|
||||
<goal>jar</goal>
|
||||
</goals>
|
||||
<phase>package</phase>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
</profiles>
|
||||
</project>
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
<bundle-symbolic-name>${project.groupId}.maven.plugin</bundle-symbolic-name>
|
||||
<jetty.stopKey>FREEBEER</jetty.stopKey>
|
||||
<jetty.jvmArgs></jetty.jvmArgs>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
</properties>
|
||||
<build>
|
||||
<plugins>
|
||||
|
@ -110,13 +111,6 @@
|
|||
</goals>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
<dependencies>
|
||||
|
@ -373,50 +367,4 @@
|
|||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<reporting>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-project-info-reports-plugin</artifactId>
|
||||
<reportSets>
|
||||
<reportSet>
|
||||
<reports>
|
||||
<report>team</report>
|
||||
<report>mailing-lists</report>
|
||||
<report>ci-management</report>
|
||||
<report>issue-management</report>
|
||||
<report>licenses</report>
|
||||
<report>scm</report>
|
||||
</reports>
|
||||
</reportSet>
|
||||
</reportSets>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-plugin-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</reporting>
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>eclipse-release</id>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-site-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>site-jar</id>
|
||||
<goals>
|
||||
<goal>jar</goal>
|
||||
</goals>
|
||||
<phase>package</phase>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
</profiles>
|
||||
</project>
|
||||
|
|
|
@ -12,10 +12,11 @@
|
|||
<packaging>pom</packaging>
|
||||
|
||||
<properties>
|
||||
<osgi-version>3.17.100</osgi-version>
|
||||
<osgi-version>3.17.200</osgi-version>
|
||||
<osgi-services-version>3.10.200</osgi-services-version>
|
||||
<osgi-util-version>3.6.100</osgi-util-version>
|
||||
<equinox-http-servlet-version>1.0.0-v20070606</equinox-http-servlet-version>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
</properties>
|
||||
|
||||
<modules>
|
||||
|
@ -72,13 +73,6 @@
|
|||
</sourceExcludes>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
<description>Generates a (maven based) P2 Updatesite</description>
|
||||
<packaging>pom</packaging>
|
||||
<properties>
|
||||
<tycho-version>2.6.0</tycho-version>
|
||||
<tycho-version>2.7.0</tycho-version>
|
||||
</properties>
|
||||
<build>
|
||||
<plugins>
|
||||
|
|
|
@ -33,7 +33,7 @@ public class quiche_h
|
|||
{
|
||||
// This interface is a translation of the quiche.h header of a specific version.
|
||||
// It needs to be reviewed each time the native lib version changes.
|
||||
private static final String EXPECTED_QUICHE_VERSION = "0.11.0";
|
||||
private static final String EXPECTED_QUICHE_VERSION = "0.12.0";
|
||||
|
||||
public static final byte C_FALSE = 0;
|
||||
public static final byte C_TRUE = 1;
|
||||
|
|
|
@ -31,7 +31,7 @@ public interface LibQuiche extends Library
|
|||
{
|
||||
// This interface is a translation of the quiche.h header of a specific version.
|
||||
// It needs to be reviewed each time the native lib version changes.
|
||||
String EXPECTED_QUICHE_VERSION = "0.11.0";
|
||||
String EXPECTED_QUICHE_VERSION = "0.12.0";
|
||||
|
||||
// The charset used to convert java.lang.String to char * and vice versa.
|
||||
Charset CHARSET = StandardCharsets.UTF_8;
|
||||
|
|
|
@ -1435,8 +1435,10 @@ public class Request implements HttpServletRequest
|
|||
RequestLog requestLog = httpChannel.getRequestLog();
|
||||
if (requestLog != null)
|
||||
{
|
||||
// Don't allow pulling more parameters
|
||||
// Don't allow pulling more parameters from request body content
|
||||
_contentParamsExtracted = true;
|
||||
if (_contentParameters == null)
|
||||
_contentParameters = NO_PARAMS;
|
||||
|
||||
// Reset the status code to what was committed
|
||||
MetaData.Response committedResponse = getResponse().getCommittedMetaData();
|
||||
|
|
|
@ -342,6 +342,9 @@ public class Response implements HttpServletResponse
|
|||
@Override
|
||||
public String encodeURL(String url)
|
||||
{
|
||||
if (url == null)
|
||||
return null;
|
||||
|
||||
final Request request = _channel.getRequest();
|
||||
SessionHandler sessionManager = request.getSessionHandler();
|
||||
|
||||
|
@ -349,7 +352,8 @@ public class Response implements HttpServletResponse
|
|||
return url;
|
||||
|
||||
HttpURI uri = null;
|
||||
if (sessionManager.isCheckingRemoteSessionIdEncoding() && URIUtil.hasScheme(url))
|
||||
boolean hasScheme = URIUtil.hasScheme(url);
|
||||
if (sessionManager.isCheckingRemoteSessionIdEncoding() && hasScheme)
|
||||
{
|
||||
uri = HttpURI.from(url);
|
||||
String path = uri.getPath();
|
||||
|
@ -371,9 +375,6 @@ public class Response implements HttpServletResponse
|
|||
if (sessionURLPrefix == null)
|
||||
return url;
|
||||
|
||||
if (url == null)
|
||||
return null;
|
||||
|
||||
// should not encode if cookies in evidence
|
||||
if ((sessionManager.isUsingCookies() && request.isRequestedSessionIdFromCookie()) || !sessionManager.isUsingURLs())
|
||||
{
|
||||
|
@ -404,9 +405,6 @@ public class Response implements HttpServletResponse
|
|||
|
||||
String id = sessionManager.getExtendedId(session);
|
||||
|
||||
if (uri == null)
|
||||
uri = HttpURI.from(url);
|
||||
|
||||
// Already encoded
|
||||
int prefix = url.indexOf(sessionURLPrefix);
|
||||
if (prefix != -1)
|
||||
|
@ -421,20 +419,24 @@ public class Response implements HttpServletResponse
|
|||
url.substring(suffix);
|
||||
}
|
||||
|
||||
// check for a null path
|
||||
String nonNullPath = "";
|
||||
if (hasScheme)
|
||||
{
|
||||
if (uri == null)
|
||||
uri = HttpURI.from(url);
|
||||
if (uri.getPath() == null)
|
||||
nonNullPath = "/";
|
||||
}
|
||||
|
||||
// edit the session
|
||||
int suffix = url.indexOf('?');
|
||||
if (suffix < 0)
|
||||
suffix = url.indexOf('#');
|
||||
if (suffix < 0)
|
||||
{
|
||||
return url +
|
||||
((HttpScheme.HTTPS.is(uri.getScheme()) || HttpScheme.HTTP.is(uri.getScheme())) && uri.getPath() == null ? "/" : "") + //if no path, insert the root path
|
||||
sessionURLPrefix + id;
|
||||
}
|
||||
return url + nonNullPath + sessionURLPrefix + id;
|
||||
|
||||
return url.substring(0, suffix) +
|
||||
((HttpScheme.HTTPS.is(uri.getScheme()) || HttpScheme.HTTP.is(uri.getScheme())) && uri.getPath() == null ? "/" : "") + //if no path so insert the root path
|
||||
sessionURLPrefix + id + url.substring(suffix);
|
||||
return url.substring(0, suffix) + nonNullPath + sessionURLPrefix + id + url.substring(suffix);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -86,18 +86,13 @@ public class ServletPathMapping implements HttpServletMapping
|
|||
break;
|
||||
|
||||
case MIDDLE_GLOB:
|
||||
_mappingMatch = null;
|
||||
_matchValue = "";
|
||||
_servletPath = pathInContext;
|
||||
_pathInfo = null;
|
||||
break;
|
||||
|
||||
default:
|
||||
throw new IllegalStateException();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// TODO can we do better for RegexPathSpec
|
||||
_mappingMatch = null;
|
||||
_matchValue = "";
|
||||
_servletPath = pathInContext;
|
||||
|
|
|
@ -34,6 +34,8 @@ import org.eclipse.jetty.util.IO;
|
|||
import org.eclipse.jetty.util.component.LifeCycle;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.junit.jupiter.params.ParameterizedTest;
|
||||
import org.junit.jupiter.params.provider.ValueSource;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
|
@ -145,8 +147,9 @@ public class RequestLogTest
|
|||
* Test an unread HTTP/1.1 POST, it has valid body content, the dispatched Handler on the server doesn't read the POST body content.
|
||||
* The RequestLog accidentally attempts to read the Request body content due to the use of Request.getParameterNames() API.
|
||||
*/
|
||||
@Test
|
||||
public void testNormalPostFormRequest() throws Exception
|
||||
@ParameterizedTest
|
||||
@ValueSource(strings = {"/hello", "/hello?a=b"})
|
||||
public void testNormalPostFormRequest(String requestPath) throws Exception
|
||||
{
|
||||
Server server = null;
|
||||
try
|
||||
|
@ -179,7 +182,7 @@ public class RequestLogTest
|
|||
byte[] bufForm = form.toString().getBytes(UTF_8);
|
||||
|
||||
StringBuilder req = new StringBuilder();
|
||||
req.append("POST /hello HTTP/1.1\r\n");
|
||||
req.append("POST ").append(requestPath).append(" HTTP/1.1\r\n");
|
||||
req.append("Host: ").append(baseURI.getRawAuthority()).append("\r\n");
|
||||
req.append("Content-Type: ").append(MimeTypes.Type.FORM_ENCODED).append("\r\n");
|
||||
req.append("Content-Length: ").append(bufForm.length).append("\r\n");
|
||||
|
@ -213,7 +216,10 @@ public class RequestLogTest
|
|||
assertThat("Body Content", bodyContent, containsString("Got POST to /hello"));
|
||||
|
||||
String reqlog = requestLogLines.poll(5, TimeUnit.SECONDS);
|
||||
assertThat("RequestLog", reqlog, containsString("method:POST|uri:/hello|paramNames.size:0|status:200"));
|
||||
int querySize = 0;
|
||||
if (requestPath.contains("?"))
|
||||
querySize = 1; // assuming that parameterized version only has 1 query value
|
||||
assertThat("RequestLog", reqlog, containsString("method:POST|uri:/hello|paramNames.size:" + querySize + "|status:200"));
|
||||
}
|
||||
}
|
||||
finally
|
||||
|
|
|
@ -1642,7 +1642,7 @@ public class ResponseTest
|
|||
}
|
||||
|
||||
@Test
|
||||
public void testEncodeRedirect()
|
||||
public void testEncodeURLs()
|
||||
{
|
||||
ContextHandler context = new ContextHandler("/path");
|
||||
Response response = getResponse();
|
||||
|
@ -1708,6 +1708,7 @@ public class ResponseTest
|
|||
assertEquals("/;jsessionid=12345", response.encodeURL("/"));
|
||||
assertEquals("/foo.html;jsessionid=12345#target", response.encodeURL("/foo.html#target"));
|
||||
assertEquals(";jsessionid=12345", response.encodeURL(""));
|
||||
assertEquals("../foo/bar.jsp;jsessionid=12345", response.encodeURL("../foo/bar.jsp"));
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
|
@ -1246,6 +1246,12 @@ public class ServletHandler extends ScopedHandler
|
|||
}
|
||||
}
|
||||
|
||||
protected PathSpec asPathSpec(String pathSpec)
|
||||
{
|
||||
// By default only allow servlet path specs
|
||||
return new ServletPathSpec(pathSpec);
|
||||
}
|
||||
|
||||
protected void updateMappings()
|
||||
{
|
||||
try (AutoLock ignored = lock())
|
||||
|
@ -1354,9 +1360,9 @@ public class ServletHandler extends ScopedHandler
|
|||
finalMapping.getServletName(),
|
||||
getServlet(finalMapping.getServletName()).getSource());
|
||||
|
||||
ServletPathSpec servletPathSpec = new ServletPathSpec(pathSpec);
|
||||
MappedServlet mappedServlet = new MappedServlet(servletPathSpec, getServlet(finalMapping.getServletName()));
|
||||
pm.put(servletPathSpec, mappedServlet);
|
||||
PathSpec ps = asPathSpec(pathSpec);
|
||||
MappedServlet mappedServlet = new MappedServlet(ps, getServlet(finalMapping.getServletName()));
|
||||
pm.put(ps, mappedServlet);
|
||||
}
|
||||
|
||||
_servletPathMap = pm;
|
||||
|
|
|
@ -0,0 +1,153 @@
|
|||
//
|
||||
// ========================================================================
|
||||
// Copyright (c) 1995-2022 Mort Bay Consulting Pty Ltd and others.
|
||||
//
|
||||
// This program and the accompanying materials are made available under the
|
||||
// terms of the Eclipse Public License v. 2.0 which is available at
|
||||
// https://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0
|
||||
// which is available at https://www.apache.org/licenses/LICENSE-2.0.
|
||||
//
|
||||
// SPDX-License-Identifier: EPL-2.0 OR Apache-2.0
|
||||
// ========================================================================
|
||||
//
|
||||
|
||||
package org.eclipse.jetty.servlet;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.PrintWriter;
|
||||
import javax.servlet.ServletException;
|
||||
import javax.servlet.http.HttpServlet;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.eclipse.jetty.http.pathmap.PathMappings;
|
||||
import org.eclipse.jetty.http.pathmap.PathSpec;
|
||||
import org.eclipse.jetty.server.LocalConnector;
|
||||
import org.eclipse.jetty.server.Server;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import static org.hamcrest.MatcherAssert.assertThat;
|
||||
import static org.hamcrest.Matchers.containsString;
|
||||
|
||||
public class RegexServletTest
|
||||
{
|
||||
private Server _server;
|
||||
private LocalConnector _connector;
|
||||
private ServletContextHandler _servletContextHandler;
|
||||
|
||||
@BeforeEach
|
||||
public void beforeEach()
|
||||
{
|
||||
_server = new Server();
|
||||
_connector = new LocalConnector(_server);
|
||||
|
||||
_servletContextHandler = new ServletContextHandler(_server, "/ctx");
|
||||
_servletContextHandler.setServletHandler(new ServletHandler()
|
||||
{
|
||||
@Override
|
||||
protected PathSpec asPathSpec(String pathSpec)
|
||||
{
|
||||
return PathMappings.asPathSpec(pathSpec);
|
||||
}
|
||||
});
|
||||
|
||||
_server.setHandler(_servletContextHandler);
|
||||
_server.addConnector(_connector);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testHello() throws Exception
|
||||
{
|
||||
_servletContextHandler.addServlet(new ServletHolder(new ServletContextHandlerTest.HelloServlet()), "^/[Hh]ello");
|
||||
_server.start();
|
||||
|
||||
assertThat(_connector.getResponse("GET /ctx/hello HTTP/1.0\r\n\r\n"), containsString("Hello World"));
|
||||
assertThat(_connector.getResponse("GET /ctx/Hello HTTP/1.0\r\n\r\n"), containsString("Hello World"));
|
||||
assertThat(_connector.getResponse("GET /ctx/HELLO HTTP/1.0\r\n\r\n"), containsString(" 404"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMapping() throws Exception
|
||||
{
|
||||
_servletContextHandler.addServlet(new ServletHolder(new TestServlet()), "^/test/.*$");
|
||||
_server.start();
|
||||
|
||||
String response = _connector.getResponse("GET /ctx/test/info HTTP/1.0\r\n\r\n");
|
||||
assertThat(response, containsString(" 200 OK"));
|
||||
assertThat(response, containsString("contextPath='/ctx'"));
|
||||
assertThat(response, containsString("servletPath='/test/info'"));
|
||||
assertThat(response, containsString("pathInfo='null'"));
|
||||
assertThat(response, containsString("mapping.mappingMatch='null'"));
|
||||
assertThat(response, containsString("mapping.matchValue=''"));
|
||||
assertThat(response, containsString("mapping.pattern='^/test/.*$'"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testForward() throws Exception
|
||||
{
|
||||
_servletContextHandler.addServlet(new ServletHolder(new ForwardServlet()), "^/forward(/.*)?");
|
||||
_servletContextHandler.addServlet(new ServletHolder(new TestServlet()), "^/[Tt]est(/.*)?");
|
||||
_server.start();
|
||||
|
||||
String response = _connector.getResponse("GET /ctx/forward/ignore HTTP/1.0\r\n\r\n");
|
||||
assertThat(response, containsString(" 200 OK"));
|
||||
assertThat(response, containsString("contextPath='/ctx'"));
|
||||
assertThat(response, containsString("servletPath='/Test/info'"));
|
||||
assertThat(response, containsString("pathInfo='null'"));
|
||||
assertThat(response, containsString("mapping.mappingMatch='null'"));
|
||||
assertThat(response, containsString("mapping.matchValue=''"));
|
||||
assertThat(response, containsString("mapping.pattern='^/[Tt]est(/.*)?'"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testInclude() throws Exception
|
||||
{
|
||||
_servletContextHandler.addServlet(new ServletHolder(new IncludeServlet()), "^/include$");
|
||||
_servletContextHandler.addServlet(new ServletHolder(new TestServlet()), "^/[Tt]est(/.*)?");
|
||||
_server.start();
|
||||
|
||||
String response = _connector.getResponse("GET /ctx/include HTTP/1.0\r\n\r\n");
|
||||
assertThat(response, containsString(" 200 OK"));
|
||||
assertThat(response, containsString("contextPath='/ctx'"));
|
||||
assertThat(response, containsString("servletPath='/include'"));
|
||||
assertThat(response, containsString("pathInfo='null'"));
|
||||
assertThat(response, containsString("mapping.mappingMatch='null'"));
|
||||
assertThat(response, containsString("mapping.matchValue=''"));
|
||||
assertThat(response, containsString("mapping.pattern='^/include$'"));
|
||||
}
|
||||
|
||||
static class TestServlet extends HttpServlet
|
||||
{
|
||||
@Override
|
||||
protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
|
||||
{
|
||||
resp.setStatus(200);
|
||||
PrintWriter out = resp.getWriter();
|
||||
out.printf("contextPath='%s'%n", req.getContextPath());
|
||||
out.printf("servletPath='%s'%n", req.getServletPath());
|
||||
out.printf("pathInfo='%s'%n", req.getPathInfo());
|
||||
out.printf("mapping.mappingMatch='%s'%n", req.getHttpServletMapping().getMappingMatch());
|
||||
out.printf("mapping.matchValue='%s'%n", req.getHttpServletMapping().getMatchValue());
|
||||
out.printf("mapping.pattern='%s'%n", req.getHttpServletMapping().getPattern());
|
||||
}
|
||||
}
|
||||
|
||||
static class ForwardServlet extends HttpServlet
|
||||
{
|
||||
@Override
|
||||
protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
|
||||
{
|
||||
req.getServletContext().getRequestDispatcher("/Test/info").forward(req, resp);
|
||||
}
|
||||
}
|
||||
|
||||
static class IncludeServlet extends HttpServlet
|
||||
{
|
||||
@Override
|
||||
protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
|
||||
{
|
||||
req.getServletContext().getRequestDispatcher("/Test/info").include(req, resp);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -29,6 +29,8 @@ public class ModuleGraphWriter
|
|||
{
|
||||
private String colorModuleBg;
|
||||
private String colorEnabledBg;
|
||||
private String colorEdgeBefore;
|
||||
private String colorEdgeAfter;
|
||||
private String colorTransitiveBg;
|
||||
private String colorCellBg;
|
||||
private String colorHeaderBg;
|
||||
|
@ -38,6 +40,8 @@ public class ModuleGraphWriter
|
|||
{
|
||||
colorModuleBg = "#B8FFB8";
|
||||
colorEnabledBg = "#66FFCC";
|
||||
colorEdgeAfter = "#00CC33";
|
||||
colorEdgeAfter = "#33CC00";
|
||||
colorTransitiveBg = "#66CC66";
|
||||
colorCellBg = "#FFFFFF80";
|
||||
colorHeaderBg = "#00000020";
|
||||
|
@ -49,6 +53,8 @@ public class ModuleGraphWriter
|
|||
String prefix = "jetty.graph.";
|
||||
colorModuleBg = getProperty(props, prefix + "color.module.bg", colorModuleBg);
|
||||
colorEnabledBg = getProperty(props, prefix + "color.enabled.bg", colorEnabledBg);
|
||||
colorEdgeBefore = getProperty(props, prefix + "color.edge.before", colorEdgeBefore);
|
||||
colorEdgeAfter = getProperty(props, prefix + "color.edge.after", colorEdgeAfter);
|
||||
colorTransitiveBg = getProperty(props, prefix + "color.transitive.bg", colorTransitiveBg);
|
||||
colorCellBg = getProperty(props, prefix + "color.cell.bg", colorCellBg);
|
||||
colorHeaderBg = getProperty(props, prefix + "color.header.bg", colorHeaderBg);
|
||||
|
@ -73,7 +79,7 @@ public class ModuleGraphWriter
|
|||
public void write(Modules modules, Path outputFile) throws IOException
|
||||
{
|
||||
try (BufferedWriter writer = Files.newBufferedWriter(outputFile, StandardCharsets.UTF_8, StandardOpenOption.CREATE_NEW, StandardOpenOption.WRITE);
|
||||
PrintWriter out = new PrintWriter(writer);)
|
||||
PrintWriter out = new PrintWriter(writer))
|
||||
{
|
||||
writeHeaderMessage(out, outputFile);
|
||||
|
||||
|
@ -245,13 +251,13 @@ public class ModuleGraphWriter
|
|||
depends = Module.normalizeModuleName(depends);
|
||||
out.printf(" \"%s\" -> \"%s\";%n", module.getName(), depends);
|
||||
}
|
||||
for (String optional : module.getAfter())
|
||||
{
|
||||
out.printf(" \"%s\" -> \"%s\" [ color=\"%s\" ];%n", module.getName(), optional, colorEdgeAfter);
|
||||
}
|
||||
for (String before : module.getBefore())
|
||||
{
|
||||
out.printf(" \"%s\" << \"%s\";%n", module.getName(), before);
|
||||
}
|
||||
for (String after : module.getAfter())
|
||||
{
|
||||
out.printf(" \"%s\" >> \"%s\";%n", module.getName(), after);
|
||||
out.printf(" \"%s\" -> \"%s\" [ color=\"%s\" ];%n", before, module.getName(), colorEdgeBefore);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,8 +13,12 @@
|
|||
|
||||
package org.eclipse.jetty.start;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStreamReader;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.nio.file.Path;
|
||||
import java.time.Duration;
|
||||
|
||||
import org.eclipse.jetty.start.config.CommandLineConfigSource;
|
||||
import org.eclipse.jetty.start.config.ConfigSources;
|
||||
|
@ -28,6 +32,8 @@ import org.junit.jupiter.api.extension.ExtendWith;
|
|||
|
||||
import static org.hamcrest.MatcherAssert.assertThat;
|
||||
import static org.hamcrest.Matchers.is;
|
||||
import static org.junit.jupiter.api.Assertions.assertTimeout;
|
||||
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||
|
||||
@ExtendWith(WorkDirExtension.class)
|
||||
public class ModuleGraphWriterTest
|
||||
|
@ -58,11 +64,51 @@ public class ModuleGraphWriterTest
|
|||
Modules modules = new Modules(basehome, args);
|
||||
modules.registerAll();
|
||||
|
||||
Path outputFile = basehome.getBasePath("graph.dot");
|
||||
Path dotFile = basehome.getBasePath("graph.dot");
|
||||
|
||||
ModuleGraphWriter writer = new ModuleGraphWriter();
|
||||
writer.write(modules, outputFile);
|
||||
writer.write(modules, dotFile);
|
||||
|
||||
assertThat("Output File Exists", FS.exists(outputFile), is(true));
|
||||
assertThat("Output File Exists", FS.exists(dotFile), is(true));
|
||||
|
||||
assertTimeout(Duration.ofSeconds(3), () ->
|
||||
{
|
||||
if (execDotCmd("dot", "-V"))
|
||||
{
|
||||
Path outputPng = testdir.getPath().resolve("output.png");
|
||||
assertTrue(execDotCmd("dot", "-Tpng", "-o" + outputPng, dotFile.toString()));
|
||||
|
||||
assertThat("PNG File does not exist", FS.exists(outputPng));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private boolean execDotCmd(String... args)
|
||||
{
|
||||
try
|
||||
{
|
||||
Process p = Runtime.getRuntime().exec(args);
|
||||
|
||||
try (BufferedReader bri = new BufferedReader(new InputStreamReader(p.getInputStream(), StandardCharsets.UTF_8));
|
||||
BufferedReader bre = new BufferedReader(new InputStreamReader(p.getErrorStream(), StandardCharsets.UTF_8)))
|
||||
{
|
||||
String line;
|
||||
while ((line = bri.readLine()) != null)
|
||||
{
|
||||
System.out.printf("[STDIN] %s%n", line);
|
||||
}
|
||||
while ((line = bre.readLine()) != null)
|
||||
{
|
||||
System.out.printf("[STDERR] %s%n", line);
|
||||
}
|
||||
}
|
||||
p.waitFor();
|
||||
return true;
|
||||
}
|
||||
catch (IOException | InterruptedException e)
|
||||
{
|
||||
e.printStackTrace();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -410,6 +410,11 @@ public class ReservedThreadExecutor extends AbstractLifeCycle implements TryExec
|
|||
{
|
||||
LOG.warn("Unable to run task", e);
|
||||
}
|
||||
finally
|
||||
{
|
||||
// Clear any interrupted status.
|
||||
Thread.interrupted();
|
||||
}
|
||||
}
|
||||
}
|
||||
finally
|
||||
|
@ -431,4 +436,4 @@ public class ReservedThreadExecutor extends AbstractLifeCycle implements TryExec
|
|||
_thread);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
75
pom.xml
75
pom.xml
|
@ -30,7 +30,7 @@
|
|||
<asciidoctorj-diagram.version>2.2.1</asciidoctorj-diagram.version>
|
||||
<asciidoctorj.version>2.5.3</asciidoctorj.version>
|
||||
<asm.version>9.2</asm.version>
|
||||
<awaitility.version>4.1.1</awaitility.version>
|
||||
<awaitility.version>4.2.0</awaitility.version>
|
||||
<bndlib.version>5.3.0</bndlib.version>
|
||||
<build-support.version>1.5</build-support.version>
|
||||
<checkstyle.version>9.3</checkstyle.version>
|
||||
|
@ -43,18 +43,18 @@
|
|||
<felix.version>7.0.3</felix.version>
|
||||
<findbugs.jsr305.version>3.0.2</findbugs.jsr305.version>
|
||||
<google.errorprone.version>2.11.0</google.errorprone.version>
|
||||
<grpc.version>1.44.1</grpc.version>
|
||||
<grpc.version>1.45.0</grpc.version>
|
||||
<gson.version>2.9.0</gson.version>
|
||||
<guava.version>31.0.1-jre</guava.version>
|
||||
<guava.version>31.1-jre</guava.version>
|
||||
<guice.version>5.1.0</guice.version>
|
||||
<hamcrest.version>2.2</hamcrest.version>
|
||||
<hawtio.version>2.14.5</hawtio.version>
|
||||
<hazelcast.version>4.2.4</hazelcast.version>
|
||||
<infinispan.protostream.version>4.3.5.Final</infinispan.protostream.version>
|
||||
<infinispan.version>11.0.15.Final</infinispan.version>
|
||||
<jackson.annotations.version>2.13.1</jackson.annotations.version>
|
||||
<jackson.core.version>2.13.1</jackson.core.version>
|
||||
<jackson.databind.version>2.13.1</jackson.databind.version>
|
||||
<jackson.annotations.version>2.13.2</jackson.annotations.version>
|
||||
<jackson.core.version>2.13.2</jackson.core.version>
|
||||
<jackson.databind.version>2.13.2</jackson.databind.version>
|
||||
<jakarta.activation.api.version>1.2.2</jakarta.activation.api.version>
|
||||
<jakarta.annotation.api.version>1.3.5</jakarta.annotation.api.version>
|
||||
<jakarta.el-api.version>3.0.3</jakarta.el-api.version>
|
||||
|
@ -84,7 +84,7 @@
|
|||
<jboss-threads.version>3.1.0.Final</jboss-threads.version>
|
||||
<jetty-assembly-descriptors.version>1.1</jetty-assembly-descriptors.version>
|
||||
<jetty.perf-helper.version>1.0.7</jetty.perf-helper.version>
|
||||
<jetty-quiche-native.version>0.11.0.2</jetty-quiche-native.version>
|
||||
<jetty-quiche-native.version>0.12.0</jetty-quiche-native.version>
|
||||
<jetty.servlet.api.version>4.0.6</jetty.servlet.api.version>
|
||||
<jetty-test-policy.version>1.2</jetty-test-policy.version>
|
||||
<jetty.test.version>5.9</jetty.test.version>
|
||||
|
@ -101,7 +101,7 @@
|
|||
<jsp.impl.version>9.0.52</jsp.impl.version>
|
||||
<junit.version>5.8.2</junit.version>
|
||||
<kerb-simplekdc.version>2.0.1</kerb-simplekdc.version>
|
||||
<log4j2.version>2.17.1</log4j2.version>
|
||||
<log4j2.version>2.17.2</log4j2.version>
|
||||
<logback.version>1.3.0-alpha14</logback.version>
|
||||
<mariadb.version>3.0.3</mariadb.version>
|
||||
<mariadb.docker.version>10.3.6</mariadb.docker.version>
|
||||
|
@ -120,8 +120,8 @@
|
|||
<taglibs-standard-spec.version>1.2.5</taglibs-standard-spec.version>
|
||||
<testcontainers.version>1.16.3</testcontainers.version>
|
||||
<weld.version>3.1.9.Final</weld.version>
|
||||
<wildfly.common.version>1.5.4.Final</wildfly.common.version>
|
||||
<wildfly.elytron.version>1.18.3.Final</wildfly.elytron.version>
|
||||
<wildfly.common.version>1.6.0.Final</wildfly.common.version>
|
||||
<wildfly.elytron.version>1.19.0.Final</wildfly.elytron.version>
|
||||
<xmemcached.version>2.4.7</xmemcached.version>
|
||||
|
||||
<!-- some maven plugins versions -->
|
||||
|
@ -141,8 +141,8 @@
|
|||
<maven.bundle.plugin.version>5.1.4</maven.bundle.plugin.version>
|
||||
<maven.clean.plugin.version>3.1.0</maven.clean.plugin.version>
|
||||
<maven.checkstyle.plugin.version>3.1.2</maven.checkstyle.plugin.version>
|
||||
<maven.compiler.plugin.version>3.10.0</maven.compiler.plugin.version>
|
||||
<maven.dependency.plugin.version>3.2.0</maven.dependency.plugin.version>
|
||||
<maven.compiler.plugin.version>3.10.1</maven.compiler.plugin.version>
|
||||
<maven.dependency.plugin.version>3.3.0</maven.dependency.plugin.version>
|
||||
<maven.deploy.plugin.version>3.0.0-M2</maven.deploy.plugin.version>
|
||||
<maven.eclipse.plugin.version>2.10</maven.eclipse.plugin.version>
|
||||
<maven.enforcer.plugin.version>3.0.0</maven.enforcer.plugin.version>
|
||||
|
@ -152,10 +152,9 @@
|
|||
<maven.invoker.plugin.version>3.2.2</maven.invoker.plugin.version>
|
||||
<maven.jar.plugin.version>3.2.2</maven.jar.plugin.version>
|
||||
<maven.javadoc.plugin.version>3.3.2</maven.javadoc.plugin.version>
|
||||
<maven.jxr.plugin.version>3.1.1</maven.jxr.plugin.version>
|
||||
<maven.jxr.plugin.version>3.2.0</maven.jxr.plugin.version>
|
||||
<maven.plugin-tools.version>3.6.4</maven.plugin-tools.version>
|
||||
<maven-plugin.plugin.version>3.6.4</maven-plugin.plugin.version>
|
||||
<maven.project-info-reports.plugin.version>3.2.1</maven.project-info-reports.plugin.version>
|
||||
<maven.release.plugin.version>2.5.3</maven.release.plugin.version>
|
||||
<maven.remote-resources-plugin.version>1.7.0</maven.remote-resources-plugin.version>
|
||||
<maven.resources.plugin.version>3.2.0</maven.resources.plugin.version>
|
||||
|
@ -165,7 +164,7 @@
|
|||
<maven.source.plugin.version>3.2.1</maven.source.plugin.version>
|
||||
<maven.war.plugin.version>3.3.2</maven.war.plugin.version>
|
||||
<spotbugs.maven.plugin.version>4.5.3.0</spotbugs.maven.plugin.version>
|
||||
<versions.maven.plugin.version>2.9.0</versions.maven.plugin.version>
|
||||
<versions.maven.plugin.version>2.10.0</versions.maven.plugin.version>
|
||||
|
||||
<!-- testing -->
|
||||
<invoker.mergeUserSettings>false</invoker.mergeUserSettings>
|
||||
|
@ -700,11 +699,6 @@
|
|||
<artifactId>maven-plugin-plugin</artifactId>
|
||||
<version>${maven-plugin.plugin.version}</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-project-info-reports-plugin</artifactId>
|
||||
<version>${maven.project-info-reports.plugin.version}</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-release-plugin</artifactId>
|
||||
|
@ -2064,47 +2058,6 @@
|
|||
</pluginManagement>
|
||||
</build>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>checkstyle</id>
|
||||
<reporting>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-project-info-reports-plugin</artifactId>
|
||||
<version>${maven.project-info-reports.plugin.version}</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-checkstyle-plugin</artifactId>
|
||||
<reportSets>
|
||||
<reportSet>
|
||||
<reports>
|
||||
<report>checkstyle</report>
|
||||
</reports>
|
||||
</reportSet>
|
||||
</reportSets>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</reporting>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-site-plugin</artifactId>
|
||||
<version>${maven.site.plugin.version}</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>build-site</id>
|
||||
<goals>
|
||||
<goal>site</goal>
|
||||
</goals>
|
||||
<phase>package</phase>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>config</id>
|
||||
<activation>
|
||||
|
|
|
@ -105,40 +105,6 @@ public class ThirdPartyModulesTests extends AbstractJettyHomeTest
|
|||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testjminix() throws Exception
|
||||
{
|
||||
Path jettyBase = newTestJettyBaseDirectory();
|
||||
String jettyVersion = System.getProperty("jettyVersion");
|
||||
JettyHomeTester distribution = JettyHomeTester.Builder.newInstance()
|
||||
.jettyVersion(jettyVersion)
|
||||
.jettyBase(jettyBase)
|
||||
.mavenLocalRepository(System.getProperty("mavenRepoPath"))
|
||||
.build();
|
||||
|
||||
int httpPort = distribution.freePort();
|
||||
|
||||
String[] argsConfig = {
|
||||
"--approve-all-licenses",
|
||||
"--add-modules=jminix,http,logging-jcl-capture"
|
||||
};
|
||||
|
||||
try (JettyHomeTester.Run runConfig = distribution.start(argsConfig))
|
||||
{
|
||||
assertTrue(runConfig.awaitFor(2, TimeUnit.MINUTES));
|
||||
assertEquals(0, runConfig.getExitValue());
|
||||
|
||||
String[] argsStart = {
|
||||
"jetty.http.port=" + httpPort
|
||||
};
|
||||
|
||||
try (JettyHomeTester.Run runStart = distribution.start(argsStart))
|
||||
{
|
||||
assertTrue(runStart.awaitConsoleLogsFor("Started Server@", 20, TimeUnit.SECONDS));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testjolokia() throws Exception
|
||||
{
|
||||
|
|
|
@ -10,25 +10,10 @@
|
|||
<artifactId>test-webapps-parent</artifactId>
|
||||
<name>Jetty Tests :: WebApps :: Parent</name>
|
||||
<packaging>pom</packaging>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<configuration>
|
||||
<!-- DO NOT DEPLOY (or Release) -->
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<skip>true</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
<properties>
|
||||
<jacoco.skip>true</jacoco.skip>
|
||||
<maven.deploy.skip>true</maven.deploy.skip>
|
||||
</properties>
|
||||
<modules>
|
||||
<module>test-webapp-rfc2616</module>
|
||||
<module>test-http2-webapp</module>
|
||||
|
|
Loading…
Reference in New Issue