I can't replicate this.
On my laptop - IBM thinkpad, Linux, using Netty it take about 3 seconds to create 1000 topic subscribers.
Also I'd bear in mind that things like session creation, consumer creation aren't really optimised as it's assumed you will re-use these objects.
Me neither. Can you share the code?
Thanks for your responses, sorry I couldn't answer sooner. I've enclosed links below to the full code that I am running.
AsynchronousTopicListenerManager creates a single connection and a single session and creates a number of AsynchronousTopicListeners which create a consumer based on the session. I've also tried it creating a session per listener but the performance was similar.
I don't mean to be rude, but you just wasted my time.
I have removed everything not belonging to HornetQ in your code (Spring.. etc).. replicated your code exactly as it is. and I didn't see any performance issues:
I could create 5000 listeners in 30 seconds. 1000 in 8.
I suggest you profile your example and do your own investigation before jumping to conclusions.
Also, if you still believe there's an issue with HornetQ, please read this post:
And provide a self contained code (without any thirdparty code) that reproduces your possible issue.
At this point I believe your issue is at some spring code while instantiating this many clients. (Which is already beyond what I should be investigating)