Enhance logging

This commit is contained in:
Ettore Di Giacinto
2024-04-19 00:15:53 +02:00
parent f6dcc09562
commit e2aa3bedd7
4 changed files with 25 additions and 16 deletions

View File

@@ -37,14 +37,11 @@ func (a *AgentConfig) availableActions(ctx context.Context) []Action {
actions := []Action{}
for _, action := range a.Actions {
xlog.Info("Set Action", action)
var config map[string]string
if err := json.Unmarshal([]byte(action.Config), &config); err != nil {
xlog.Info("Error unmarshalling action config", err)
continue
}
xlog.Info("Config", config)
switch action.Name {
case ActionSearch: