Claus Ibsen created CAMEL-11347:
-----------------------------------

             Summary: Optimize AsyncCallback in EIPs to use reusable static 
classes
                 Key: CAMEL-11347
                 URL: https://issues.apache.org/jira/browse/CAMEL-11347
             Project: Camel
          Issue Type: Improvement
          Components: camel-core
            Reporter: Claus Ibsen
             Fix For: 2.20.0


When some EIPs or consumer routes via AsyncCallback then we create a new 
AsyncCallback as anonymous inner class. But this creates a new instance as the 
JVM cannot optimize that.

As those callback don't usually have their own state, we can likely replace 
that with a single reusable instance which can reduce the memory allocation.

For example this TimerConsumer$3 can be optimized. 



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to