跳到正文
Skillpedia
部署与云(DevOps)17k · #10792

wiztelemetry-tracing

它能做什么

这个技能帮助 AI 智能体在 KubeSphere 中设置分布式追踪。适合希望跟踪请求穿过多个服务,以找出缓慢或出错环节的开发者和运维人员。

适用场景

  • ✓当你想安装追踪功能,以便跟踪跨服务的请求时。
  • ✓当你想为应用添加 OpenTelemetry 自动插桩时。
  • ✓当你需要为某个缓慢的请求查询追踪、跨度(span)或服务图时。

技能链接

https://github.com/kubesphere/kubesphere/blob/master/skills/wiztelemetry-tracing/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/kubesphere/kubesphere/blob/master/skills/wiztelemetry-tracing/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请帮我安装追踪扩展,并显示今天结账服务最慢的几条追踪记录。”

每周 5 个新技能,1 分钟读完。

工作原理

智能体会先检查平台服务和 OpenSearch,然后安装所需的追踪组件,例如收集器和生成器。之后,它通过追踪查询 API 查询追踪和跨度。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

WizTelemetry Tracing

Overview

WizTelemetry Tracing is an extension component in the KubeSphere Observability Platform that provides distributed tracing functionality based on the OpenTelemetry standard.

When to Use

  • Installing or configuring the WizTelemetry Tracing extension
  • Understanding tracing architecture (Generator + Operator + Collector + Agent)
  • Using the tracing query API to query traces, spans, service graphs
  • Configuring OpenTelemetry auto-instrumentation for applications

Components

Component Description Default Enabled
generator WizTelemetry Tracing Generator: generates service graphs from tracing data (StatefulSet) true
operator OpenTelemetry Operator: manages OpenTelemetry Collector and auto-instrumentation true
collector OpenTelemetry Collector for WizTelemetry: receives traces, exports to Vector and OpenSearch true
agent WizTelemetry Tracing Agent: collects tracing data from local log files (DaemonSet) false
demo OpenTelemetry Demo: generates sample tracing data for demonstration false

Dependencies

  • WizTelemetry Platform Service (whizard-telemetry): Required
  • OpenSearch (opensearch): Required

Installation

Prerequisites

REQUIRED: Complete all steps in order before generating InstallPlan.

Step 1: Get Available Clusters and Confirm Target

CRITICAL: DO NOT proceed until target clusters are determined.

Step 1.1: Get available clusters

kubectl get clusters -o jsonpath='{.items[*].metadata.name}'

Step 1.2: Determine target clusters

  • If user explicitly specified target clusters in the request -> Use those clusters directly, proceed to Step 2
  • If user did NOT specify target clusters -> Ask user to confirm which clusters to deploy to, then proceed to Step 2

Ask user (if not specified):

Available clusters: host, dev
Which clusters do you want to deploy WizTelemetry Tracing to?

Step 2: Get Latest Version (if not provided by user)

MUST do this to get the latest version:

kubectl get extensionversions -n kubesphere-system -l kubesphere.io/extension-ref=wiztelemetry-tracing -o jsonpath='{range .items[*]}{.spec.version}{"\n"}{end}' | sort -V | tail -1

This outputs the latest version (e.g., 1.0.6). Note this down - you'll use it in the InstallPlan.

Step 3: Get Generator Endpoint

Get a node IP from the target cluster:

kubectl get nodes -o jsonpath='{.items[0].status.addresses[?(@.type=="ExternalIP")].address}' 2>/dev/null || \
kubectl get nodes -o jsonpath='{.items[0].status.addresses[?(@.type=="InternalIP")].address}'

This outputs a node IP (e.g., 192.168.1.100). Use this as the generator endpoint.

If multiple shards (e.g., generator.shardCount: 3), generate all endpoints:

NODE_IP="<NODE_IP>"
for i in 0 1 2; do
  PORT=$((32318 + i))
  echo "  - http://${NODE_IP}:${PORT}"
done

Replace <NODE_IP> with the actual node IP from the previous command.

Step 4: Confirm Configuration with User

Before creating the InstallPlan, confirm the following with the user:

I'll install WizTelemetry Tracing with the following configuration:
- Version: <VERSION>
- Target clusters: <TARGET_CLUSTERS>
- Generator endpoint: http://<NODE_IP>:32318
- OpenSearch endpoint: <OPENSEARCH_ENDPOINT>

Do you want to proceed? (yes/no)

If user confirms, proceed to create the InstallPlan. If not, adjust the configuration based on user feedback.

Step 5: Create InstallPlan

CRITICAL: InstallPlan metadata.name MUST be wiztelemetry-tracing. DO NOT use any other name.

CRITICAL: config field is YAML format. You MUST:

  • Use the config structure exactly as shown in the template
  • DO NOT add configuration fields that are not shown in the template
  • DO NOT modify the structure or hierarchy

CRITICAL: All placeholders MUST be replaced with actual values. DO NOT leave them as placeholders.

Based on your selections:

  • Target clusters: User-confirmed cluster names
  • OpenSearch endpoint: User-provided (default: https://opensearch-cluster-data.kubesphere-logging-system.svc:9200)
  • OpenSearch credentials: User-provided (default user: admin)

Template

apiVersion: kubesphere.io/v1alpha1
kind: InstallPlan
metadata:
  name: wiztelemetry-tracing
  namespace: kubesphere-sys
常见问题

追踪功能依赖什么?

它依赖 WizTelemetry Platform Service 和 OpenSearch。

它会安装哪些组件?

它可以安装生成器、操作器、收集器、代理,以及可选的演示组件。

需要修改应用吗?

该技能涵盖 OpenTelemetry 自动插桩,这是为应用添加追踪的一种方式。

详情

作者的原始描述

Use when working with WizTelemetry Tracing extension for KubeSphere, including installation, configuration, and tracing query API

repo: kubesphere/kubesphere

热度

GitHub 星标
17k
排名
#10792
许可证
—
更新时间
2026/7/14

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能