All Projects → jamesmoriarty → call-graph

jamesmoriarty / call-graph

Licence: MIT license
Capture execution and create dependency graphs.

Programming Languages

ruby
36898 projects - #4 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to call-graph

cytoscape.js-fcose
fCoSE: a fast Compound Spring Embedder
Stars: ✭ 94 (+487.5%)
Mutual labels:  graphviz
phuml
phUML is a UML diagram generator. It takes arbitrary object oriented PHP code and creates fully blown class diagrams of it.
Stars: ✭ 75 (+368.75%)
Mutual labels:  graphviz
e9afl
AFL binary instrumentation
Stars: ✭ 234 (+1362.5%)
Mutual labels:  instrumentation
prometheus-phoenix
Prometheus.io Phoenix instrumenter
Stars: ✭ 66 (+312.5%)
Mutual labels:  instrumentation
prometheus-plugs
Prometheus.erl Elixir Plugs
Stars: ✭ 52 (+225%)
Mutual labels:  instrumentation
sdks
Polyaxon Clients & Langange SDKS
Stars: ✭ 12 (-25%)
Mutual labels:  instrumentation
ged2site
Create a family tree website from a Gedcom file
Stars: ✭ 25 (+56.25%)
Mutual labels:  graphviz
OneAgent-SDK-Python-AutoInstrumentation
autodynatrace, a python library that implements automatic instrumentation using the OneAgent SDK for Python
Stars: ✭ 42 (+162.5%)
Mutual labels:  instrumentation
java-jaxrs
OpenTracing Java JAX-RS instrumentation
Stars: ✭ 37 (+131.25%)
Mutual labels:  instrumentation
datalinguist
Stanford CoreNLP in idiomatic Clojure.
Stars: ✭ 93 (+481.25%)
Mutual labels:  graphviz
instrumentation
An extensible java agent framework that instruments (modifies the bytecode at class loading time) programs running on the JVM, with the purpose of capturing method invocation events (start, finish, errors ...) and notifying custom listeners.
Stars: ✭ 39 (+143.75%)
Mutual labels:  instrumentation
console
Oracle Instrumentation Console: Lightweight PL/SQL logging tool inspired by the JavaScript Console
Stars: ✭ 14 (-12.5%)
Mutual labels:  instrumentation
opencensus-go-exporter-stackdriver
OpenCensus Go exporter for Stackdriver Monitoring and Trace
Stars: ✭ 65 (+306.25%)
Mutual labels:  instrumentation
PlantUml-Language-Service
PlantUml Language Service extension for Visual Studio 2017 and 2019
Stars: ✭ 24 (+50%)
Mutual labels:  graphviz
daglib
Directed Acyclic Graphs With Modern Fortran
Stars: ✭ 20 (+25%)
Mutual labels:  graphviz
sphinx-server
Sphinx documentation Docker image with Python server and support for PlantUML and more.
Stars: ✭ 62 (+287.5%)
Mutual labels:  graphviz
graphviz-server
Java based GraphViz HTTP Server
Stars: ✭ 34 (+112.5%)
Mutual labels:  graphviz
metrics-okhttp
An OkHttp HTTP client wrapper providing Metrics instrumentation of connection pools, request durations and rates, and other useful information.
Stars: ✭ 18 (+12.5%)
Mutual labels:  instrumentation
callGraph
A multi-language tool which parses source code for function definitions and calls
Stars: ✭ 50 (+212.5%)
Mutual labels:  graphviz
ocaml-re-nfa
OCaml code to construct an NFA from a regular expression
Stars: ✭ 44 (+175%)
Mutual labels:  graphviz

CallGraph

Build Status

Capture execution and create dependency graphs.

Why

The Law of Demeter (LoD) or principle of least knowledge is a design guideline for developing software, particularly object-oriented programs. In its general form, the LoD is a specific case of loose coupling. The guideline was proposed by Ian Holland at Northeastern University towards the end of 1987, and can be succinctly summarized in each of the following ways:[1]

  • Each unit should have only limited knowledge about other units: only units "closely" related to the current unit.
  • Each unit should only talk to its friends; don't talk to strangers.
  • Only talk to your immediate friends.

Install

Gem Version

gem install call_graph

Usage

Capture the execution you want to graph between CallGraph.trace { }.

class A
  def self.x
    B.new.y
  end
end

class B
  def y
    1 + C.z do
      1
    end
  end
end

class C
  def self.z
    yield
  end
end
require 'call_graph'

CallGraph.config do |config|
  config.file_path = "examples/call-graph"
end

CallGraph.trace do
  A.x
end

Print the captured execution with the provided rake tasks.

# Rakefile
load 'call_graph/tasks/printer.rake'
$ rake -T
...
rake call_graph:printer:dot  # write dot file
rake call_graph:printer:png  # write png file from dot file

Example Graph

Configuration

CallGraph.config do |config|
  config.file_path = "examples/call-graph"
end

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake test to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run bundle exec rake install. To release a new version, update the version number in version.rb, and then run bundle exec rake release, which will create a git tag for the version, push git commits and tags, and push the .gem file to rubygems.org.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/jamesmoriarty/call_graph. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].