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

Zoltan Haindrich commented on HIVE-21228:
-----------------------------------------

I'm not sure but around here: 
{code}
@@ -144,10 +144,6 @@ private void createEncryptionZone(String[] params) throws 
Exception {
 
     String keyName = args.getOptionValue("keyName");
     Path cryptoZone = new Path(args.getOptionValue("path"));
-    if (cryptoZone == null) {
-      throw new Exception("Cannot create encryption zone: Invalid path '"
-          + args.getOptionValue("path") + "'");
-    }
{code}

I believe the original intention might be to check that path was set or not?
The check was most probably not working (unless Path throw excpetion for null 
argument)... but could we fix it?

misc:

* I'm not sure in which cases 
beeline/src/java/org/apache/hive/beeline/Reflector.java is used; but it seems 
like interprets "TRUe" as false.
* in hplsql/src/main/java/org/apache/hive/hplsql/functions/FunctionMisc we 
could use lambda


> Replace all occurences of new Integer with Integer.valueOf
> ----------------------------------------------------------
>
>                 Key: HIVE-21228
>                 URL: https://issues.apache.org/jira/browse/HIVE-21228
>             Project: Hive
>          Issue Type: Improvement
>            Reporter: Ivan Suller
>            Assignee: Ivan Suller
>            Priority: Trivial
>         Attachments: HIVE-21228.01.patch, HIVE-21228.02.patch
>
>
> Creating Integer objects with new Integer(...) creates a new object, while 
> Integer.valueOf(...) can be cached (and is actually cached in most if not all 
> JVMs) thus reducing GC overhead.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to