Skip to content

hsestupin/storm-spirit

Repository files navigation

storm-spirit

A Clojure library designed to help you better understand your Storm topology visualizing it. At this moment the only one visualization way is supported - graphviz.

Dependency

[org.clojars.hsestupin/storm-spirit "0.1.0"]
<dependency>
  <groupId>org.clojars.hsestupin</groupId>
  <artifactId>storm-spirit</artifactId>
  <version>0.1.0</version>
</dependency>

Usage

Use of this project requires that Graphviz is installed, which can be checked by running dot -V at the command line. If it's not installed, you can do the following:

platform directions
Linux install graphviz using your package manager
OS X download the installer
Windows download the installer

Lets assume that var topology holds your topology built something like that. You can build the view of topology like this:

; using wrapper
(storm-spirit.core/visualize-with-graphviz topology)
; or multimethod call
(storm-spirit.core/visualize {:view-format :graphviz :topology topology})

And you will see:

alt tag

Also by default it draws vertical graph but you could specify the direction like this (see possible parameter values http://www.graphviz.org/content/attrs#drankdir):

; using wrapper
(storm-spirit.core/visualize-with-graphviz topology {:graph-attrs {:rankdir :LR}})
; or multimethod call
(storm-spirit.core/visualize {:view-format :graphviz :topology topology
            :graph-attrs {:rankdir :LR}})

Which produces the following image: alt tag

Please notice that any graph attributes specified in the map :graph-attrs are simply passed to dot.

License

Copyright (C) 2014 Sergey Stupin

Distributed under the Eclipse Public License, the same as Clojure.

About

Apache Storm visualization tools

Resources

License

Stars

Watchers

Forks

Packages

No packages published