wasmcloud/cmd/internal/topic.go

24 lines
675 B
Go
Raw Normal View History

2019-12-08 16:07:31 +00:00
package internal
import "github.com/rogpeppe/go-internal/txtar"
// Topic name for wasmcloud -> executor communication
2019-12-14 21:04:28 +00:00
const TopicName = "exec"
2019-12-08 16:07:31 +00:00
type ExecRequest struct {
WASMCID string `json:"wasmcid"`
2019-12-08 17:46:02 +00:00
Name string `json:"name"`
2019-12-08 16:07:31 +00:00
Data []byte `json:"data"`
2019-12-14 21:04:28 +00:00
Policy []byte `json:"policy"`
2019-12-08 16:07:31 +00:00
ABI ABI `json:"abi"`
Env map[string]string `json:"env"`
UUID string `json:"uuid"`
}
type ExecResponse struct {
WASMCID string `json:"wasmcid"`
LogBundleCID string `json:"log_bundle_cid"`
Logs txtar.Archive `json:"logs"`
UUID string `json:"uuid"`
}