Skip to content

Update build/config to use pyproject.toml #19

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

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open

Conversation

VanL
Copy link

@VanL VanL commented Feb 25, 2025

This pull request ports the information in setup.py and setup.cfg to pyproject.toml and then deletes the setup.* files. As shown, it installs with uv sync and builds with uv build.

@aosingh aosingh self-requested a review February 27, 2025 20:37
@aosingh
Copy link
Owner

aosingh commented Feb 28, 2025

@VanL

Thanks for raising a PR. Could you please explain the rationale behind multi server ?

@VanL
Copy link
Author

VanL commented Feb 28, 2025

Context: I am building an application that will allow clients to log into a main application and "load" or "save" a project. For various reasons, we do not want to have the project save entries in the main database. Our current proposed architecture uses sqlite files as "save files" for clients.

These save files are mostly write-once, read-many, but there may be some updates. We were looking at sqlite_rx as a base because it allows a single process to handle reading/writing of a particular database, resolving concurrency issues (at least as far as sqlite is concerned, we need to handle ordering of operations separately).

However, just like we don't want all the client save files in the main db, we don't want them in the same db. Again, think "save file."

As it is currently, I just extended the existing project to serve multiple databases based on a static map. Instead of the plain REQ/REP socket, the multiserver implements a ROUTER/DEALER that then connects to a SQLiteServer instance based essentially on your existing design.

The going-forward plan is to implement an autocreate/autoconnect feature. Instead of just connecting to the dbs statically defined in the database_map, the server will examine the database name and autocreate/autoconnect to the database to serve the connection.

There is more (managing processes/process lifetimes, eviction, security considerations, configuration), but that's where I am going.

@aosingh
Copy link
Owner

aosingh commented Mar 7, 2025

@VanL I am currently reviewing this. Things are a bit slow on my side because I am on parental leave but I hope to merge this soon by next week.

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

Successfully merging this pull request may close these issues.

2 participants