Announcement Announcement Module
Collapse
No announcement yet.
Performance of multiple splitter/ aggregators Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Performance of multiple splitter/ aggregators

    Hello,

    I have standalone project where im using multiple splitters/ aggregators. I see some slowness in the overall response time ( the time from sending the message to gateway and receiving the response from the final aggregator).
    My question is how do i profile where the time is getting delayed in the integration job ?

    Thanks
    Srini

  • #2
    If you are using STS, the embedded tcServer has Spring Insight (but you have to turn it on). The Spring Integration plugin captures frames that show where the time is being spent.

    Insight is now also available for some other platforms, not just tcServer.

    Spring Insight (and the Spring Integration plugin) is highlighted (along with the JMX support) in this webinar http://www.springsource.org/node/3598

    Comment


    • #3
      Thanks for the tip. I was actually running this as standalone as mentioned, this is outside the server. Is there a way to do it?

      Thanks
      Srini

      Comment


      • #4
        Sorry - missed the word standalone.

        There's nothing out of the box; you could create a global channel inteceptor and capture timestamps as messages pass through each channel.

        If you come up with something interesting, feel free to contribute it back to the community :-)

        Comment


        • #5
          Well i tried to put aspect around the integration module.
          But it complains, please let me know if i need to tweak the package
          Code:
          Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'channelInitializer': Invocation of init method failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name '$autoCreateChannelCandidates': Initialization of bean failed; nested exception is org.springframework.aop.framework.AopConfigException: Could not generate CGLIB subclass of class [class org.springframework.integration.config.xml.ChannelInitializer$AutoCreateCandidatesCollector]: Common causes of this problem include using a final class or a non-visible class; nested exception is java.lang.IllegalArgumentException: Superclass has no null constructors but no arguments were given
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
          	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
          	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
          	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)
          	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
          	at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:609)
          	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918)
          	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:469)
          	at org.springframework.test.context.support.AbstractGenericContextLoader.loadContext(AbstractGenericContextLoader.java:103)
          	at org.springframework.test.context.support.AbstractGenericContextLoader.loadContext(AbstractGenericContextLoader.java:1)
          	at org.springframework.test.context.support.DelegatingSmartContextLoader.loadContext(DelegatingSmartContextLoader.java:228)
          	at org.springframework.test.context.TestContext.loadApplicationContext(TestContext.java:124)
          	at org.springframework.test.context.TestContext.getApplicationContext(TestContext.java:148)
          	... 24 more
          Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name '$autoCreateChannelCandidates': Initialization of bean failed; nested exception is org.springframework.aop.framework.AopConfigException: Could not generate CGLIB subclass of class [class org.springframework.integration.config.xml.ChannelInitializer$AutoCreateCandidatesCollector]: Common causes of this problem include using a final class or a non-visible class; nested exception is java.lang.IllegalArgumentException: Superclass has no null constructors but no arguments were given
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:527)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
          	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
          	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
          	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)
          	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
          	at org.springframework.integration.config.xml.ChannelInitializer.afterPropertiesSet(ChannelInitializer.java:102)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452)
          	... 38 more
          Caused by: org.springframework.aop.framework.AopConfigException: Could not generate CGLIB subclass of class [class org.springframework.integration.config.xml.ChannelInitializer$AutoCreateCandidatesCollector]: Common causes of this problem include using a final class or a non-visible class; nested exception is java.lang.IllegalArgumentException: Superclass has no null constructors but no arguments were given
          	at org.springframework.aop.framework.Cglib2AopProxy.getProxy(Cglib2AopProxy.java:213)
          	at org.springframework.aop.framework.ProxyFactory.getProxy(ProxyFactory.java:112)
          	at org.springframework.aop.framework.autoproxy.AbstractAutoProxyCreator.createProxy(AbstractAutoProxyCreator.java:476)
          	at org.springframework.aop.framework.autoproxy.AbstractAutoProxyCreator.wrapIfNecessary(AbstractAutoProxyCreator.java:362)
          	at org.springframework.aop.framework.autoproxy.AbstractAutoProxyCreator.postProcessAfterInitialization(AbstractAutoProxyCreator.java:322)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsAfterInitialization(AbstractAutowireCapableBeanFactory.java:407)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1461)
          	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
          	... 46 more
          Caused by: java.lang.IllegalArgumentException: Superclass has no null constructors but no arguments were given
          	at net.sf.cglib.proxy.Enhancer.emitConstructors(Enhancer.java:721)
          	at net.sf.cglib.proxy.Enhancer.generateClass(Enhancer.java:499)
          	at net.sf.cglib.transform.TransformingClassGenerator.generateClass(TransformingClassGenerator.java:33)
          	at net.sf.cglib.core.DefaultGeneratorStrategy.generate(DefaultGeneratorStrategy.java:25)
          	at net.sf.cglib.core.AbstractClassGenerator.create(AbstractClassGenerator.java:216)
          	at net.sf.cglib.proxy.Enhancer.createHelper(Enhancer.java:377)
          	at net.sf.cglib.proxy.Enhancer.create(Enhancer.java:285)
          	at org.springframework.aop.framework.Cglib2AopProxy.getProxy(Cglib2AopProxy.java:201)
          	... 53 more

          Comment


          • #6
            I am not sure what you are trying to do with an Aspect; I meant you can implement a
            Code:
            ChannelInterceptor
            and apply it some/all channels wit a global declaration
            Code:
            <int:channel-interceptor pattern="*" ref="myPerfInterceptor" />
            .

            Comment


            • #7
              Sorry missed the global part. Thought i need to put the interceptor for every channel. So having aop around a specific package of spring integration and profiling in that aop was easier. I got this working pointing to the aggregator package. Dont see much delays in that.

              But i will try the global interceptor

              Thanks

              Comment

              Working...
              X