mirror of
https://github.com/datarhei/core.git
synced 2025-12-24 13:07:56 +08:00
Fix tests and marshalling process config
This commit is contained in:
@@ -309,6 +309,7 @@ func (cfg *ProcessConfig) Unmarshal(c *app.Config, metadata map[string]interface
|
||||
io := ProcessConfigIO{
|
||||
ID: x.ID,
|
||||
Address: x.Address,
|
||||
Cleanup: []ProcessConfigIOCleanup{},
|
||||
}
|
||||
|
||||
io.Options = make([]string, len(x.Options))
|
||||
@@ -321,6 +322,7 @@ func (cfg *ProcessConfig) Unmarshal(c *app.Config, metadata map[string]interface
|
||||
io := ProcessConfigIO{
|
||||
ID: x.ID,
|
||||
Address: x.Address,
|
||||
Cleanup: []ProcessConfigIOCleanup{},
|
||||
}
|
||||
|
||||
io.Options = make([]string, len(x.Options))
|
||||
|
||||
@@ -29,4 +29,4 @@
|
||||
"reconnect": true,
|
||||
"reconnect_delay_seconds": 10,
|
||||
"stale_timeout_seconds": 10
|
||||
}
|
||||
}
|
||||
@@ -28,4 +28,4 @@
|
||||
"reconnect": true,
|
||||
"reconnect_delay_seconds": 10,
|
||||
"stale_timeout_seconds": 10
|
||||
}
|
||||
}
|
||||
@@ -29,4 +29,4 @@
|
||||
"reconnect": true,
|
||||
"reconnect_delay_seconds": 10,
|
||||
"stale_timeout_seconds": 10
|
||||
}
|
||||
}
|
||||
@@ -354,7 +354,9 @@ func (h *ProcessHandler) Update(c echo.Context) error {
|
||||
h.restream.SetProcessMetadata(tid, key, data)
|
||||
}
|
||||
|
||||
return c.JSON(http.StatusOK, process)
|
||||
p, _ := h.getProcess(tid, newFilter("config"))
|
||||
|
||||
return c.JSON(http.StatusOK, p.Config)
|
||||
}
|
||||
|
||||
// Command issues a command to a process
|
||||
|
||||
Reference in New Issue
Block a user