Skip to content

Commit

Permalink
fix example
Browse files Browse the repository at this point in the history
  • Loading branch information
tntobias committed Sep 13, 2020
1 parent fe98241 commit e00b246
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Expand Up @@ -27,12 +27,12 @@ dc.NewGroup("services").
gcp.Compute.ComputeEngine(diagram.NodeLabel("Server 2")),
gcp.Compute.ComputeEngine(diagram.NodeLabel("Server 3")),
).
ConnectAllFrom(dns.ID(), diagram.Forward()).
ConnectAllFrom(lb.ID(), diagram.Forward()).
ConnectAllTo(cache.ID(), diagram.Forward())

dc.NewGroup("data").Label("Data Layer").Add(cache, db).Connect(cache, db)

d.Connect(lb, dns, diagram.Forward()).Group(dc)
d.Connect(dns, lb, diagram.Forward()).Group(dc)

if err := d.Render(); err != nil {
log.Fatal(err)
Expand Down
4 changes: 2 additions & 2 deletions _examples/app/main.go
Expand Up @@ -26,12 +26,12 @@ func main() {
gcp.Compute.ComputeEngine(diagram.NodeLabel("Server 2")),
gcp.Compute.ComputeEngine(diagram.NodeLabel("Server 3")),
).
ConnectAllFrom(dns.ID(), diagram.Forward()).
ConnectAllFrom(lb.ID(), diagram.Forward()).
ConnectAllTo(cache.ID(), diagram.Forward())

dc.NewGroup("data").Label("Data Layer").Add(cache, db).Connect(cache, db)

d.Connect(lb, dns, diagram.Forward()).Group(dc)
d.Connect(dns, lb, diagram.Forward()).Group(dc)

if err := d.Render(); err != nil {
log.Fatal(err)
Expand Down
Binary file modified images/app-diagram.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit e00b246

Please sign in to comment.