Handling Large AppMaps

Some AppMaps contain too much data and can be difficult to review. Often, these AppMaps have many repetitive function calls that add a lot of data to the file, but don’t add much value when interpreting the AppMap. Large AppMaps are a potential indication that you should change how you’re recording by filtering out less valuable information. For example, you could exclude some calls to logging functions, or record fewer endpoints when manually recording.

AppMaps Over 10 MB

When you attempt to open an AppMap in a code editor extension that is over 10 MB, it will be automatically pruned down to ~10 MB. The most frequently called functions will be removed until the file is below 10 MB in size. (Don’t worry, the file will remain untouched because the pruning is done in memory). You will see notifications within the AppMap informing you that it has been pruned, and the pruned functions will be highlighted in the Stats panel:

Pruned Stats Panel

The automatic pruning might be sufficient, but if you want more control over what events are removed, you have two options:

  1. Use the prune CLI command to remove events from an existing AppMap
  2. Change the configuration of your appmap.yml to exclude certain events when an AppMap is generated

AppMaps Over 200 MB

When an AppMap is over 200 MB, we will not open it in the code editor extension because it could cause performance issues on your computer. Instead, we generate statistics about your AppMap and open the Stats panel. Use this information to configure your appmap.yml to exclude these functions (see below). The next time that you generate your AppMap, it will be smaller because it will not contain the specified functions:

Giant Map Stats Panel

We do not recommend using the prune CLI command for AppMaps over 200 MB, because it loads the entire AppMap into memory, which may cause performance issues for your computer.

Was this page helpful? thumb_up Yes thumb_down No
Thank you for your feedback!