[ 
https://issues.apache.org/jira/browse/HADOOP-12474?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14955529#comment-14955529
 ] 

Hadoop QA commented on HADOOP-12474:
------------------------------------

\\
\\
| (/) *{color:green}+1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
| {color:blue}0{color} | pre-patch |   7m  6s | Pre-patch trunk compilation is 
healthy. |
| {color:green}+1{color} | @author |   0m  0s | The patch does not contain any 
@author tags. |
| {color:green}+1{color} | tests included |   0m  0s | The patch appears to 
include 1 new or modified test files. |
| {color:green}+1{color} | javac |   8m 57s | There were no new javac warning 
messages. |
| {color:green}+1{color} | release audit |   0m 24s | The applied patch does 
not increase the total number of release audit warnings. |
| {color:green}+1{color} | checkstyle |   0m 25s | There were no new checkstyle 
issues. |
| {color:green}+1{color} | whitespace |   0m  0s | The patch has no lines that 
end in whitespace. |
| {color:green}+1{color} | install |   1m 39s | mvn install still works. |
| {color:green}+1{color} | eclipse:eclipse |   0m 39s | The patch built with 
eclipse:eclipse. |
| {color:green}+1{color} | findbugs |   0m 48s | The patch does not introduce 
any new Findbugs (version 3.0.0) warnings. |
| {color:green}+1{color} | common tests |   1m 42s | Tests passed in 
hadoop-kms. |
| | |  21m 45s | |
\\
\\
|| Subsystem || Report/Notes ||
| Patch URL | 
http://issues.apache.org/jira/secure/attachment/12766383/HADOOP-12474.001.patch 
|
| Optional Tests | javac unit findbugs checkstyle |
| git revision | trunk / 6716f15 |
| hadoop-kms test log | 
https://builds.apache.org/job/PreCommit-HADOOP-Build/7803/artifact/patchprocess/testrun_hadoop-kms.txt
 |
| Test Results | 
https://builds.apache.org/job/PreCommit-HADOOP-Build/7803/testReport/ |
| Java | 1.7.0_55 |
| uname | Linux asf901.gq1.ygridcore.net 3.13.0-36-lowlatency #63-Ubuntu SMP 
PREEMPT Wed Sep 3 21:56:12 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux |
| Console output | 
https://builds.apache.org/job/PreCommit-HADOOP-Build/7803/console |


This message was automatically generated.

> Fix data race when allocating server port in MiniKMS 
> -----------------------------------------------------
>
>                 Key: HADOOP-12474
>                 URL: https://issues.apache.org/jira/browse/HADOOP-12474
>             Project: Hadoop Common
>          Issue Type: Bug
>            Reporter: Mingliang Liu
>            Assignee: Mingliang Liu
>         Attachments: HADOOP-12474.000.patch, HADOOP-12474.001.patch
>
>
> In {{MiniKMS}}, there is potential data race when create jetty server in 
> {{createJettyServer}}. It looks like the code searches for a free port and 
> then starts jetty, but maybe there's enough of a race condition between port 
> location and jetty.start to cause intermittent failures.
> {code}
>       ServerSocket ss = new ServerSocket((inPort < 0) ? 0 : inPort, 50, 
> localhost);
>       int port = ss.getLocalPort();
>       Server server = new Server(0);
>       if (!ssl) {
>         server.getConnectors()[0].setHost(host);
>         server.getConnectors()[0].setPort(port);
>       } else {
>         ...
>         c.setPort(port);
> {code}
> We've seen test failures saying {{java.net.BindException: Address already in 
> use}}, e.g. 
> [https://builds.apache.org/job/PreCommit-HDFS-Build/12942/testReport/]
> As in [HADOOP-12417], we should always bind port 0 which gives us an 
> ephemeral port, instead of searching a free port before starting jetty.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to