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

Karl Pauls reassigned FELIX-338:
--------------------------------

    Assignee: Karl Pauls

Yes, I admit that it is always tricky to do performance test. All I can say is 
that for me the ThreadLocal version runs faster. One issue might be how many 
native threads your system supports. In case you use much more threads then you 
really have parallelism must go done. The above, I see on a MacBook Pro with a 
dual core 2.4 Ghz Intel and under a SunVM under Windows (but that is under 
VMWare). It is almost the same for 2, 4, and 8 threads but approaches 0 quickly 
after (at 64 threads I don't see any difference anymore).    

I'll go ahead and commit this patch now so that we have a fix in place. 
However, I agree with your point that we should look at the ldap code again to 
see whether we can clean it up some more. Let's pick that up again once we have 
a bug fix release out of the door.

> Framework FilterImpl is not thread safe on execution
> ----------------------------------------------------
>
>                 Key: FELIX-338
>                 URL: https://issues.apache.org/jira/browse/FELIX-338
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: 0.8.0, 1.0.0
>            Reporter: Felix Meschberger
>            Assignee: Karl Pauls
>         Attachments: filter.patch, FilterImpl_rewrite.patch
>
>
> Executing a Filter implemented by the Felix Framework FilterImpl class is not 
> thread safe, as the Filter.Implmatch() methods are not synchronized but use a 
> Mapper and Evaluator instance fields which are modified while matching the 
> filter.
> Two options seem to exist:
>    1. Make the match() methods synchronized
>    2. Create Mapper and Evaluator instances on each match() call
> My assumption is that the second method tends to be better because of the 
> synchronization needed with the first approach.
> Reported by Tom Remoleur, thanks. The full mail thread leading to this issue 
> may be found at [1].
> [1] http://www.mail-archive.com/[EMAIL PROTECTED]/msg00145.html

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

Reply via email to