Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PMM-5680 add log to struct AgentInfo #866

Closed
wants to merge 6 commits into from
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,13 @@ gen-alertmanager: # Generate Alertmanager client.
go fmt ./api/alertmanager/...
go install -v ./api/alertmanager/...

update-deps:
go get -u ./...
cd tools && go get -u .
go get -t -u ./...
cd tools && go get -t -u .
go mod tidy

clean_swagger:
find api -name '*.swagger.json' -print -delete

Expand Down
108 changes: 59 additions & 49 deletions api/agentlocalpb/agentlocal.pb.go

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

2 changes: 2 additions & 0 deletions api/agentlocalpb/agentlocal.proto
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ message AgentInfo {
// The current listen port of this Agent (exporter or vmagent).
// Zero for other Agent types, or if unknown or not yet supported.
uint32 listen_port = 4;
//Store logs
repeated string logs = 5;
}

message StatusRequest {
Expand Down
34 changes: 22 additions & 12 deletions api/agentlocalpb/json/agentlocalpb.json
Original file line number Diff line number Diff line change
Expand Up @@ -143,15 +143,22 @@
"RDS_EXPORTER",
"EXTERNAL_EXPORTER",
"AZURE_DATABASE_EXPORTER"
],
"x-order": 1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why remove this?

]
},
"listen_port": {
"description": "The current listen port of this Agent (exporter or vmagent).\nZero for other Agent types, or if unknown or not yet supported.",
"type": "integer",
"format": "int64",
"x-order": 3
},
"logs": {
"type": "array",
"title": "Store logs",
"items": {
"type": "string"
},
"x-order": 4
},
"status": {
"description": "AgentStatus represents actual Agent status.\n\n - STARTING: Agent is starting.\n - RUNNING: Agent is running.\n - WAITING: Agent encountered error and will be restarted automatically soon.\n - STOPPING: Agent is stopping.\n - DONE: Agent finished.\n - UNKNOWN: Agent is not connected, we don't know anything about it's state.",
"type": "string",
Expand All @@ -164,8 +171,7 @@
"STOPPING",
"DONE",
"UNKNOWN"
],
"x-order": 2
]
}
}
},
Expand Down Expand Up @@ -214,8 +220,7 @@
"type": "string",
"x-order": 3
}
},
"x-order": 2
}
}
}
}
Expand Down Expand Up @@ -330,15 +335,22 @@
"RDS_EXPORTER",
"EXTERNAL_EXPORTER",
"AZURE_DATABASE_EXPORTER"
],
"x-order": 1
]
},
"listen_port": {
"description": "The current listen port of this Agent (exporter or vmagent).\nZero for other Agent types, or if unknown or not yet supported.",
"type": "integer",
"format": "int64",
"x-order": 3
},
"logs": {
"type": "array",
"title": "Store logs",
"items": {
"type": "string"
},
"x-order": 4
},
"status": {
"description": "AgentStatus represents actual Agent status.\n\n - STARTING: Agent is starting.\n - RUNNING: Agent is running.\n - WAITING: Agent encountered error and will be restarted automatically soon.\n - STOPPING: Agent is stopping.\n - DONE: Agent finished.\n - UNKNOWN: Agent is not connected, we don't know anything about it's state.",
"type": "string",
Expand All @@ -351,8 +363,7 @@
"STOPPING",
"DONE",
"UNKNOWN"
],
"x-order": 2
]
}
}
},
Expand Down Expand Up @@ -401,8 +412,7 @@
"type": "string",
"x-order": 3
}
},
"x-order": 2
}
}
}
}
Expand Down
45 changes: 30 additions & 15 deletions api/agentlocalpb/json/client/agent_local/agent_local_client.go

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

Loading