feat(kiali): add built-in MCP prompts to the Kiali toolset#1176
Conversation
fdcb75e to
7136aca
Compare
|
Thank you for the suggestions Josune, all were valid, also I add missing handler for istio config list. |
Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> Co-authored-by: Cursor <cursoragent@cursor.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
manusa
left a comment
There was a problem hiding this comment.
Thanks for this — the structure is clean (the listResourceHandler factory is a nice touch), the README/docs/configuration.md regenerate with no drift, and build/vet/the kiali suite all pass.
Reviewing from the kubernetes-mcp-server side — Kiali owns the toolset's deeper behavior and its own tests, so I've kept this to three things worth a look before merge:
traffic-topologycan fail on its default no-arg invocation —get_mesh_traffic_graphmarksnamespacesrequired, but the prompt makes it optional and hard-fails when omitted.- Generic prompt names —
list-namespaces/list-services/list-workloadsaren't mesh-qualified; withcore+kialienabled they read like core cluster ops, and this will only get worse ascoreadds its own prompts. service-troubleshoothardcodes a-v1workload suffix — fine for bookinfo, empty logs for most real services.
Not flagging test coverage — assuming that's handled in the Kiali repo.
|
Thank you very much @manusa for the review, all points were approached. |
|
Hi @hhovsepy thanks for taking care of this. Last commit wasn't signed off and we have a DCO failure. |
manusa
left a comment
There was a problem hiding this comment.
Thanks for the iterations, @hhovsepy — the prompt naming and the -v1 workload suffix from my earlier review are both sorted. josunect's threads are all resolved and the suite/docs are clean.
One thing left before this is good to go — it's the other half of my original traffic-graph comment:
mesh-topology ships with its traffic-graph section permanently empty. meshTopologyHandler calls get_mesh_traffic_graph with no namespaces, but that endpoint requires them, so the section always degrades to (data unavailable: …). traffic-topology already solves this with resolveNamespaces — same fix applies here (details inline). That's the only blocker from my side.
Non-blocking polish, take it or leave it:
- "all mesh namespaces" in the
traffic-topologyarg/error/README actually means all accessible namespaces — minor wording. - A one-line comment on
fetchKialiDatato mark the soft-fail intentional (it's what hid the issue above). - A
mesh-topologytest would've caught this — worth one with the fix, though I'm leaving broader coverage to the Kiali repo.
Fix the mesh-topology graph and I'm happy to approve.
Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com>
manusa
left a comment
There was a problem hiding this comment.
Thanks @hhovsepy — all my review points are addressed. mesh-topology now resolves namespaces before the traffic-graph call (with TestMeshTopologyPrompt covering it), and the wording and fetchKialiData doc comment are in too. Verified build/vet/the Kiali suite locally. LGTM.
…s#1176) * Added Kiali MCP prompts Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> Co-authored-by: Cursor <cursoragent@cursor.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Apply suggestion from @josunect Co-authored-by: Josune Cordoba <49480155+josunect@users.noreply.github.com> Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Added the missing handler for Istio config list Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Update tests Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * Approached all comments Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * approached comments Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> * fixed README Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> --------- Signed-off-by: Hayk Hovsepyan <hhovsepy@redhat.com> Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: josunect <jcordoba@redhat.com>

Summary
Kiali PR: kiali/kiali#9768