we're using JMS in Spring to access Azure Service Bus in our application, when we set spring.jms.servicebus.pool.max-connections to 100, our application met a error like below, after we changed it to be 50, our application started working, so I'm wondering if 100 exceeds the upper limit of spring.jms.servicebus.pool.max-connections, if so, what's the recommended number for it?
[scheduler-job-run-4] o.h.b.s.app.service.impl.JobRunnable : org.springframework.jms.UncategorizedJmsException: Uncategorized exception occurred during JMS processing; nested exception is javax.jms.JMSException: Error while attempting to add new Connection to the pool; nested exception is java.lang.NullPointerException: Cannot invoke "org.messaginghub.pooled.jms.pool.PooledConnection.incrementReferenceCount()" because "connection" is null
at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:311)
at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:185)
at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:507)
at org.springframework.jms.core.JmsTemplate.send(JmsTemplate.java:584)
at org.springframework.jms.core.JmsTemplate.convertAndSend(JmsTemplate.java:661)
at org.boogoo.attendance.infra.job.SyncPunchFromWeComJob.lambda$invoke$0(SyncPunchFromWeComJob.java:259)
at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1625)
at java.base/java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:762)
at org.boogoo.attendance.infra.job.SyncPunchFromWeComJob.invoke(SyncPunchFromWeComJob.java:257)
at org.boogoo.attendance.infra.job.SyncPunchFromWeComJob.execute(SyncPunchFromWeComJob.java:175)
at org.hzero.boot.scheduler.app.service.impl.JobRunnable.jobRun(JobRunnable.java:141)
at org.hzero.boot.scheduler.app.service.impl.JobRunnable.run(JobRunnable.java:112)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:833)
Caused by: javax.jms.JMSException: Error while attempting to add new Connection to the pool
at org.messaginghub.pooled.jms.util.JMSExceptionSupport.create(JMSExceptionSupport.java:82)
at org.messaginghub.pooled.jms.JmsPoolConnectionFactory.createJmsPoolConnection(JmsPoolConnectionFactory.java:719)
at org.messaginghub.pooled.jms.JmsPoolConnectionFactory.createConnection(JmsPoolConnectionFactory.java:247)
at org.messaginghub.pooled.jms.JmsPoolConnectionFactory.createConnection(JmsPoolConnectionFactory.java:242)
at org.springframework.jms.support.JmsAccessor.createConnection(JmsAccessor.java:196)
at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:494)
... 12 more
Caused by: java.lang.NullPointerException: Cannot invoke "org.messaginghub.pooled.jms.pool.PooledConnection.incrementReferenceCount()" because "connection" is null
at org.messaginghub.pooled.jms.JmsPoolConnectionFactory.createJmsPoolConnection(JmsPoolConnectionFactory.java:717)
... 16 more
we're using JMS in Spring to access Azure Service Bus in our application, when we set spring.jms.servicebus.pool.max-connections to 100, our application met a error like below, after we changed it to be 50, our application started working, so I'm wondering if 100 exceeds the upper limit of spring.jms.servicebus.pool.max-connections, if so, what's the recommended number for it?