GO’CIRCUIT
A project by Petar Maymounkov.

Circuitizing legacy applications

 
A pre-existing, or “legacy”, Go application can be easily run and managed by the circuit with no modification of its internal logic at all.

Integration in a line

For any pre-existing application, simply add

import _ "circuit/load/cmd"
to the main program package and go on to compile it as usual with go build.

Executing the compiled binary is no different than before the circuit was imported into it, except for the added requirement that the CIR environment points to an app configuration file that specifies a Zookeeper section. (The Build and Deploy sections are not needed.)

You can find a sample application in subdirectory tutorials/legacy. When executed, the program will sleep for a short while, giving you an opportunity to switch terminals and verify its presence using the 4ls tool.