suport for distributing tasks that contain plugins

This commit is contained in:
xucong053
2022-07-25 21:15:03 +08:00
committed by 徐聪
parent 4ff3179a22
commit c72dc38bd3
4 changed files with 51 additions and 3 deletions
+8 -1
View File
@@ -32,7 +32,8 @@ type TConfig struct {
Timeout float64 `json:"timeout,omitempty" yaml:"timeout,omitempty"` // global timeout in seconds
Export []string `json:"export,omitempty" yaml:"export,omitempty"`
Weight int `json:"weight,omitempty" yaml:"weight,omitempty"`
Path string `json:"path,omitempty" yaml:"path,omitempty"` // testcase file path
Path string `json:"path,omitempty" yaml:"path,omitempty"` // testcase file path
PluginSetting *PluginConfig `json:"plugin,omitempty" yaml:"plugin,omitempty"` // plugin config
}
// WithVariables sets variables for current testcase.
@@ -172,3 +173,9 @@ const (
)
var thinkTimeDefaultRandom = map[string]float64{"min_percentage": 0.5, "max_percentage": 1.5}
type PluginConfig struct {
Path string
Type string // bin、so、py
Content []byte
}