> On Jan. 13, 2015, 7:36 a.m., Veena Basavaraj wrote:
> > connector/connector-sdk/src/main/java/org/apache/sqoop/connector/matcher/NameMatcher.java,
> >  line 38
> > <https://reviews.apache.org/r/29849/diff/1/?file=818952#file818952line38>
> >
> >     while youa re please fix the , it should be Too few? not sure I 
> > understand this 
> >     
> >     public enum MatcherError implements ErrorCode {
> >       MATCHER_0000("To few Schemas provided."),
> >     
> >       ;
> >       
> >       Second, why only change this to an exception in Name and not in 
> > LocationMatcher?

on second look at the code it is even unnecessary to check for empty, please 
drop it

public class MatcherFactory {
  public static Matcher getMatcher(Schema fromSchema, Schema toSchema) {
    if (toSchema.isEmpty() || fromSchema.isEmpty()) {
      return new LocationMatcher(fromSchema, toSchema);
    } else {
      return new NameMatcher(fromSchema, toSchema);
    }
  }
}


- Veena


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


On Jan. 13, 2015, 7:14 a.m., Qian Xu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29849/
> -----------------------------------------------------------
> 
> (Updated Jan. 13, 2015, 7:14 a.m.)
> 
> 
> Review request for Sqoop.
> 
> 
> Bugs: SQOOP-1988
>     https://issues.apache.org/jira/browse/SQOOP-1988
> 
> 
> Repository: sqoop-sqoop2
> 
> 
> Description
> -------
> 
> see jira
> 
> 
> Diffs
> -----
> 
>   
> connector/connector-sdk/src/main/java/org/apache/sqoop/connector/matcher/LocationMatcher.java
>  d92723e 
>   
> connector/connector-sdk/src/main/java/org/apache/sqoop/connector/matcher/Matcher.java
>  36ac5a5 
>   
> connector/connector-sdk/src/main/java/org/apache/sqoop/connector/matcher/NameMatcher.java
>  7cbc39f 
>   
> connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestLocationMatcher.java
>  624fa7b 
>   
> connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestNameMatcher.java
>  76ff0da 
> 
> Diff: https://reviews.apache.org/r/29849/diff/
> 
> 
> Testing
> -------
> 
> Existing tests passed 
> 
> 
> Thanks,
> 
> Qian Xu
> 
>

Reply via email to