feat(gns3_copilot): enhance topology logging with structured details

Improve logging in GNS3 topology reader to provide more structured and informative output. The previous single-line JSON log has been replaced with separate info and debug logs:
- Info log now includes project ID, project name, node count, and link count
- Debug log retains the full topology details for deeper inspection
This makes it easier to monitor topology retrieval in production while keeping detailed data available for debugging.
This commit is contained in:
YueGuobin 2026-03-04 17:43:41 +08:00
parent ef712ad314
commit 0648b53a45

View File

@ -90,7 +90,12 @@ class GNS3TopologyTool(BaseTool):
}
# Log topology result
logger.info("Topology retrieved: %s", topology)
logger.info("Topology retrieved: project_id=%s, name=%s, nodes=%d, links=%d",
topology.get("project_id"),
topology.get("name"),
len(topology.get("nodes", {})),
len(topology.get("links", [])))
logger.debug("Topology details: %s", topology)
return topology