You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ranger.apache.org by Ramesh Mani <rm...@hortonworks.com> on 2017/04/04 01:12:24 UTC
Review Request 58165: RANGER-1495: Good coding practices
recommendation by static code analysis
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/58165/
-----------------------------------------------------------
Review request for ranger, Abhay Kulkarni, Madhan Neethiraj, and Velmurugan Periasamy.
Bugs: RANGER-1495
https://issues.apache.org/jira/browse/RANGER-1495
Repository: ranger
Description
-------
RANGER-1495: Good coding practices recommendation by static code analysis
Diffs
-----
hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java 6cc62a7
Diff: https://reviews.apache.org/r/58165/diff/1/
Testing
-------
Testing done in VM
Thanks,
Ramesh Mani
Re: Review Request 58165: RANGER-1495: Good coding practices
recommendation by static code analysis
Posted by Velmurugan Periasamy <vp...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/58165/#review171030
-----------------------------------------------------------
Fix it, then Ship it!
hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java
Lines 407 (patched)
<https://reviews.apache.org/r/58165/#comment243862>
This patch is not applying on ranger-0.7 (applies on master though)
If you are planning to add this on 0.7.1, please fix and commit.
```
$ git apply --check -v < ~/Downloads/0001-RANGER-1495-Good-coding-practices-recommedation-by-s.patch
Checking patch hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java...
error: while searching for:
for (String tbl : tblList) {
try {
List<FieldSchema> hiveSch = hiveClient.getFields(db, tbl);
for (FieldSchema sch : hiveSch) {
String columnName = sch.getName();
if (colList != null && colList.contains(columnName)) {
continue;
}
if (columnNameMatchingRegEx == null) {
ret.add(columnName);
}
else if (FilenameUtils.wildcardMatch(columnName,columnNameMatchingRegEx)) {
ret.add(columnName);
}
}
} catch (TException e) {
error: patch failed: hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java:404
error: hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java: patch does not apply
```
- Velmurugan Periasamy
On April 4, 2017, 1:12 a.m., Ramesh Mani wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/58165/
> -----------------------------------------------------------
>
> (Updated April 4, 2017, 1:12 a.m.)
>
>
> Review request for ranger, Abhay Kulkarni, Madhan Neethiraj, and Velmurugan Periasamy.
>
>
> Bugs: RANGER-1495
> https://issues.apache.org/jira/browse/RANGER-1495
>
>
> Repository: ranger
>
>
> Description
> -------
>
> RANGER-1495: Good coding practices recommendation by static code analysis
>
>
> Diffs
> -----
>
> hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java 6cc62a7
>
>
> Diff: https://reviews.apache.org/r/58165/diff/1/
>
>
> Testing
> -------
>
> Testing done in VM
>
>
> Thanks,
>
> Ramesh Mani
>
>