aurora-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wfar...@apache.org
Subject aurora git commit: Upgrade to jetty 9.3.6.v20151106.
Date Tue, 15 Dec 2015 06:40:23 GMT
Repository: aurora
Updated Branches:
  refs/heads/master c66d9f574 -> fe9b46023


Upgrade to jetty 9.3.6.v20151106.

Reviewed at https://reviews.apache.org/r/41392/


Project: http://git-wip-us.apache.org/repos/asf/aurora/repo
Commit: http://git-wip-us.apache.org/repos/asf/aurora/commit/fe9b4602
Tree: http://git-wip-us.apache.org/repos/asf/aurora/tree/fe9b4602
Diff: http://git-wip-us.apache.org/repos/asf/aurora/diff/fe9b4602

Branch: refs/heads/master
Commit: fe9b4602313ba7c6ee465714cc0377b5e9500383
Parents: c66d9f5
Author: Bill Farner <wfarner@apache.org>
Authored: Mon Dec 14 22:40:18 2015 -0800
Committer: Bill Farner <wfarner@apache.org>
Committed: Mon Dec 14 22:40:18 2015 -0800

----------------------------------------------------------------------
 build.gradle                                    |  15 +--
 .../aurora/scheduler/http/HttpStatsFilter.java  |   1 +
 .../scheduler/http/JettyServerModule.java       |  67 ++++++----
 .../aurora/scheduler/http/RequestLogger.java    | 131 -------------------
 .../aurora/scheduler/http/api/ApiModule.java    |   9 --
 .../scheduler/http/RequestLoggerTest.java       | 111 ----------------
 .../scheduler/http/ServletFilterTest.java       |   4 -
 .../aurora/e2e/test_kerberos_end_to_end.sh      |   4 +-
 8 files changed, 46 insertions(+), 296 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/build.gradle
----------------------------------------------------------------------
diff --git a/build.gradle b/build.gradle
index ab1ec1c..a91370f 100644
--- a/build.gradle
+++ b/build.gradle
@@ -86,7 +86,7 @@ For more details, please see https://issues.apache.org/jira/browse/AURORA-1169
   ext.slf4jRev = '1.7.12'
   ext.thriftRev = '0.9.1'
   ext.guiceRev = '3.0'
-  ext.servletRev = '2.5'
+  ext.servletRev = '3.1.0'
   ext.stringTemplateRev = '3.2.1'
   ext.zookeeperRev = '3.3.4'
   ext.jerseyRev = '1.18.1'
