Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-12655

TestHttpServer.testBindAddress bind port range is wider than expected

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.9.0, 3.0.0-alpha1
    • 2.9.0, 3.0.0-alpha1
    • None
    • Jenkins

    Description

      Saw it in a pre-commit jenkins job https://builds.apache.org/job/PreCommit-HADOOP-Build/8242/testReport/org.apache.hadoop.http/TestHttpServer/testBindAddress/

      It also appeared previously in Hadoop-common-trunk-Java8 jenkins on Oct 21.

      In the following case, the first server bound to port 53212, and the second one bound to port 53225, which violated the assertion in the test case (the second port is supposed to be no more than the first + 8)

      Stacktrace
      
      java.lang.AssertionError: null
      	at org.junit.Assert.fail(Assert.java:86)
      	at org.junit.Assert.assertTrue(Assert.java:41)
      	at org.junit.Assert.assertTrue(Assert.java:52)
      	at org.apache.hadoop.http.TestHttpServer.checkBindAddress(TestHttpServer.java:539)
      	at org.apache.hadoop.http.TestHttpServer.testBindAddress(TestHttpServer.java:503)
      
      
      Standard Output
      
      2015-12-15 05:26:44,123 INFO  server.AuthenticationFilter (AuthenticationFilter.java:constructSecretProvider(304)) - Unable to initialize FileSignerSecretProvider, falling back to use random secrets.
      2015-12-15 05:26:44,125 INFO  http.HttpRequestLog (HttpRequestLog.java:getRequestLog(80)) - Http request log for http.requests.test is not defined
      2015-12-15 05:26:44,126 INFO  http.HttpServer2 (HttpServer2.java:addGlobalFilter(701)) - Added global filter 'safety' (class=org.apache.hadoop.http.HttpServer2$QuotingInputFilter)
      2015-12-15 05:26:44,127 INFO  http.HttpServer2 (HttpServer2.java:addFilter(676)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context test
      2015-12-15 05:26:44,128 INFO  http.HttpServer2 (HttpServer2.java:addFilter(684)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context static
      2015-12-15 05:26:44,128 INFO  http.HttpServer2 (HttpServer2.java:addFilter(684)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context logs
      2015-12-15 05:26:44,131 INFO  http.HttpServer2 (HttpServer2.java:openListeners(906)) - Jetty bound to port 41406
      2015-12-15 05:26:44,155 INFO  server.AuthenticationFilter (AuthenticationFilter.java:constructSecretProvider(304)) - Unable to initialize FileSignerSecretProvider, falling back to use random secrets.
      2015-12-15 05:26:44,157 INFO  http.HttpRequestLog (HttpRequestLog.java:getRequestLog(80)) - Http request log for http.requests.test is not defined
      2015-12-15 05:26:44,158 INFO  http.HttpServer2 (HttpServer2.java:addGlobalFilter(701)) - Added global filter 'safety' (class=org.apache.hadoop.http.HttpServer2$QuotingInputFilter)
      2015-12-15 05:26:44,159 INFO  http.HttpServer2 (HttpServer2.java:addFilter(676)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context test
      2015-12-15 05:26:44,159 INFO  http.HttpServer2 (HttpServer2.java:addFilter(684)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context static
      2015-12-15 05:26:44,160 INFO  http.HttpServer2 (HttpServer2.java:addFilter(684)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context logs
      2015-12-15 05:26:44,161 INFO  http.HttpServer2 (HttpServer2.java:openListeners(906)) - Jetty bound to port 53212
      2015-12-15 05:26:44,188 INFO  server.AuthenticationFilter (AuthenticationFilter.java:constructSecretProvider(304)) - Unable to initialize FileSignerSecretProvider, falling back to use random secrets.
      2015-12-15 05:26:44,189 INFO  http.HttpRequestLog (HttpRequestLog.java:getRequestLog(80)) - Http request log for http.requests.test is not defined
      2015-12-15 05:26:44,190 INFO  http.HttpServer2 (HttpServer2.java:addGlobalFilter(701)) - Added global filter 'safety' (class=org.apache.hadoop.http.HttpServer2$QuotingInputFilter)
      2015-12-15 05:26:44,191 INFO  http.HttpServer2 (HttpServer2.java:addFilter(676)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context test
      2015-12-15 05:26:44,191 INFO  http.HttpServer2 (HttpServer2.java:addFilter(684)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context static
      2015-12-15 05:26:44,192 INFO  http.HttpServer2 (HttpServer2.java:addFilter(684)) - Added filter static_user_filter (class=org.apache.hadoop.http.lib.StaticUserWebFilter$StaticUserFilter) to context logs
      2015-12-15 05:26:45,500 INFO  http.HttpServer2 (HttpServer2.java:openListeners(906)) - Jetty bound to port 53225
      
      

      Attachments

        1. HADOOP-12655.001.patch
          0.9 kB
          Wei-Chiu Chuang

        Activity

          People

            weichiu Wei-Chiu Chuang
            weichiu Wei-Chiu Chuang
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: