Commit Graph

4 Commits

Author SHA1 Message Date
Mitchell Hashimoto 8a9e1c1527
dag: call into DotNode to get attributes 2016-12-03 15:17:14 -08:00
James Bardin 6f347ebb3a Remove dot package
Unify all dot functionality in the dag package
2016-11-14 08:50:34 -05:00
James Bardin 8a5d71b0ac Implement dag.GraphNodeDotter (temporarily)
To maintain the same output, the Graph.Dot implementation needs to be
aware of GraphNodeDotter. Copy the interface into the dag package, and
make the Dot marshaler aware of which nodes implemented the interface.
This way we can remove most of the remaining dot code from terraform.
2016-11-14 08:50:34 -05:00
James Bardin 28d406c040 Provider a marshaler for dag.Graph
The dot format generation was done with a mix of code from the terraform
package and the dot package. Unify the dot generation code, and it into
the dag package.

Use an intermediate structure to allow a dag.Graph to marshal itself
directly. This structure will be ablt to marshal directly to JSON, or be
translated to dot format. This was we can record more information about
the graph in the debug logs, and provide a way to translate those logged
structures to dot, which is convenient for viewing the graphs.
2016-11-14 08:50:33 -05:00