tortoise / tortoise-orm

Familiar asyncio ORM for python, built with relations in mind
https://tortoise.github.io
Apache License 2.0
4.57k stars 378 forks source link

Updating config at runtime #1563

Closed intigratech closed 4 months ago

intigratech commented 6 months ago

I have a use case where I need to be able to dynamically "install/uninstall" apps at runtime. I guess this would entail closing the connection and re-init with the new config. However, the issue with this approach is that this would cause connections to all databases to close? Is there a way to update the config/apps for just a particular connection without affecting other database connections?

abondar commented 4 months ago

No, there isn't way to do so, and I am not sure there should be

I'll close issue, but you can describe your usecase if you think that is something that could be used not only in extremely exotic cases

intigratech commented 4 months ago

No worries. Yes, I realize it's a bit of an exotic use case.