cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lucas Pouzac (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CXF-6009) Monitor contention at org.apache.cxf.transport.http.Headers
Date Thu, 18 Sep 2014 12:34:33 GMT

     [ https://issues.apache.org/jira/browse/CXF-6009?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Lucas Pouzac updated CXF-6009:
------------------------------
    Attachment: monitor_contention_headers.png

> Monitor contention at org.apache.cxf.transport.http.Headers
> -----------------------------------------------------------
>
>                 Key: CXF-6009
>                 URL: https://issues.apache.org/jira/browse/CXF-6009
>             Project: CXF
>          Issue Type: Improvement
>          Components: Transports
>    Affects Versions: 3.0.1
>            Reporter: Lucas Pouzac
>              Labels: concurrency, perfomance
>             Fix For: 3.0.2, 3.1.0
>
>         Attachments: monitor_contention_headers.png
>
>
> Headers.getHttpDateFormat() indirectly calls TimeZone.getTimeZone("GMT"), which calls
into JRE lib method causing monitor contention. See screen shot
> Fix by instantiate into static variable.
> {code:java}
>     private static TimeZone tZone = TimeZone.getTimeZone("GMT");
>     public static SimpleDateFormat getHttpDateFormat() {
>         SimpleDateFormat dateFormat = 
>             new SimpleDateFormat("EEE, dd MMM yyyy HH:mm:ss zzz", Locale.US);
>         dateFormat.setTimeZone(tZone);
>         return dateFormat;
>     }
> {code}



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

Mime
View raw message