[ https://issues.apache.org/jira/browse/DRILL-6106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16340390#comment-16340390 ]
ASF GitHub Bot commented on DRILL-6106: --------------------------------------- Github user vrozov commented on a diff in the pull request: https://github.com/apache/drill/pull/1099#discussion_r164012734 --- Diff: exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigClient.java --- @@ -94,7 +94,7 @@ private String getStringProperty(String name, String defaultValue) { private int getIntProperty(String name, int defaultValue) { int value = defaultValue; if ( (properties != null) && (properties.containsKey(name))) { - value = new Integer(properties.getProperty(name)).intValue(); + value = Integer.valueOf(properties.getProperty(name)).intValue(); --- End diff -- ``` if (properties != null) { String property = properties.getProperty(name); if (property != null && property.length() > 0) { value = Integer.decode(property); } ``` > Use valueOf method instead of constructor since valueOf has a higher > performance by caching frequently requested values. > ------------------------------------------------------------------------------------------------------------------------ > > Key: DRILL-6106 > URL: https://issues.apache.org/jira/browse/DRILL-6106 > Project: Apache Drill > Issue Type: Improvement > Reporter: Reudismam Rolim de Sousa > Priority: Minor > > Use valueOf method instead of constructor since valueOf has a higher > performance by caching frequently requested values. -- This message was sent by Atlassian JIRA (v7.6.3#76005)