Your
Debugger,
Documentation,
Pull-request companion.
Quickly visualize execution flow for Ruby on Rails apps.
Which methods call which, their parameters, and return values.
Use Cases
- Newly hired engineers get up to speed quickly by visually seeing only the called methods for a given endpoint.
-
Debug code without the need for placing
puts/print
statements everywhere. - Quickly see problems with execution - e.g. this endpoint is suddenly calling
process_payment
twice.
Why Do I Need This?
Pull Requests Don't Reveal Everything
-
Program flow issues -
e.g. a method is called via a callback on the application controller, but then there's a redundant call within one of the controller actions. -
Action taken based on a parameter value -
e.g. if the value of a parameter comes from a database value or is calculated far up the call chain, it's really hard to trace that parameter to its originating source and determine if it's a valid value being passed in.
Learning a Large Codebase
The key to effortlessly onboarding new software engineers is to not just dump a pile of code in their lap, like a surprise bag of dirty laundry. If you're dumping 300,000 lines of code in your newly hired engineer's lap, you're setting them up for failure. How do they explore the code effectively? Give them the tool that allows them to understand your codebase, quickly.
The issue with standard debuggers, code navigation (e.g Rubymine), or randomly sprinkling puts
statements everywhere, is that you're only getting a sample of the execution. Wherever you place your
breakpoint, that's your visibility.
Call Stacking is broader, an unbiased profiler that allows you to envision the entire call stack, without any sort of manual intervention/breakpoints. Call Stacking passively collects all of the important methods, their context, and presents them to your engineer in an easily digestible visual.
Get started right away - no need to add invasive markup within your code.
The visualization is built automatically for you, without any intervention.
Key Features
-
Zero Time to Integrate
No need to add any markup to your codebase. Call Stacking is a drop-in solution.
-
Heads-up Debugger
A world-class visualization allows you to explore and instantly see the critical method calls for any given endpoint.
When your application page renders, press ctrl-d or click on the 💥 icon on the far right and instantly see all of your methods calls. See the callstack alongside your application.
-
Visual nesting of the method calls
You can see which methods are called within each parent method. Hover over the entry to view location of the method call.
-
Search
Ctrl-s - quickly search for any called method or class.
-
Visibility for argument values for each method call.
When reviewing a pull request, it can be difficult to determine the value being passed as an argument to a specific method. This value may be coming from the database or being calculated in a parent method several levels up in the call stack, which can require significant effort to trace through the code to identify the source.
Easily observe the full calling context without having to trace through the code.
-
↳ Visibility for rendering and return values.
Instantly see the HTML that the template or partial rendered. Or what the
calculated_payment
returned. -
Sort traces by feature/url.
Imagine hiring a new engineer and handing them the callstacks for each major mobile endpoint.
"Here are our endpoints. Here's the context in which each method is called. Here are the important methods."
-
Comments
Individual changes to your callstack can be commented on by any of your invited team members. (Team edition)
Setup
github/callstacking-rails
- Add
callstacking-rails
to the development group in yourGemfile
. bundle install
- Create a Call Stacking account with
bundle exec callstacking-rails register
- Login with your Call Stacking account using
bundle exec callstacking-rails setup
You can enable/disable callstacking-rails
at any time with
bundle exec callstacking-rails enable
or bundle exec callstacking-rails disable
.
Usage
Browser Requests
- Start your Rails application (
rails s
) - You should see a 💥icon on the right hand side after your page has rendered.
- Either click 💥 or use the hotkey ctrl-d to open the heads up debugger.
- The heads up debugger contains all of the call stacking info for the rendered page.
- You can search for any method call or return using the built in search (ctrl-s).
Headless Requests / API Endpoints
- Start your Rails application (
rails s
) - Navigate to https://callstacking.com/traces
- Make an API request with Curl, Postman, your mobile app, etc.
- As new traces occur, the entries will automatically appear atop your trace list. Click on the entry to view the callstack details.
- Or - when a new request starts, the stack trace URL will be output in the Rails console log.