You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2020/01/14 18:05:00 UTC

[jira] [Commented] (IMPALA-8501) RpcMgrTest.SlowCallback and RpcMgrTest.AsyncCall sometimes have port conflicts

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

ASF subversion and git services commented on IMPALA-8501:
---------------------------------------------------------

Commit c359c557eb299174c43ed0d27ab1c2247fc94f74 in impala's branch refs/heads/master from Thomas Tauber-Marshall
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=c359c55 ]

IMPALA-8501: Fix race condition on port in RpcMgrTest

RpcMgrTest previously would choose a random, unused port when starting
and then eventually start a krpc service on the port. This resulted in
a race condition where the port could be taken by another process
between when it was chosen and when RpcMgrTest actually used it,
causing RpcMgrTest to fail.

This patch significantly reduces the probability of such an error
happening by choosing the port immediately before it is used.

Change-Id: I841196f8557f29816f5f2960f36fc7772233b975
Reviewed-on: http://gerrit.cloudera.org:8080/14997
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>


> RpcMgrTest.SlowCallback and RpcMgrTest.AsyncCall sometimes have port conflicts
> ------------------------------------------------------------------------------
>
>                 Key: IMPALA-8501
>                 URL: https://issues.apache.org/jira/browse/IMPALA-8501
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Backend
>            Reporter: Tim Armstrong
>            Assignee: Thomas Tauber-Marshall
>            Priority: Critical
>              Labels: flaky
>             Fix For: Impala 3.4.0
>
>
> {noformat}
> Failed to add acceptor pool: Network error: error binding socket to 127.0.0.1:55500: Address already in use (error 98)
> {noformat}
> This is running on centos 7.
> It looks like the ephemeral port is searched-for during the startup of the test binary and only used later, so these tests have a bigger race window than others. It would be good to defer finding the ephemeral port until it is about to be used.
> {noformat}
> static int32_t SERVICE_PORT = FindUnusedEphemeralPort();
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org