Active PooledConnectionFactory pooling Connections vs Sessions

混江龙づ霸主 提交于 2019-12-06 11:34:10

Both approaches should be functionally equivalent, and the difference in the code to do one vs. the other should be relatively small.

In terms of performance I don't think it will really matter as your bottleneck will be on the consuming side not on the producing side since you have a single consumer and potentially many concurrent producers.

Personally, I would prefer letting the pool do all the work and just writing the application as if it is creating a connection and session every time it sends a message (which would obviously be a huge anti-pattern without a pool).

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!