GetDeployingProgress 추가
This commit is contained in:
@ -517,3 +517,7 @@ func (h *houstonHandler) GetLogFileLinks(w http.ResponseWriter, r *http.Request)
|
||||
enc := json.NewEncoder(w)
|
||||
enc.Encode(out)
|
||||
}
|
||||
|
||||
func (h *houstonHandler) GetDeployingProgress(w http.ResponseWriter, r *http.Request) {
|
||||
json.NewEncoder(w).Encode(h.Operation().DeplyingProgress())
|
||||
}
|
||||
|
||||
@ -418,6 +418,10 @@ func (os *operationServer) Hosts() map[string]hostSnapshot {
|
||||
return os.hp.allHosts()
|
||||
}
|
||||
|
||||
func (os *operationServer) DeplyingProgress() []*protos.DeployingProgress {
|
||||
return os.db.clone()
|
||||
}
|
||||
|
||||
func newOperationServer() *operationServer {
|
||||
return &operationServer{
|
||||
hp: hostPool{
|
||||
|
||||
@ -108,6 +108,7 @@ type Operation interface {
|
||||
RestartProcess(RestartProcessRequest)
|
||||
Upload(UploadRequest)
|
||||
Hosts() map[string]hostSnapshot
|
||||
DeplyingProgress() []*protos.DeployingProgress
|
||||
}
|
||||
|
||||
func loadServerConfig() serverConfig {
|
||||
|
||||
Reference in New Issue
Block a user