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
Laravel Pennant performance spans & breadcrumbs #655
Comments
@cleptric I’m happy to create the code and PR for this if you would like? |
@martinbean Hey, thanks a lot! |
@cleptric Why would Sentry need an event before a feature is retrieved? Would you not want to add a breadcrumb after a feature and its value has been resolved? |
We already trace all DB queries related to retrieving a feature, so the only addition here would be to wrap these queries into a new span and create a breadcrumb before the DB queries are run. This is mostly about better UX in the product. |
In addition to @cleptric their comments, having an event before & after means we know when the framework started and finished resolving the feature flag, meaning we know how long it took and which (if any) database queries or other expensive operations took place while resolving the flag. This gives much insights in the timing. So for just breadcrumbs the "after" is enough but for the performance spans the "before" is a must. |
Laravel Pennant is a new feature flagging library for Laravel.
There are currently two events dispatched,
FeatureRetrieved
andFeatureResolved
.We could try contributing new
FeatureRetrieve
andFeatureResolve
events upstream, or use decorators, so we are able to wrap the code or DB query executed into a span, containing the feature identifier and result.The text was updated successfully, but these errors were encountered: