diff options
Diffstat (limited to 'commands.go')
-rw-r--r-- | commands.go | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/commands.go b/commands.go deleted file mode 100644 index 5368097f..00000000 --- a/commands.go +++ /dev/null @@ -1,27 +0,0 @@ -package roadrunner - -import ( - "encoding/json" - "github.com/spiral/goridge" -) - -// TerminateCommand must stop underlying process. -type TerminateCommand struct { - Terminate bool `json:"terminate"` -} - -// PidCommand send greeting message between processes in json format. -type PidCommand struct { - Pid int `json:"pid"` - Parent int `json:"parent,omitempty"` -} - -// sends control message via relay using JSON encoding -func sendCommand(rl goridge.Relay, command interface{}) error { - bin, err := json.Marshal(command) - if err != nil { - return err - } - - return rl.Send(bin, goridge.PayloadControl) -} |