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

Logging Output #58

Open
No9 opened this issue Jul 21, 2020 · 3 comments
Open

Logging Output #58

No9 opened this issue Jul 21, 2020 · 3 comments

Comments

@No9
Copy link

No9 commented Jul 21, 2020

Hi There
First of all thanks very much for putting this driver together - I'm really enjoying working with it.

I noticed from the docs that logging is available but if I understand the code correctly it's only used in migrations:
https://github.com/thedodd/wither/search?q=log&type=Code

Is my understanding correct?

FYI I have also put together a small sample app using this lib with tide and handlebars
https://github.com/No9/tide-morth-example/

Thanks again for your work.

@thedodd
Copy link
Owner

thedodd commented Jul 21, 2020

@No9 as of master today, yes. That is correct. Previously, there was a bit more logging within the index synchronization code; however, that has been removed recently due to some driver limitations discussed over in #51.

Right now, almost everything is a thin layer over top of the driver, which allows for the model based approach. There isn't much to log. However, along those lines, if you do think that perhaps more logging is merited, I am certainly open to that. I've even considered adding in support for the tracing library, but I'm not sure on that one.

Thoughts?

@No9
Copy link
Author

No9 commented Jul 21, 2020

I think tracing may be the way to go - Just wanted to confirm that I wasn't missing anything on the logging.
I'd like to get e2e tracing into the sample app - I'll take a look and ping back when I know more.
Feel free to close this in the meantime.

@thedodd
Copy link
Owner

thedodd commented Sep 3, 2020

@No9 if you are up to the challenge, I think an excellent approach for this lib would be to use #[tracing::instrument(level="trace")] on our Model trait. Any other async methods / functions called in the lib can be similarly decorated.

If you are down to do so, we could probably factor the code into the upcoming 0.9.0 release. Just let me know :)

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

No branches or pull requests

2 participants