> On March 11, 2015, 8:28 a.m., Madhan Neethiraj wrote:
> > hdfs-agent/src/test/java/org/apache/ranger/services/hdfs/client/HdfsClientTest.java,
> >  line 127
> > <https://reviews.apache.org/r/31874/diff/1/?file=889881#file889881line127>
> >
> >     Wouldn't this test fail in connecting to namenode (i.e. use of 
> > node-2.example.com)? Please review other such tests as well.

Please see the whole body of the test method, lines 115 through 129.

 @Test
  public void testValidNonHaConfig()  throws IllegalArgumentException {

    // username: hdfsuser
    // password: hdfsuser
    // hadoop.security.authentication: simple
    // fs.default.name: hdfs://node-2.example.com:8020

    Map configs = new HashMap<String, String>();
    configs.put("username", "hdfsuser");
    configs.put("password", "hdfsuser");
    configs.put("hadoop.security.authentication", "simple");
    configs.put("fs.default.name", "hdfs://node-2.example.com:8020");
    HdfsClient.validateConnectionConfigs(configs);
  }

This is unit test case for NonHa as the test case name testValidNonHaConfig() 
indicates.

The unit test case validates only for valid combinations of parameters, not 
connecting to the back end server.


- dilli


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/31874/#review76054
-----------------------------------------------------------


On March 10, 2015, 12:39 a.m., dilli dorai wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/31874/
> -----------------------------------------------------------
> 
> (Updated March 10, 2015, 12:39 a.m.)
> 
> 
> Review request for ranger.
> 
> 
> Bugs: RANGER-293
>     https://issues.apache.org/jira/browse/RANGER-293
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> RANGER-293: add server side checks for HDFS Repo connection properties
> 
> 
> Diffs
> -----
> 
>   
> hdfs-agent/src/main/java/org/apache/ranger/services/hdfs/client/HdfsClient.java
>  03f8124 
>   
> hdfs-agent/src/test/java/org/apache/ranger/services/hdfs/client/HdfsClientTest.java
>  PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/31874/diff/
> 
> 
> Testing
> -------
> 
> Ran the newly added unit tests in 
> hdfs-agent/src/test/java/org/apache/ranger/services/hdfs/client/HdfsClientTest.java
> 
> Tested manually with ranger-admin ui
> 
> 
> Thanks,
> 
> dilli dorai
> 
>

Reply via email to