11ms it takes because you use your code directly without any messaging background - no GC for immutable
Message
objects (10000) and reflection for method invocation (from Gateway Proxy)For me your test takes this time:
Total: 433 Total: 247 Total: 150 Total: 145 Total: 152 Total: 146 Total: 142 Total: 142 Total: 142 Total: 143
It is with @Repeat(10)
on test method and <int:service-activator input-channel="requestChannel" expression="'hello'"/>
.
Since your
replyChannel
doesn't do anything special you can get rid of it and you'll get some performance increase, because there is no need to correlate the reply fromreplyChannel
to theTemporaryReplyChannel
fromMessageHeaders
.Anyway show, please, the code of your
myProcessor
which version of Spring Integration do you use? Wouldn't you mind to upgrade to the latest one - 3.0.2 (http://projects.spring.io/spring-integration) ?