Stridsvagn69420 / Cyrkensia

Music Repository Server
https://crates.io/crates/cyrkensia
GNU Affero General Public License v3.0
2 stars 0 forks source link

PR for new improved Rust version #38

Open Stridsvagn69420 opened 1 year ago

Stridsvagn69420 commented 1 year ago

Closes #20

Pull Request for the Rust rewrite. Hopefully I will be satisfied with this. More information will follow.

Stridsvagn69420 commented 1 year ago

So like, I finished lé epic 420 dev notes. And I think this concept is way better than what I had in mind before. I just need to figure out how to run something parallel to actix-web, or I guess I'll just do the update if age is equal or larger than maximum age.

Stridsvagn69420 commented 7 months ago

I made notes - again (I swear this will become a running gag) - but this time they're pretty solid and better than what I thought was good. You see, this server is supposed to be minimal. If you need a lot of caching, use Nginx or whatever. (As in, it caches the API result.) The only thing it caches is the metadata read from the "database", because of deserialization and I/O operations. The database is also now just JSON files instead of some SQL stuff. It's too much for this small project.

Stridsvagn69420 commented 7 months ago

Before I start, I'll check out the entire thing with features and how I manage them the best, since this is both binary and library, after I'm done with the main application. Currently, you'd have to disable the default features and only then set the ones you need. Plus, I wanna exclude the rustls feature for anything that isn't part of the cli feature.

About the submodules and features:

Stridsvagn69420 commented 7 months ago

I think this crate will have 3 different types of Artist, Album and Track (REST API, Database, Appstate), so I might as well make a Trait for it.