Hi all, I just created the respective issue ([1]).
As such, I also take this discussion to the dev list. If none objects, I take this over to fix this using the second (Mapper/Evaluator instances per call) in the next few days. Regards Felix [1] http://issues.apache.org/jira/browse/FELIX-338 On 8/14/07, Richard S. Hall <[EMAIL PROTECTED]> wrote: > > Felix Meschberger wrote: > > Hi, > > > > >From what I see, the FilterImpl.match() methods are not synchronized > yet > > a single instance for the Mapper and Evaluator. I think, either the > > match() methods should synchronize or the Mapper and Evaluator instances > > should be created for each call to match. > > > > Yes, I think your evaluation is correct...this needs to be fixed. > > > I assume, the second solution (creating new instances on each call) > > would probably be better as synchronization overhead tends to be more > > heavy weight than memory allocation. > > > > I don't really know which would be better. This could end up getting > called a lot. > > One benefit of creating new Mapper/Evaluator instances each time is that > it would clean up some ugliness in setting references to null to enable > garbage collection. > > Another benefit of new instances is that it would allow for more > parallelism, but I am not sure this is super important. > > Does any one have any input on what is the better approach? > > Was a JIRA issue created for this? > > -> richard > > > Regards > > Felix > > > > Am Dienstag, den 31.07.2007, 14:05 +0200 schrieb Tom Remoleur: > > > >> Hello everybody, > >> > >> Since I'm using felix with lot of bundle, sometimes I've got a rare > bug, > >> but I was never able to reproduct him. > >> But yesterday I've finally caught it. According to the stack trace, I > >> think that is a synchronization issue : > >> Here two services are registred at same time from two differents > threads > >> (configuration admin update thread and bundle initialisation thread), > but > >> when firing event to ServiceListener, the same filter is evaluated by > the > >> two threads at same time, resulting in errors (but as you can see the > >> filter is correct) > >> > >> I'm sorry for the few informations avalaible but it's an occasional > >> problem and I can't easily debug it. > >> > >> SEVERE: ERROR : FilterImpl: > >> (&(objectClass= > fr.u_strasbg.clarinet.stork.service.cli.CLICommandContextService > )(Context=ShellConf)) > >> org.apache.felix.log.impl.LogException: > >> org.apache.felix.framework.util.ldap.EvaluationException: > >> Evaluation.evalute: final stack has more than one result > >> at > >> org.apache.felix.framework.util.ldap.Evaluator.evaluate(Evaluator.java > :128) > >> at org.apache.felix.framework.FilterImpl.match(FilterImpl.java > :167) > >> at > >> > org.apache.felix.framework.util.EventDispatcher.invokeServiceListenerCallback > (EventDispatcher.java:717) > >> at > >> org.apache.felix.framework.util.EventDispatcher.fireEventImmediately( > EventDispatcher.java:593) > >> at > >> org.apache.felix.framework.util.EventDispatcher.fireServiceEvent( > EventDispatcher.java:525) > >> at org.apache.felix.framework.Felix.fireServiceEvent(Felix.java > :3510) > >> at org.apache.felix.framework.Felix.access$000(Felix.java:36) > >> at org.apache.felix.framework.Felix$1.serviceChanged(Felix.java > :576) > >> at > >> org.apache.felix.framework.ServiceRegistry.fireServiceChanged( > ServiceRegistry.java:435) > >> at > >> org.apache.felix.framework.ServiceRegistry.registerService( > ServiceRegistry.java:71) > >> at org.apache.felix.framework.Felix.registerService(Felix.java > :2637) > >> at > >> org.apache.felix.framework.BundleContextImpl.registerService( > BundleContextImpl.java:254) > >> at > >> org.apache.felix.framework.BundleContextImpl.registerService( > BundleContextImpl.java:232) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.registerService( > ServiceImpl.java:610) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.activateService( > ServiceImpl.java:408) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.access$000( > ServiceImpl.java:41) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl$3.run(ServiceImpl.java > :110) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor$1.run( > SerialExecutor.java:29) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor.scheduleNext( > SerialExecutor.java:66) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor.execute( > SerialExecutor.java:50) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.calculateStateChanges( > ServiceImpl.java:132) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.start(ServiceImpl.java > :241) > >> at > >> org.apache.felix.dependencymanager.DependencyManager.add( > DependencyManager.java:53) > >> at > >> > fr.u_strasbg.clarinet.stork.impl.deviceconfig.ethernet.EthernetDeviceCategoryServiceImpl.deviceExist > (EthernetDeviceCategoryServiceImpl.java:250) > >> at > >> > fr.u_strasbg.clarinet.stork.impl.deviceconfig.ethernet.EthernetDeviceCategoryServiceImpl.addDevice > (EthernetDeviceCategoryServiceImpl.java:203) > >> at > >> > fr.u_strasbg.clarinet.stork.impl.deviceconfig.vlan.VlanFactoryServiceImpl.createVlan > (VlanFactoryServiceImpl.java:279) > >> at > >> > fr.u_strasbg.clarinet.stork.impl.deviceconfig.vlan.VlanFactoryServiceImpl.updated > (VlanFactoryServiceImpl.java:197) > >> at > >> > org.apache.felix.cm.impl.ConfigurationManager$ManagedServiceFactoryUpdate.run > (ConfigurationManager.java:975) > >> at org.apache.felix.cm.impl.UpdateThread.run(UpdateThread.java:89) > >> Jul 30, 2007 4:59:48 PM > fr.u_strasbg.clarinet.stork.utils.common.APLogger > >> error > >> SEVERE: ERROR : FilterImpl: > >> (&(objectClass= > fr.u_strasbg.clarinet.stork.service.cli.CLICommandContextService > )(Context=ShellConf)) > >> org.apache.felix.log.impl.LogException: > >> org.apache.felix.framework.util.ldap.EvaluationException: AND: too few > >> operands > >> at > >> org.apache.felix.framework.util.ldap.Parser.fewOperands(Parser.java > :1710) > >> at org.apache.felix.framework.util.ldap.Parser.access$000( > Parser.java:27) > >> at > >> org.apache.felix.framework.util.ldap.Parser$AndOperator.execute( > Parser.java:545) > >> at > >> org.apache.felix.framework.util.ldap.Evaluator.evaluate(Evaluator.java > :92) > >> at org.apache.felix.framework.FilterImpl.match(FilterImpl.java > :167) > >> at > >> > org.apache.felix.framework.util.EventDispatcher.invokeServiceListenerCallback > (EventDispatcher.java:717) > >> at > >> org.apache.felix.framework.util.EventDispatcher.fireEventImmediately( > EventDispatcher.java:593) > >> at > >> org.apache.felix.framework.util.EventDispatcher.fireServiceEvent( > EventDispatcher.java:525) > >> at org.apache.felix.framework.Felix.fireServiceEvent(Felix.java > :3510) > >> at org.apache.felix.framework.Felix.access$000(Felix.java:36) > >> at org.apache.felix.framework.Felix$1.serviceChanged(Felix.java > :576) > >> at > >> org.apache.felix.framework.ServiceRegistry.fireServiceChanged( > ServiceRegistry.java:435) > >> at > >> org.apache.felix.framework.ServiceRegistry.registerService( > ServiceRegistry.java:71) > >> at org.apache.felix.framework.Felix.registerService(Felix.java > :2637) > >> at > >> org.apache.felix.framework.BundleContextImpl.registerService( > BundleContextImpl.java:254) > >> at > >> org.apache.felix.framework.BundleContextImpl.registerService( > BundleContextImpl.java:232) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.registerService( > ServiceImpl.java:610) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.activateService( > ServiceImpl.java:408) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.access$000( > ServiceImpl.java:41) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl$1.run(ServiceImpl.java > :98) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor$1.run( > SerialExecutor.java:29) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor.scheduleNext( > SerialExecutor.java:66) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor.access$000( > SerialExecutor.java:15) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor$1.run( > SerialExecutor.java:32) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor.scheduleNext( > SerialExecutor.java:66) > >> at > >> org.apache.felix.dependencymanager.SerialExecutor.execute( > SerialExecutor.java:50) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.calculateStateChanges( > ServiceImpl.java:132) > >> at > >> org.apache.felix.dependencymanager.ServiceImpl.start(ServiceImpl.java > :241) > >> at > >> org.apache.felix.dependencymanager.DependencyManager.add( > DependencyManager.java:53) > >> at > >> > fr.u_strasbg.clarinet.stork.impl.deviceconfig.vlan.VlanDeviceActivator.init > (VlanDeviceActivator.java:80) > >> at > >> org.apache.felix.dependencymanager.DependencyActivatorBase.start( > DependencyActivatorBase.java:74) > >> at > >> org.apache.felix.framework.util.SecureAction.startActivator( > SecureAction.java:589) > >> at org.apache.felix.framework.Felix._startBundle(Felix.java:1535) > >> at org.apache.felix.framework.Felix.startBundle(Felix.java:1469) > >> at > >> org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java > :1064) > >> at org.apache.felix.framework.StartLevelImpl.run( > StartLevelImpl.java:258) > >> at java.lang.Thread.run(Unknown Source) > >> > >> > >> Tom > >> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
