Hi @phptek as per your previous comment on #93 here is my current status of work, it's not a lot, but it does fire them off. You obviously need your DSN set, and for this implementation you need to set SENTRY_TRACES_SAMPLE_RATE as an .env variable.
1 will mean everything is logged, which is useful for testing, and Sentry recommend using 0.20 for production, so only 1 in 5 requests are actually logged. You could reduce this if needing an even smaller sample size, but this appeared to be working as expected in my basic testing. This information will need to be added to the README.md which I have not done yet.
Feel free to contribute, or offer advice here for this to be rounded out. The last actual feature needs to be the management of the Transaction's life-cycle, where in SentryAdaptor.php:192's function startTransaction() you will see that it starts and ends it straight away. It has to be started at the beginning of the request, and ended at the closing of it for the timings to actually make sense, or as something similar that is as close to the metal that is reasonable. I'm not quite sure how to hook into this yet - at least in an elegant way. My initial thought was to include an extension of the request handler itself, but that might be the wrong direction.
It is also likely that there is some missing data when it comes to stack tracing the performance monitoring, but presumably when it's plugged into the life-cycle properly it will have a lot more context available to it as well.
Hi @phptek as per your previous comment on #93 here is my current status of work, it's not a lot, but it does fire them off. You obviously need your DSN set, and for this implementation you need to set
SENTRY_TRACES_SAMPLE_RATE
as an.env
variable.1
will mean everything is logged, which is useful for testing, and Sentry recommend using0.20
for production, so only 1 in 5 requests are actually logged. You could reduce this if needing an even smaller sample size, but this appeared to be working as expected in my basic testing. This information will need to be added to theREADME.md
which I have not done yet.Feel free to contribute, or offer advice here for this to be rounded out. The last actual feature needs to be the management of the
Transaction
's life-cycle, where inSentryAdaptor.php:192
's functionstartTransaction()
you will see that it starts and ends it straight away. It has to be started at the beginning of the request, and ended at the closing of it for the timings to actually make sense, or as something similar that is as close to the metal that is reasonable. I'm not quite sure how to hook into this yet - at least in an elegant way. My initial thought was to include an extension of the request handler itself, but that might be the wrong direction.It is also likely that there is some missing data when it comes to stack tracing the performance monitoring, but presumably when it's plugged into the life-cycle properly it will have a lot more context available to it as well.