You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The code in the settings knows that the server can support both postgresql and mariadb. The same is true with the requirements.txt files.
We can reduce the complexity of the codebase by making the features database agnostic. The goal is to have a single database (most likely PostgreSQL) as the default database. But to allow users to switch in a MariaDB/MySQL database by modifying the config.
This is technically what the codebase is doing by it treats both databases as first-class citizens which is unnecessarily bloating the codebase.
Combine multiple databases
It might be worth combining the userdb and the maindb so the application only needs a single database by default.
It will probably be useful to support the existing environment variables for backward-compatibility. But my gut tells me it won't be used by most our users, so having a single database configuration should lower the barrier-to-entry for new users, thus improve the adoption of the server.
The text was updated successfully, but these errors were encountered:
@AntonOfTheWoods What was the inspiration behind separating the 'maindb' and the 'userdb'?
I assume it's just to keep the Anki Sync and Django data separate?
@VikashKothary , yes. userdbs are done as postgres schemas and mysql dbs if memory serves. The idea was to keep the django side of things separate from userdata.
That sounds good. I'm planning on refactoring it so that the internal state of this service in the database isn't influenced by the Anki database structure, so we might be able to eliminate the complexity.
I think the Anki database structures suffer from very poor column names so I hope if we can improve this, it would improve the developer experience and reduce the complexity of the service.
Combine PostgreSQL and MariaDB features
The code in the settings knows that the server can support both postgresql and mariadb. The same is true with the requirements.txt files.
We can reduce the complexity of the codebase by making the features database agnostic. The goal is to have a single database (most likely PostgreSQL) as the default database. But to allow users to switch in a MariaDB/MySQL database by modifying the config.
This is technically what the codebase is doing by it treats both databases as first-class citizens which is unnecessarily bloating the codebase.
Combine multiple databases
It might be worth combining the userdb and the maindb so the application only needs a single database by default.
It will probably be useful to support the existing environment variables for backward-compatibility. But my gut tells me it won't be used by most our users, so having a single database configuration should lower the barrier-to-entry for new users, thus improve the adoption of the server.
The text was updated successfully, but these errors were encountered: