Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] New agent memory option MySQL and Postgres creating multiples connections to database #3567

Open
joaopaulo-m opened this issue Nov 25, 2024 · 0 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@joaopaulo-m
Copy link

joaopaulo-m commented Nov 25, 2024

Describe the bug
On version 2.1.4 was added Postgres and MySql options to Agent Memory node. It works fine but after a few messages starts getting the "Too many connections errors" and my database has 29 connections.

To Reproduce
Steps to reproduce the behavior:

  1. Create a agent flow
  2. Add a Agent Memory with Postgres or MySQL option
  3. Send a few messages
  4. Check the database connections number

Expected behavior
Create a singleton of the TypeOrm DataSource, I checked the project code and I found that its been created a new instance of TypeOrm DataSource every time a MySqlSaver or PostgresSave it's created, this might be the problem.

Screenshots
image

image

image

@HenryHengZJ HenryHengZJ added bug Something isn't working enhancement New feature or request labels Nov 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants