Get rid of javax.servlet API dependency for core org.eclipse.jgit

Change-Id: I57d5d4fab7e0b1bd4cf5f1850e8569c8ac5def88
Signed-off-by: Marc Strapetz <marc.strapetz@syntevo.com>
Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
This commit is contained in:
Marc Strapetz 2017-01-03 18:12:05 +01:00 committed by Andrey Loskutov
parent 5dc30db56e
commit 6087031469
4 changed files with 4 additions and 12 deletions

View File

@ -9,7 +9,6 @@ java_library(
'//lib:javaewah',
'//lib:jsch',
'//lib:httpcomponents',
'//lib:servlet-api',
'//lib:slf4j-api',
],
visibility = ['PUBLIC'],

View File

@ -140,7 +140,6 @@ Import-Package: com.googlecode.javaewah;version="[1.1.6,2.0.0)",
com.jcraft.jsch;version="[0.1.37,0.2.0)",
javax.crypto,
javax.net.ssl,
javax.servlet.http;version="[2.5.0,3.2.0)",
org.slf4j;version="[1.7.0,2.0.0)",
org.xml.sax,
org.xml.sax.helpers

View File

@ -89,11 +89,6 @@
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<scope>provided</scope>
</dependency>
</dependencies>
<build>

View File

@ -45,8 +45,6 @@
import java.io.IOException;
import javax.servlet.http.HttpServletResponse;
import org.eclipse.jgit.internal.JGitText;
/**
@ -55,6 +53,7 @@
* @since 2.0
*/
public class ServiceMayNotContinueException extends IOException {
private static final int FORBIDDEN = 403;
private static final long serialVersionUID = 1L;
private final int statusCode;
@ -63,7 +62,7 @@ public class ServiceMayNotContinueException extends IOException {
/** Initialize with no message. */
public ServiceMayNotContinueException() {
// Do not set a message.
statusCode = HttpServletResponse.SC_FORBIDDEN;
statusCode = FORBIDDEN;
}
/**
@ -73,7 +72,7 @@ public ServiceMayNotContinueException() {
*/
public ServiceMayNotContinueException(String msg) {
super(msg);
statusCode = HttpServletResponse.SC_FORBIDDEN;
statusCode = FORBIDDEN;
}
/**
@ -99,7 +98,7 @@ public ServiceMayNotContinueException(String msg, int statusCode) {
*/
public ServiceMayNotContinueException(String msg, Throwable cause) {
super(msg, cause);
statusCode = HttpServletResponse.SC_FORBIDDEN;
statusCode = FORBIDDEN;
}
/**