cksac / dataloader-rs

Rust implementation of Facebook's DataLoader using async-await.
Apache License 2.0
261 stars 23 forks source link

Willing to accept full documentation contributions? #29

Closed MarkMcCaskey closed 2 years ago

MarkMcCaskey commented 3 years ago

Hello! Thanks for this crate!

I'm evaluating a stack for a web app (including postgres, actix, and juniper) and I'm concerned about potentially very bad performance on the backend <-> database connection. It seems like more than caching, I'd need the ability to specialize specific types of queries to be able to optimize bottlenecks (i.e. the most common / expensive queries should be done in a single SQL query).

It seems dataloaders are a possible fix for this but I don't have a ton of context on GraphQL or dataloaders so I'm still trying to figure out what exactly they do and if they'll solve the problem I have or if I need something else or have to drop GraphQL.

It's a bit difficult for me without documentation of this crate. I've looked through the code and and it seems well written and pretty small overall though, so I think I'd be able to add docs myself.

Would you be interested in accepting pull requests to fully document this crate (for docs.rs)?

Additionally, would you be interested in enabling a lint in CI (or directly in the Rust code) to deny missing docs?

If I have to understand everything myself anyways, I might as well document everything so that it'll be easier for future people to use this. But before I commit to spending that time, I want to check with you to see if you'd be willing to accept PRs for documentation.

cksac commented 3 years ago

You can checkout juniper example for how it works together.

Welcome PR for docs or enhancements. For deny missing docs, once docs is all ready, I am fine to enable this.