myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leonardo Uribe (JIRA)" <...@myfaces.apache.org>
Subject [jira] Resolved: (MYFACES-2804) LifecycleImpl _firstRequestProcessed should be marked as volatile
Date Fri, 09 Jul 2010 22:36:50 GMT

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

Leonardo Uribe resolved MYFACES-2804.
-------------------------------------

    Fix Version/s: 2.0.1-SNAPSHOT
       Resolution: Fixed

> LifecycleImpl _firstRequestProcessed should be marked as volatile
> -----------------------------------------------------------------
>
>                 Key: MYFACES-2804
>                 URL: https://issues.apache.org/jira/browse/MYFACES-2804
>             Project: MyFaces Core
>          Issue Type: Improvement
>          Components: JSR-314
>    Affects Versions: 2.0.0
>            Reporter: Leonardo Uribe
>            Assignee: Leonardo Uribe
>             Fix For: 2.0.1-SNAPSHOT
>
>
> Checking how _firstRequestProcessed works, I notice we can do some enhancements LifecycleImpl
and LifecycleFactoryImpl. In both classes, we use synchronized blocks to access common methods,
but that is not really necessary, we can do other alternatives like ConcurrentHashMap and
CopyOnWriteArrayList and they will be more effective.
> Note LifecycleImpl instance is shared by multiple threads at the same time, so it must
be thread safe. If we have variables that changes inside it, we must ensure visibility adding
"final" and "volatile" modifiers too when necessary.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message