felix-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pierre De Rop <pierre.de...@gmail.com>
Subject Re: IPojo performance benchmark
Date Sat, 21 Jun 2014 22:13:59 GMT
Hello Clement,

I'm also working on some benchmark related to dependency manager,
declarative service, and after reading this post, I tried to incorporate a
scenario using iPojo in my benchmark.
And it seems that I'm also observing a performance problem.

I will try to commit somewhere my benchmark program soon in my sandbox,
however, I just made a quick jvisualvm, and it looks like I'm spending 95 %
of the time in the
org.apache.felix.ipojo.IPojoFactory$RetryNameGenerator.generate method.

Here is a stacktrace, if this may help:

"Thread-2" #30 prio=5 os_prio=0 tid=0x635f7c00 nid=0x47c1 runnable
[0x62cfd000]
   java.lang.Thread.State: RUNNABLE
        at
org.apache.felix.ipojo.IPojoFactory$RetryNameGenerator.generate(IPojoFactory.java:1149)
        at
org.apache.felix.ipojo.IPojoFactory.createComponentInstance(IPojoFactory.java:302)
        - locked <0x67652198> (a
java.util.Collections$SynchronizedRandomAccessList)
        - locked <0x95055f50> (a org.apache.felix.ipojo.ComponentFactory)
        at
org.apache.felix.ipojo.IPojoFactory.createComponentInstance(IPojoFactory.java:240)
        at
org.apache.felix.ipojo.api.ComponentType.createInstance(ComponentType.java:79)
        at
org.apache.felix.dm.benchmark.ipojo.IPojoActivator$$Lambda$108/3740909.apply(Unknown
Source)
        at
org.apache.felix.dm.benchmark.controller.Helper.lambda$1(Helper.java:85)
        at
org.apache.felix.dm.benchmark.controller.Helper$$Lambda$36/6147827.apply(Unknown
Source)
        at
java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
        at
java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1359)
        at
java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:512)
        at
java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:502)
        at
java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
        at
java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
        at
java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
        at
org.apache.felix.dm.benchmark.ipojo.IPojoActivator.__M_start(IPojoActivator.java:96)
        at
org.apache.felix.dm.benchmark.ipojo.IPojoActivator.start(IPojoActivator.java)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:483)
        at org.apache.felix.ipojo.util.Callback.call(Callback.java:237)
        at org.apache.felix.ipojo.util.Callback.call(Callback.java:193)
        at
org.apache.felix.ipojo.handlers.lifecycle.callback.LifecycleCallback.call(LifecycleCallback.java:86)
        at
org.apache.felix.ipojo.handlers.lifecycle.callback.LifecycleCallbackHandler.__M_stateChanged(LifecycleCallbackHandler.java:162)
        at
org.apache.felix.ipojo.handlers.lifecycle.callback.LifecycleCallbackHandler.stateChanged(LifecycleCallbackHandler.java)
        at
org.apache.felix.ipojo.InstanceManager.setState(InstanceManager.java:560)
        at
org.apache.felix.ipojo.InstanceManager.start(InstanceManager.java:440)
        at
org.apache.felix.ipojo.ComponentFactory.createInstance(ComponentFactory.java:179)
        at
org.apache.felix.ipojo.IPojoFactory.createComponentInstance(IPojoFactory.java:319)
        - locked <0x6e5340d0> (a org.apache.felix.ipojo.ComponentFactory)
        at
org.apache.felix.ipojo.IPojoFactory.createComponentInstance(IPojoFactory.java:240)
        at
org.apache.felix.ipojo.api.ComponentType.createInstance(ComponentType.java:79)
        at
org.apache.felix.dm.benchmark.ipojo.Activator.start(Activator.java:31)
        at
org.apache.felix.framework.util.SecureAction.startActivator(SecureAction.java:645)
        at org.apache.felix.framework.Felix.activateBundle(Felix.java:2152)
        at org.apache.felix.framework.Felix.startBundle(Felix.java:2070)
        at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:976)
        at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:963)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.startAndStop(BenchmarkControllerImpl.java:190)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.lambda$17(BenchmarkControllerImpl.java:104)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl$$Lambda$17/24713481.run(Unknown
Source)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.durationOf(BenchmarkControllerImpl.java:229)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.lambda$11(BenchmarkControllerImpl.java:104)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl$$Lambda$15/17116744.applyAsLong(Unknown
Source)
        at java.util.stream.LongPipeline$2$1.accept(LongPipeline.java:214)
        at
java.util.stream.Streams$RangeLongSpliterator.forEachRemaining(Streams.java:235)
        at
java.util.Spliterator$OfLong.forEachRemaining(Spliterator.java:757)
        at
java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:512)
        at
java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:502)
        at
java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:576)
        at
java.util.stream.AbstractPipeline.evaluateToArrayNode(AbstractPipeline.java:255)
        at java.util.stream.LongPipeline.toArray(LongPipeline.java:484)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.lambda$2(BenchmarkControllerImpl.java:104)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl$$Lambda$14/9086622.accept(Unknown
Source)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.lambda$16(BenchmarkControllerImpl.java:169)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl$$Lambda$11/14120199.accept(Unknown
Source)
        at java.util.Optional.ifPresent(Optional.java:159)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.lambda$4(BenchmarkControllerImpl.java:168)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl$$Lambda$7/32522449.accept(Unknown
Source)
        at
java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948)
        at
java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:580)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.forEachScenarioBundle(BenchmarkControllerImpl.java:166)
        at
org.apache.felix.dm.benchmark.controller.impl.BenchmarkControllerImpl.run(BenchmarkControllerImpl.java:100)
        at java.lang.Thread.run(Thread.java:745)

I'm using latest released ipojo + java8.


(will do my best to commit the benchmark so you can take a look and check
if my test is wrong or if there is really something to be verified
somewhere in IPojo).



cheers;
/Pierre


On Sat, Jun 21, 2014 at 9:49 AM, Clement Escoffier <
clement.escoffier@gmail.com> wrote:

> Hi,
>
> Thanks,
>
> I will have a look at it, and come back to you.
>
> Clement
> On 21 juin 2014 at 09:21:46, Xander Uiterlinden (uiterlix@gmail.com)
> wrote:
>
> Hi,
>
> A colleague of mine just pointed me at this discussion. I'm one of the two
> persons that did the presentation on DM performance on the OSGi devcon.
>
> Regarding iPojo, we included it using the documentation on the site but are
> not iPojo experts. I'd be happy to help in figuring out whether the results
> are due to the tests or to the iPojo implementation itself.
>
> The code is at:
> https://github.com/sandermak/osgi-dm-shootout/tree/master/benchmark
>
> Cheers,
>
> Xander
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message