You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@tajo.apache.org by "DaeMyung Kang (JIRA)" <ji...@apache.org> on 2014/11/13 16:36:33 UTC

[jira] [Created] (TAJO-1173) Add size 8 instead of 4 For ServerName

DaeMyung Kang created TAJO-1173:
-----------------------------------

             Summary: Add size 8 instead of 4 For ServerName
                 Key: TAJO-1173
                 URL: https://issues.apache.org/jira/browse/TAJO-1173
             Project: Tajo
          Issue Type: Improvement
          Components: tajo master
            Reporter: DaeMyung Kang
            Assignee: DaeMyung Kang
            Priority: Trivial


In tajo-core/src/main/java/org/apache/tajo/master/cluster/ServerName.java.
In getServerName, Creating StringBuilder With (hostName.length() + 4)

but like below, it is short, so it call internally newCapacity() if port size is larger than 3


     name.append(hostName); //+hostName.length()
     name.append(SERVERNAME_SEPARATOR); //+1
     name.append(port); //port range is 0 <= port range <= 65535

so this patch. prevent newCapacity() internally doing allocating proper size.

but. It just change value from 4 to 8(to cover port range 65535)
It passed testcases.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)