Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion cmd/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,8 @@ func (o *serverOption) runE(cmd *cobra.Command, args []string) (err error) {
go func() {
<-clean
serverLogger.Info("stopping the extensions")
storeExtMgr.StopAll()
storeExtMgr.StopAll() // This will stop all plugins including AI plugin

serverLogger.Info("stopping the server")
_ = lis.Close()
_ = o.httpServer.Shutdown(ctx)
Expand Down
2 changes: 2 additions & 0 deletions console/atest-ui/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import TestingHistoryPanel from './views/TestingHistoryPanel.vue'
import MockManager from './views/MockManager.vue'
import StoreManager from './views/StoreManager.vue'
import WelcomePage from './views/WelcomePage.vue'
import AIAssistant from './views/AIAssistant.vue'
import MagicKey from './components/MagicKey.vue'
import Extension from './views/Extension.vue'
import { useI18n } from 'vue-i18n'
Expand Down Expand Up @@ -175,6 +176,7 @@ API.GetMenus((menus) => {
<TestingHistoryPanel v-else-if="panelName === 'history'" :ID="ID"/>
<MockManager v-else-if="panelName === 'mock'" />
<StoreManager v-else-if="panelName === 'store'" />
<AIAssistant v-else-if="panelName === 'ai-assistant'" />
<WelcomePage v-else-if="panelName === 'welcome' || panelName === ''" />

<span v-for="menu in extensionMenus" :key="menu.index" :index="menu.index">
Expand Down
74 changes: 37 additions & 37 deletions pkg/mock/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,65 +16,65 @@ limitations under the License.
package mock

type Object struct {
Name string `yaml:"name" json:"name"`
InitCount *int `yaml:"initCount" json:"initCount"`
Sample string `yaml:"sample" json:"sample"`
Name string `yaml:"name" json:"name"`
InitCount *int `yaml:"initCount" json:"initCount"`
Sample string `yaml:"sample" json:"sample"`
}

type Item struct {
Name string `yaml:"name" json:"name"`
Request Request `yaml:"request" json:"request"`
Response Response `yaml:"response" json:"response"`
Param map[string]interface{}
Name string `yaml:"name" json:"name"`
Request Request `yaml:"request" json:"request"`
Response Response `yaml:"response" json:"response"`
Param map[string]interface{}
}

type Request struct {
Protocol string `yaml:"protocol" json:"protocol"`
Path string `yaml:"path" json:"path"`
Method string `yaml:"method" json:"method"`
Header map[string]string `yaml:"header" json:"header"`
Body string `yaml:"body" json:"body"`
Protocol string `yaml:"protocol" json:"protocol"`
Path string `yaml:"path" json:"path"`
Method string `yaml:"method" json:"method"`
Header map[string]string `yaml:"header" json:"header"`
Body string `yaml:"body" json:"body"`
}

type RequestWithAuth struct {
Request `yaml:",inline"`
BearerAPI string `yaml:"bearerAPI" json:"bearerAPI"`
Username string `yaml:"username" json:"username"`
Password string `yaml:"password" json:"password"`
Request `yaml:",inline"`
BearerAPI string `yaml:"bearerAPI" json:"bearerAPI"`
Username string `yaml:"username" json:"username"`
Password string `yaml:"password" json:"password"`
}

type Response struct {
Encoder string `yaml:"encoder" json:"encoder"`
Body string `yaml:"body" json:"body"`
BodyFromFile string `yaml:"bodyFromFile" json:"bodyFromFile"`
Header map[string]string `yaml:"header" json:"header"`
StatusCode int `yaml:"statusCode" json:"statusCode"`
BodyData []byte
Encoder string `yaml:"encoder" json:"encoder"`
Body string `yaml:"body" json:"body"`
BodyFromFile string `yaml:"bodyFromFile" json:"bodyFromFile"`
Header map[string]string `yaml:"header" json:"header"`
StatusCode int `yaml:"statusCode" json:"statusCode"`
BodyData []byte
}

type Webhook struct {
Name string `yaml:"name" json:"name"`
Timer string `yaml:"timer" json:"timer"`
Param map[string]string `yaml:"param" json:"param"`
Request RequestWithAuth `yaml:"request" json:"request"`
Name string `yaml:"name" json:"name"`
Timer string `yaml:"timer" json:"timer"`
Param map[string]string `yaml:"param" json:"param"`
Request RequestWithAuth `yaml:"request" json:"request"`
}

type Proxy struct {
Prefix string `yaml:"prefix" json:"prefix"`
Port int `yaml:"port" json:"port"`
Path string `yaml:"path" json:"path"`
Target string `yaml:"target" json:"target"`
RequestAmend RequestAmend `yaml:"requestAmend" json:"requestAmend"`
Protocol string `yaml:"protocol" json:"protocol"`
Prefix string `yaml:"prefix" json:"prefix"`
Port int `yaml:"port" json:"port"`
Path string `yaml:"path" json:"path"`
Target string `yaml:"target" json:"target"`
RequestAmend RequestAmend `yaml:"requestAmend" json:"requestAmend"`
Protocol string `yaml:"protocol" json:"protocol"`
}

type RequestAmend struct {
BodyPatch string `yaml:"bodyPatch" json:"bodyPatch"`
BodyPatch string `yaml:"bodyPatch" json:"bodyPatch"`
}

type Server struct {
Objects []Object `yaml:"objects" json:"objects"`
Items []Item `yaml:"items" json:"items"`
Proxies []Proxy `yaml:"proxies" json:"proxies"`
Webhooks []Webhook `yaml:"webhooks" json:"webhooks"`
Objects []Object `yaml:"objects" json:"objects"`
Items []Item `yaml:"items" json:"items"`
Proxies []Proxy `yaml:"proxies" json:"proxies"`
Webhooks []Webhook `yaml:"webhooks" json:"webhooks"`
}
105 changes: 32 additions & 73 deletions pkg/runner/monitor/monitor.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading