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

Postgres support #446

Open
JJGadgets opened this issue Feb 17, 2024 · 1 comment
Open

Postgres support #446

JJGadgets opened this issue Feb 17, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@JJGadgets
Copy link

Type

Enhancement of an existing feature

Description

It would be nice to have Postgres support for Shinpuru, as I planned to selfhost this on my home Kubernetes cluster which has a Postgres Kubernetes operator installed and running to automate and manage replication, backups/restores (including streaming WALs, I can delete the Postgres cluster and reapply the cluster YAML and it'll restore and reconfigure everything automatically), credentials and other aspects of Postgres clusters.

MySQL/MariaDB Kubernetes operators are IMO less battle tested and stable than Postgres operators, and it seems like Shinpuru has been setup in a way that allows supporting other databases more readily (feel free to correct me if I'm wrong).

Attachments

No response

@JJGadgets JJGadgets added the enhancement New feature or request label Feb 17, 2024
@zekroTJA
Copy link
Owner

Hey! First of all, thank you for your suggestion!

Generally, the general implementation and configuration of the database would support different other database implementations next to MySQL/MariaDB.

I am actually planning a re-write of the whole database structure, which is still around and almost untouched since the creation of the bot, where I was still pretty novice to database concepts and thus, the implementation is pretty poor. But because there are so much dependencies on the database and because the current system kind of works, I did not prioritize to redo the whole thing yet.

Currently, I do some refactoring to re-work the whole dependency coupling between the different modules of shinpuru. When I am done with that, I would take a try on re-implementing the database in a more efficient way, where I would also support multiple other database types, but this might take a long time until it is ready to use.

Currently, the easiest and fastest way to support postgres would be to somewhat copy the current MySQL implementation but with postgres queries. But I would prefer to focus on the method path before because it is more future proof.

But if you really need the postgres implementation, I am also very open for a PR, if you have the time and interest. If you want to do so, feel free to contact me if you need help. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants