PGBOUNCER连接池,用于连接到同一Postgres DB的多个弹簧启动应用程序?

发布于 2025-02-09 12:17:18 字数 257 浏览 3 评论 0原文

只想验证PG保镖连接池的这种情况是否可能

  • 具有 a b spring boot应用程序连接到同一db(仅读取操作)的弹簧启动应用程序
  • 确实会提供PGBOUNCER共享连接池在相同应用程序的多个实例中? - 是否有一种方法可以在应用中分享 50:50

在PGBOUNCER方面的这些设置上的任何见解或文档都会有所帮助

Just want to validate if this scenario of PG bouncer Connection pooling is possible

  • Have A and B spring boot application connecting to the same DB (only read operations)
  • Does PGbouncer share connection pools across multiple instances of the same applications?
    - Is there a way to share like 50:50 among applications.

Any insights or docs on these settings on pgbouncer side would be helpful

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

昵称有卵用 2025-02-16 12:17:18

是的PGBOUNCER在同一应用程序的多个实例上共享连接池。配置pool_size定义了每个用户组合每个数据库的连接池大小。因此,如果同一应用程序的多个实例使用相同的用户,则在跨实例共享连接池。

请注意,它不会与其他数据库或用户组合共享池。

Yes PGBouncer shares connection pools across multiple instances of the same applications. The config pool_size defines the connection pool size for per database per user combination. So if multiple instances of same application use same user then the connection pool is shared across instances.

Note that it doesn't share pool with other database or user combination.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文