[Fleet] Add action to Add tags to Agent details page#225433
[Fleet] Add action to Add tags to Agent details page#225433juliaElastic merged 4 commits intoelastic:mainfrom
Conversation
|
Pinging @elastic/fleet (Team:Fleet) |
MichelLosier
left a comment
There was a problem hiding this comment.
Looks great! Just an edge case with inactive agents to look at.
| // Fetch all tags when the component mounts | ||
| const fetchTags = async () => { | ||
| try { | ||
| const agentTagsResponse = await sendGetAgentTags({}); |
There was a problem hiding this comment.
When I was clicking through this, I incidentally only had inactive agents with tags, and when I went to use this my tag list was blank. If a user is viewing an inactive agent, I think we should include the showInactive option.
| const agentTagsResponse = await sendGetAgentTags({}); | |
| const agentTagsResponse = await sendGetAgentTags({ showInactive: !agent?.active }); |
What are your thoughts though of showing tags from inactive agents when viewing active agents? In the same way that we don't by default show inactive agents by default in the agent list, maybe a user is less interested in the tags used by an old fleet of agents, but I could also see it being useful if someone was transitioning to a new fleet of agents and wanting to still use tags from old inactive ones.
There was a problem hiding this comment.
Good catch, updated to fetch tags for inactive agents.
Actually agent.active:false stands for unenrolled agents, for those the Add tags action is disabled.
Inactive agents can be identified with agent.status: inactive.
💚 Build Succeeded
Metrics [docs]Async chunks
History
|
Summary
Closes #222765
Add "Add / remove tags" to Action details page
agent_details_tags.mov
Unenrolled agent
Inactive agent