Implement limited detail spans

Open
#471 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
python, ruby

Research direction

Start by reading the referenced Ruby files, lib/scout_apm/layer_children_set.rb and lib/scout_apm/limited_layer.rb, then trace the corresponding span tracking in the Python agent. Compare how the Ruby implementation switches to restricted detail after 2000 spans of a kind. Done means long-running requests retain limited detail rather than unbounded span data.

Written by the indexing model from the issue text.

Description

Currently we track all spans in full detail. This isn't ideal for slow HTTP views or long running background tasks which might have 1000's of database queries, cache calls, etc. which can result in much data being tracked.

We can implement the same strategy that the Ruby library does: use restricted detail after so many of a kind of span (coded to 2000 at time of writing):

https://github.com/scoutapp/scout_apm_ruby/blob/master/lib/scout_apm/layer_children_set.rb#L48
https://github.com/scoutapp/scout_apm_ruby/blob/master/lib/scout_apm/limited_layer.rb

Dominant language
Python
Stars
77
Forks
19
Avg merge
1d 9h
Merged PRs (30d)
5

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from scoutapp/scout_apm_python

All issues in scoutapp/scout_apm_python

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.