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

Seetharam Venkatesh commented on OOZIE-886:
-------------------------------------------

Few suggestions:

* StringBuilder traceInfo = new StringBuilder(); should be inside if statement, 
else you are creating this object unnecessarily if trace is not enabled

* StringBuilder initial capacity by default is 16 chars & resizes quite a bit. 
You could have had a 1k or 4k buffer to start with but since its trace doesnt 
matter much. :-)

* traceInfo.append("Header Name" + name); should be changed to: 
traceInfo.append("Header").append(name).append("Header Value").append(value);
or traceInfo.append(name).append("=").append(value).append(";"); 
                
> Display request header info when trace is enabled
> -------------------------------------------------
>
>                 Key: OOZIE-886
>                 URL: https://issues.apache.org/jira/browse/OOZIE-886
>             Project: Oozie
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 3.2.0
>            Reporter: Jay Srinivasan
>            Assignee: Jay Srinivasan
>            Priority: Minor
>             Fix For: 3.2.0
>
>         Attachments: OOZIE-886.patch
>
>
> Display request headers when trace is enabled

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to