scoutapp / scout-apm-laravel

ScoutAPM PHP Agent for the Laravel Framework
MIT License
22 stars 12 forks source link

Span limit of 1500 has been reached trying to start span for "SQL/Query" #75

Closed ysb closed 3 years ago

ysb commented 3 years ago

Hi;

I get Span limit of 1500 has been reached trying to start span for "SQL/Query" error on some queries. What is the reason and how can I solve this?

Thanks.

asgrim commented 3 years ago

This limit was introduced to stop excessively large amounts of memory from being consumed by Scout. See scoutapp/scout-apm-php#186

ysb commented 3 years ago

Thanks, but how can I prevent getting an exception? Can I just set like config(['scout.reached_span_cap' => true]); ?

asgrim commented 3 years ago

It is unlikely you're seeing an exception, you're probably seeing a notice level message in your logs. If you don't want to see notice level logs, you can change the log level as per https://github.com/scoutapp/scout-apm-laravel#logging-verbosity

However, if you are seeing an actual exception, please can you send me the trace and I can look into how it can be prevented.

ysb commented 3 years ago

Yes my fault, It is a notice. I thought it's an error when I see it on Bugsnag. Thanks for quick support.

asgrim commented 3 years ago

You're welcome! :)