@@ -156,9 +156,9 @@ project(':commons') {
     compile "com.google.guava:guava:${guavaRev}"
     compile "com.google.inject.extensions:guice-multibindings:${guiceRev}"
     compile "com.google.inject:guice:${guiceRev}"
+    compile "com.sun.jersey:jersey-core:${jerseyRev}"
     compile "commons-lang:commons-lang:${commonsLangRev}"
-    compile "javax.servlet:servlet-api:${servletRev}"
-    compile "javax.ws.rs:javax.ws.rs-api:2.0.1"
+    compile "javax.servlet:javax.servlet-api:${servletRev}"
     compile "joda-time:joda-time:2.3"
     compile "log4j:log4j:${log4jRev}"
     compile "org.antlr:stringtemplate:${stringTemplateRev}"
@@ -324,12 +324,7 @@ sourceSets {
 
 dependencies {
   def shiroRev = '1.2.4'
-
-  def gsonDep = "com.google.code.gson:gson:${gsonRev}"
-  def guavaDep = "com.google.guava:guava:${guavaRev}"
-  // NOTE: We are using the jetty 7.x series due to a large number of dependencies impacted
-  // by 8.x and later resulting from using newer javax.servlet servlet-api.
-  def jettyDep = '7.6.15.v20140411'
+  def jettyDep = '9.3.6.v20151106'
 
   compile project(':api')
   compile project(':commons')
@@ -349,7 +344,7 @@ dependencies {
   compile "com.sun.jersey:jersey-servlet:${jerseyRev}"
   compile "com.sun.jersey.contribs:jersey-guice:${jerseyRev}"
   compile 'javax.inject:javax.inject:1'
-  compile "javax.servlet:servlet-api:${servletRev}"
+  compile "javax.servlet:javax.servlet-api:${servletRev}"
   compile "log4j:log4j:${log4jRev}"
   compile "org.antlr:stringtemplate:${stringTemplateRev}"
   compile 'org.apache.mesos:mesos:0.24.1'

http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/src/main/java/org/apache/aurora/scheduler/http/HttpStatsFilter.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/aurora/scheduler/http/HttpStatsFilter.java b/src/main/java/org/apache/aurora/scheduler/http/HttpStatsFilter.java
index 7ffd105..d0a52a8 100644
--- a/src/main/java/org/apache/aurora/scheduler/http/HttpStatsFilter.java
+++ b/src/main/java/org/apache/aurora/scheduler/http/HttpStatsFilter.java
@@ -54,6 +54,7 @@ public class HttpStatsFilter extends AbstractFilter {
       wrappedStatus = sc;
     }
 
+    @SuppressWarnings("deprecation")
     @Override
     public void setStatus(int sc, String sm) {
       super.setStatus(sc, sm);

http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/src/main/java/org/apache/aurora/scheduler/http/JettyServerModule.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/aurora/scheduler/http/JettyServerModule.java b/src/main/java/org/apache/aurora/scheduler/http/JettyServerModule.java
index c78315d..838bfc9 100644
--- a/src/main/java/org/apache/aurora/scheduler/http/JettyServerModule.java
+++ b/src/main/java/org/apache/aurora/scheduler/http/JettyServerModule.java
@@ -24,7 +24,9 @@ import java.util.logging.Logger;
 import javax.annotation.Nonnegative;
 import javax.inject.Inject;
 import javax.inject.Singleton;
+import javax.servlet.DispatcherType;
 import javax.servlet.ServletContextListener;
+import javax.ws.rs.HttpMethod;
 
 import com.google.common.annotations.VisibleForTesting;
 import com.google.common.base.Joiner;
@@ -72,15 +74,16 @@ import org.apache.aurora.scheduler.http.api.security.HttpSecurityModule;
 import org.apache.aurora.scheduler.thrift.ThriftModule;
 import org.eclipse.jetty.rewrite.handler.RewriteHandler;
 import org.eclipse.jetty.rewrite.handler.RewriteRegexRule;
-import org.eclipse.jetty.server.Connector;
-import org.eclipse.jetty.server.DispatcherType;
+import org.eclipse.jetty.server.Handler;
 import org.eclipse.jetty.server.Server;
+import org.eclipse.jetty.server.ServerConnector;
+import org.eclipse.jetty.server.Slf4jRequestLog;
 import org.eclipse.jetty.server.handler.HandlerCollection;
+import org.eclipse.jetty.server.handler.HandlerList;
 import org.eclipse.jetty.server.handler.RequestLogHandler;
-import org.eclipse.jetty.server.nio.SelectChannelConnector;
+import org.eclipse.jetty.server.handler.gzip.GzipHandler;
 import org.eclipse.jetty.servlet.DefaultServlet;
 import org.eclipse.jetty.servlet.ServletContextHandler;
-import org.eclipse.jetty.servlets.GzipFilter;
 import org.eclipse.jetty.util.resource.Resource;
 
 import static java.util.Objects.requireNonNull;
@@ -263,7 +266,6 @@ public class JettyServerModule extends AbstractModule {
                 filterRegex(allOf(ImmutableSet.copyOf(JAX_RS_ENDPOINTS.values())))
                     .through(GuiceContainer.class, GUICE_CONTAINER_PARAMS);
 
-                filterRegex("/assets/.*").through(new GzipFilter());
                 filterRegex("/assets/scheduler(?:/.*)?").through(LeaderRedirectFilter.class);
 
                 serve("/assets", "/assets/*")
@@ -303,6 +305,7 @@ public class JettyServerModule extends AbstractModule {
     private final ServletContextListener servletContextListener;
     private final Optional<String> advertisedHostOverride;
     private volatile Server server;
+    private volatile HostAndPort serverAddress = null;
 
     @Inject
     HttpServerLauncher(
@@ -321,7 +324,7 @@ public class JettyServerModule extends AbstractModule {
             .put("/(?:scheduler|updates)(?:/.*)?", "/assets/scheduler/index.html")
             .build();
 
-    private RewriteHandler getRewriteHandler(HandlerCollection rootHandler) {
+    private static Handler getRewriteHandler(Handler wrapped) {
       RewriteHandler rewrites = new RewriteHandler();
       rewrites.setOriginalPathAttribute(ORIGINAL_PATH_ATTRIBUTE_NAME);
       rewrites.setRewriteRequestURI(true);
@@ -334,32 +337,24 @@ public class JettyServerModule extends AbstractModule {
         rewrites.addRule(rule);
       }
 
-      rewrites.setHandler(rootHandler);
+      rewrites.setHandler(wrapped);
 
       return rewrites;
     }
 
+    private static Handler getGzipHandler(Handler wrapped) {
+      GzipHandler gzip = new GzipHandler();
+      gzip.addIncludedMethods(HttpMethod.POST);
+      gzip.setHandler(wrapped);
+      return gzip;
+    }
+
     @Override
     public HostAndPort getAddress() {
       Preconditions.checkState(state() == State.RUNNING);
-      Connector connector = server.getConnectors()[0];
-
-      String host;
-      if (advertisedHostOverride.isPresent()) {
-        host = advertisedHostOverride.get();
-      } else if (connector.getHost() == null) {
-        // Resolve the local host name.
-        try {
-          host = InetAddress.getLocalHost().getHostAddress();
-        } catch (UnknownHostException e) {
-          throw new RuntimeException("Failed to resolve local host address: " + e, e);
-        }
-      } else {
-        // If jetty was configured with a specific host to bind to, use that.
-        host = connector.getHost();
-      }
-
-      return HostAndPort.fromParts(host, connector.getLocalPort());
+      return HostAndPort.fromParts(
+          advertisedHostOverride.or(serverAddress.getHostText()),
+          serverAddress.getPort());
     }
 
     @Override
@@ -376,18 +371,18 @@ public class JettyServerModule extends AbstractModule {
       servletHandler.addFilter(GuiceFilter.class, "/*", EnumSet.allOf(DispatcherType.class));
       servletHandler.addEventListener(servletContextListener);
 
-      HandlerCollection rootHandler = new HandlerCollection();
+      HandlerCollection rootHandler = new HandlerList();
 
       RequestLogHandler logHandler = new RequestLogHandler();
-      logHandler.setRequestLog(new RequestLogger());
+      logHandler.setRequestLog(new Slf4jRequestLog());
 
       rootHandler.addHandler(logHandler);
       rootHandler.addHandler(servletHandler);
 
-      Connector connector = new SelectChannelConnector();
+      ServerConnector connector = new ServerConnector(server);
       connector.setPort(HTTP_PORT.get());
       server.addConnector(connector);
-      server.setHandler(getRewriteHandler(rootHandler));
+      server.setHandler(getGzipHandler(getRewriteHandler(rootHandler)));
 
       try {
         connector.open();
@@ -395,6 +390,20 @@ public class JettyServerModule extends AbstractModule {
       } catch (Exception e) {
         throw Throwables.propagate(e);
       }
+
+      String host;
+      if (connector.getHost() == null) {
+        // Resolve the local host name.
+        try {
+          host = InetAddress.getLocalHost().getHostAddress();
+        } catch (UnknownHostException e) {
+          throw new RuntimeException("Failed to resolve local host address: " + e, e);
+        }
+      } else {
+        // If jetty was configured with a specific host to bind to, use that.
+        host = connector.getHost();
+      }
+      serverAddress = HostAndPort.fromParts(host, connector.getLocalPort());
     }
 
     @Override

http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/src/main/java/org/apache/aurora/scheduler/http/RequestLogger.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/aurora/scheduler/http/RequestLogger.java b/src/main/java/org/apache/aurora/scheduler/http/RequestLogger.java
deleted file mode 100644
index ef6a848..0000000
--- a/src/main/java/org/apache/aurora/scheduler/http/RequestLogger.java
+++ /dev/null
@@ -1,131 +0,0 @@
-/**
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.aurora.scheduler.http;
-
-import java.util.Locale;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-import com.google.common.annotations.VisibleForTesting;
-
-import org.apache.aurora.common.util.Clock;
-import org.eclipse.jetty.http.HttpHeaders;
-import org.eclipse.jetty.server.Request;
-import org.eclipse.jetty.server.RequestLog;
-import org.eclipse.jetty.server.Response;
-import org.eclipse.jetty.util.DateCache;
-import org.eclipse.jetty.util.component.AbstractLifeCycle;
-
-import static java.util.Objects.requireNonNull;
-
-/**
- * A copy of twitter RequestLogger from twitter commons, which is a port of jetty's NCSARequestLog
- * to use java.util.logging.  This clone exists to allow us to upgrade to jetty 7.
- * <p>
- * TODO(wfarner): Replace this with jetty's Slf4jRequestLog once we upgrade to jetty 8.
- */
-public class RequestLogger extends AbstractLifeCycle implements RequestLog {
-
-  private static final Logger LOGGER = Logger.getLogger(RequestLogger.class.getName());
-
-  private final Clock clock;
-  private final LogSink sink;
-  private final DateCache logDateCache;
-
-  interface LogSink {
-    boolean isLoggable(Level level);
-    void log(Level level, String messagge);
-  }
-
-  RequestLogger() {
-    this(Clock.SYSTEM_CLOCK, new LogSink() {
-      @Override
-      public boolean isLoggable(Level level) {
-        return LOGGER.isLoggable(level);
-      }
-
-      @Override public void log(Level level, String message) {
-        LOGGER.log(level, message);
-      }
-    });
-  }
-
-  @VisibleForTesting
-  RequestLogger(Clock clock, LogSink sink) {
-    this.clock = requireNonNull(clock);
-    this.sink = requireNonNull(sink);
-    logDateCache = new DateCache("dd/MMM/yyyy:HH:mm:ss Z", Locale.getDefault());
-    logDateCache.setTimeZoneID("GMT");
-  }
-
-  private String formatEntry(Request request, Response response) {
-    StringBuilder buf = new StringBuilder();
-
-    buf.append(request.getServerName());
-    buf.append(' ');
-
-    String addr = request.getHeader(HttpHeaders.X_FORWARDED_FOR);
-    if (addr == null) {
-      addr = request.getRemoteAddr();
-    }
-
-    buf.append(addr);
-    buf.append(" [");
-    buf.append(logDateCache.format(request.getTimeStamp()));
-    buf.append("] \"");
-    buf.append(request.getMethod());
-    buf.append(' ');
-    buf.append(request.getUri().toString());
-    buf.append(' ');
-    buf.append(request.getProtocol());
-    buf.append("\" ");
-    buf.append(response.getStatus());
-    buf.append(' ');
-    buf.append(response.getContentCount());
-    buf.append(' ');
-
-    String referer = request.getHeader(HttpHeaders.REFERER);
-    if (referer == null) {
-      buf.append("\"-\" ");
-    } else {
-      buf.append('"');
-      buf.append(referer);
-      buf.append("\" ");
-    }
-
-    String agent = request.getHeader(HttpHeaders.USER_AGENT);
-    if (agent == null) {
-      buf.append("\"-\" ");
-    } else {
-      buf.append('"');
-      buf.append(agent);
-      buf.append('"');
-    }
-
-    buf.append(' ');
-    buf.append(clock.nowMillis() - request.getTimeStamp());
-    return buf.toString();
-  }
-
-  @Override
-  public void log(Request request, Response response) {
-    int statusCategory = response.getStatus() / 100;
-    Level level = statusCategory == 2 || statusCategory == 3 ? Level.INFO : Level.WARNING;
-    if (!sink.isLoggable(level)) {
-      return;
-    }
-
-    sink.log(level, formatEntry(request, response));
-  }
-}

http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/src/main/java/org/apache/aurora/scheduler/http/api/ApiModule.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/aurora/scheduler/http/api/ApiModule.java b/src/main/java/org/apache/aurora/scheduler/http/api/ApiModule.java
index 791fd45..da6894e 100644
--- a/src/main/java/org/apache/aurora/scheduler/http/api/ApiModule.java
+++ b/src/main/java/org/apache/aurora/scheduler/http/api/ApiModule.java
@@ -14,9 +14,7 @@
 package org.apache.aurora.scheduler.http.api;
 
 import javax.inject.Singleton;
-import javax.ws.rs.HttpMethod;
 
-import com.google.common.base.Joiner;
 import com.google.common.collect.ImmutableMap;
 import com.google.inject.Provides;
 import com.google.inject.servlet.ServletModule;
@@ -32,7 +30,6 @@ import org.apache.aurora.scheduler.thrift.aop.AnnotatedAuroraAdmin;
 import org.apache.thrift.protocol.TJSONProtocol;
 import org.apache.thrift.server.TServlet;
 import org.eclipse.jetty.servlet.DefaultServlet;
-import org.eclipse.jetty.servlets.GzipFilter;
 import org.eclipse.jetty.util.resource.Resource;
 
 public class ApiModule extends ServletModule {
@@ -58,12 +55,6 @@ public class ApiModule extends ServletModule {
     if (ENABLE_CORS_SUPPORT.get()) {
       filter(API_PATH).through(new CorsFilter(ENABLE_CORS_FOR.get()));
     }
-    // NOTE: GzipFilter is applied only to /api instead of globally because the
-    // Jersey-managed servlets have a conflicting filter applied to them.
-    filter(API_PATH)
-        .through(
-            new GzipFilter(),
-            ImmutableMap.of("methods", Joiner.on(',').join(HttpMethod.GET, HttpMethod.POST)));
     serve(API_PATH).with(TServlet.class);
 
     filter(ApiBeta.PATH, ApiBeta.PATH + "/*").through(LeaderRedirectFilter.class);

http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/src/test/java/org/apache/aurora/scheduler/http/RequestLoggerTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/aurora/scheduler/http/RequestLoggerTest.java b/src/test/java/org/apache/aurora/scheduler/http/RequestLoggerTest.java
deleted file mode 100644
index a2f786a..0000000
--- a/src/test/java/org/apache/aurora/scheduler/http/RequestLoggerTest.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/**
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.aurora.scheduler.http;
-
-import java.util.Locale;
-import java.util.logging.Level;
-
-import org.apache.aurora.common.quantity.Amount;
-import org.apache.aurora.common.quantity.Time;
-import org.apache.aurora.common.testing.easymock.EasyMockTest;
-import org.apache.aurora.common.util.testing.FakeClock;
-import org.eclipse.jetty.http.HttpHeaders;
-import org.eclipse.jetty.http.HttpURI;
-import org.eclipse.jetty.server.Request;
-import org.eclipse.jetty.server.RequestLog;
-import org.eclipse.jetty.server.Response;
-import org.eclipse.jetty.util.DateCache;
-import org.junit.Before;
-import org.junit.Test;
-
-import static org.apache.aurora.scheduler.http.RequestLogger.LogSink;
-import static org.easymock.EasyMock.expect;
-
-public class RequestLoggerTest extends EasyMockTest {
-
-  private DateCache logDateCache;
-  private FakeClock clock;
-  private LogSink sink;
-  private Request request;
-  private Response response;
-
-  private RequestLog log;
-
-  @Before
-  public void setUp() throws Exception {
-    logDateCache = new DateCache("dd/MMM/yyyy:HH:mm:ss Z", Locale.getDefault());
-    logDateCache.setTimeZoneID("GMT");
-    clock = new FakeClock();
-    sink = createMock(LogSink.class);
-    request = createMock(Request.class);
-    response = createMock(Response.class);
-    log = new RequestLogger(clock, sink);
-  }
-
-  @Test
-  public void testFormat200() throws Exception {
-    clock.advance(Amount.of(40L * 365, Time.DAYS));
-
-    expect(response.getStatus()).andReturn(200).atLeastOnce();
-    expect(request.getServerName()).andReturn("snoopy");
-    expect(request.getHeader(HttpHeaders.X_FORWARDED_FOR)).andReturn(null);
-    expect(request.getMethod()).andReturn("GET");
-    expect(request.getUri()).andReturn(new HttpURI("/"));
-    expect(request.getProtocol()).andReturn("http");
-    expect(response.getContentCount()).andReturn(256L);
-    expect(request.getRemoteAddr()).andReturn("easymock-test");
-    expect(request.getHeader(HttpHeaders.REFERER)).andReturn(null);
-    expect(request.getHeader(HttpHeaders.USER_AGENT)).andReturn("junit");
-    expect(request.getTimeStamp()).andReturn(clock.nowMillis()).atLeastOnce();
-
-    expect(sink.isLoggable(Level.INFO)).andReturn(true);
-
-    String logDate = logDateCache.format(clock.nowMillis());
-    sink.log(Level.INFO, "snoopy easymock-test [" + logDate + "]"
-        + " \"GET / http\" 200 256 \"-\" \"junit\" 110");
-
-    control.replay();
-
-    clock.advance(Amount.of(110L, Time.MILLISECONDS));
-    log.log(request, response);
-  }
-
-  @Test
-  public void testFormat500() throws Exception {
-    clock.advance(Amount.of(40L * 365, Time.DAYS));
-
-    expect(response.getStatus()).andReturn(500).atLeastOnce();
-    expect(request.getServerName()).andReturn("woodstock");
-    expect(request.getHeader(HttpHeaders.X_FORWARDED_FOR)).andReturn(null);
-    expect(request.getMethod()).andReturn("POST");
-    expect(request.getUri()).andReturn(new HttpURI("/data"));
-    expect(request.getProtocol()).andReturn("http");
-    expect(response.getContentCount()).andReturn(128L);
-    expect(request.getRemoteAddr()).andReturn("easymock-test");
-    expect(request.getHeader(HttpHeaders.REFERER)).andReturn(null);
-    expect(request.getHeader(HttpHeaders.USER_AGENT)).andReturn("junit");
-    expect(request.getTimeStamp()).andReturn(clock.nowMillis()).atLeastOnce();
-
-    expect(sink.isLoggable(Level.WARNING)).andReturn(true);
-
-    String logDate = logDateCache.format(clock.nowMillis());
-    sink.log(Level.WARNING, "woodstock easymock-test [" + logDate + "]"
-        + " \"POST /data http\" 500 128 \"-\" \"junit\" 500");
-
-    control.replay();
-
-    clock.advance(Amount.of(500L, Time.MILLISECONDS));
-    log.log(request, response);
-  }
-}

http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/src/test/java/org/apache/aurora/scheduler/http/ServletFilterTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/aurora/scheduler/http/ServletFilterTest.java b/src/test/java/org/apache/aurora/scheduler/http/ServletFilterTest.java
index 3a18e94..d0c4449 100644
--- a/src/test/java/org/apache/aurora/scheduler/http/ServletFilterTest.java
+++ b/src/test/java/org/apache/aurora/scheduler/http/ServletFilterTest.java
@@ -51,10 +51,6 @@ public class ServletFilterTest extends JettyServerModuleTest {
     assertContentEncoding(get(path), Optional.of("gzip"));
   }
 
-  private void assertGzipEncodedPost(String path, String body) {
-    assertContentEncoding(post(path, body), Optional.of("gzip"));
-  }
-
   @Test
   public void testGzipEncoding() throws Exception {
     replayAndStart();

http://git-wip-us.apache.org/repos/asf/aurora/blob/fe9b4602/src/test/sh/org/apache/aurora/e2e/test_kerberos_end_to_end.sh
----------------------------------------------------------------------
diff --git a/src/test/sh/org/apache/aurora/e2e/test_kerberos_end_to_end.sh b/src/test/sh/org/apache/aurora/e2e/test_kerberos_end_to_end.sh
index 82ff868..ecb3d3f 100755
--- a/src/test/sh/org/apache/aurora/e2e/test_kerberos_end_to_end.sh
+++ b/src/test/sh/org/apache/aurora/e2e/test_kerberos_end_to_end.sh
@@ -116,9 +116,9 @@ function test_snapshot {
 
 function test_h2console {
   h2console_as vagrant
-  grep -q 'Error 401 Unauthorized' h2console-response.vagrant.json
+  grep -q 'Error 401' h2console-response.vagrant.json
   h2console_as unpriv
-  grep -q 'Error 401 Unauthorized' h2console-response.unpriv.json
+  grep -q 'Error 401' h2console-response.unpriv.json
   h2console_as root
   grep -q 'Welcome to H2' h2console-response.root.json
 }


Mime
View raw message