[
https://issues.apache.org/jira/browse/CXF-6009?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Sergey Beryozkin resolved CXF-6009.
-----------------------------------
Resolution: Fixed
thanks...
> 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)