Skip to content

Commit

Permalink
Add a rough system diagram from my notebook
Browse files Browse the repository at this point in the history
The entities represented I believe are the bare minimum number of services
necessary to make things roughly work. The idea being that everything
effectively orients around the eventbus, and "extensibility" means tuning into
or publishing events rather than in-memory anything.

Fixes #20
  • Loading branch information
rtyler committed Jul 27, 2019
1 parent 8b87fac commit f4397eb
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Makefile
Expand Up @@ -12,7 +12,6 @@ SUB_DIRS=grammar

################################################################################
## Phony targets

# Cute hack thanks to:
# https://marmelab.com/blog/2016/02/29/auto-documented-makefile.html
help: ## Display this help text
Expand All @@ -39,7 +38,9 @@ prereqs: scripts/prereqs.sh ## Check that this system has the necessary tools to
clean: ## Clean all temporary/working files
$(foreach dir, $(SUB_DIRS), $(MAKE) -C $(dir) $@)

################################################################################
diagram: system.png system.dot ## Generate the diagrams describing otto
dot -Tpng -o system.png system.dot

################################################################################

.PHONY: all build check clean depends lint swagger
29 changes: 29 additions & 0 deletions system.dot
@@ -0,0 +1,29 @@
digraph {
label="Otto system design";

node[shape="box", style="rounded"]

node[shape="box", style="square"]
orchestrator; frontend; datastore; objectstore; webhooks; agents;
node[shape="parallelogram", style=""]
eventbus;

webhooks -> eventbus[color="blue", label="write events"];
eventbus -> frontend[color="red", label="subscribe to live updates"];

orchestrator -> datastore[color="blue", label="create runs"];
orchestrator -> eventbus[color="purple", dir="both", label="read/write events"];
orchestrator -> agents[color="purple", dir="both", label="create and control agents"];

agents -> eventbus[color="blue", label="write events"];
agents -> datastore[color="blue", label="persist results"];
agents -> objectstore[color="blue", label="archive artifacts"];

datastore -> frontend[color="red", label="read runs"];
objectstore -> frontend[color="red", label="read artifacts"];
objectstore -> agents[color="red", label="fetch artifacts/stashes"];

//{rank=same; orchestrator agents eventbus}
//{rank=same; message input}
}

Binary file added system.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 f4397eb

Please sign in to comment.