hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arun C Murthy <...@yahoo-inc.com>
Subject Re: Review Request: HADOOP-7104 Remove unnecessary DNS reverse lookups from RPC layer
Date Fri, 14 Jan 2011 01:12:39 GMT
Hey Todd,

  We were discussing redirecting these to the jira itself. Do you know  
what happened?

  I'm finding it really hard to follow both jira and these. Is there  
an INFRA ticket you know about?

thanks,
Arun

On Jan 13, 2011, at 4:57 PM, Todd Lipcon wrote:

>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/316/#review106
> -----------------------------------------------------------
>
>
>
> trunk/src/test/core/org/apache/hadoop/security/TestSecurityUtil.java
> <https://reviews.apache.org/r/316/#comment217>
>
>    I think this test case could be improved a few ways:
>
>    - Rather than actually rely on forward/reverse DNS for the  
> localhost matching up in the test case, you can do something like:
>
>    private InetAddress mockAddr(String reverseTo) {
>      InetAddress mock = Mockito.mock(InetAddress.class);
>      doReturn(reverseTo).when(mock).getCanonicalHostName();
>      return mock;
>    }
>
>    then for the test:
>
>    verify("hdfs/_HOST@REALM", mockAddr("foohost"), "hdfs/ 
> foohost@REALM");
>
>    - another useful test to make sure reverse DNS doesn't happen:
>
>    InetAddress mock = Mockito.mock(InetAddress.class);
>    verify("hdfs/specifiedhost@REALM", mock, "hdfs/ 
> specifiedhost@REALM");
>    Mockito.verify(mock, Mockito.never()).getCanonicalHostName();
>
>    This should hopefully make the tests less fussy on hudson boxes  
> where experience shows DNS is often screwy.
>
>    - Need to test the newly allowed case for hdfs@REALM instead of  
> hdfs/...@REALM, right?
>
>
> - Todd
>
>
> On 2011-01-13 16:02:16, Todd Lipcon wrote:
>>
>> -----------------------------------------------------------
>> This is an automatically generated e-mail. To reply, visit:
>> https://reviews.apache.org/r/316/
>> -----------------------------------------------------------
>>
>> (Updated 2011-01-13 16:02:16)
>>
>>
>> Review request for hadoop-common.
>>
>>
>> Summary
>> -------
>>
>> Patch from HADOOP-7104 (written by Kan)
>>
>>
>> This addresses bug HADOOP-7104.
>>    https://issues.apache.org/jira/browse/HADOOP-7104
>>
>>
>> Diffs
>> -----
>>
>>  trunk/src/java/org/apache/hadoop/ipc/Client.java 1058749
>>  trunk/src/java/org/apache/hadoop/ipc/Server.java 1058749
>>  trunk/src/java/org/apache/hadoop/security/SecurityUtil.java 1058749
>>  trunk/src/java/org/apache/hadoop/security/authorize/ 
>> ServiceAuthorizationManager.java 1058749
>>  trunk/src/test/core/org/apache/hadoop/security/ 
>> TestSecurityUtil.java 1058749
>>
>> Diff: https://reviews.apache.org/r/316/diff
>>
>>
>> Testing
>> -------
>>
>>
>> Thanks,
>>
>> Todd
>>
>>
>


Mime
View raw message