@blueking/open-telemetry 0.0.12 → 0.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -7
- package/dist/bk-rum.global.js +1 -1
- package/dist/bk-rum.global.js.map +1 -1
- package/dist/index.js +261 -260
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/skills/bk-rum-otele/SKILL.md +1 -1
- package/skills/bk-rum-otele/evals/evals.json +1 -1
- package/skills/bk-rum-otele/references/configuration.md +4 -4
- package/skills/bk-rum-otele/references/troubleshooting.md +2 -2
package/package.json
CHANGED
|
@@ -88,7 +88,7 @@ CDN:
|
|
|
88
88
|
</script>
|
|
89
89
|
```
|
|
90
90
|
|
|
91
|
-
`transport.endpoint`
|
|
91
|
+
`transport.endpoint` 填上报根地址(通常包含 `/v1` 路径前缀),SDK 自动拼 `/rum`、`/metrics`、`/logs`;`token` 作为 `Authorization: Bearer <token>` 默认头。构造后默认 `autoStart: true` 自动启动,无需手动 `start()`。
|
|
92
92
|
|
|
93
93
|
## 默认采集能力清单
|
|
94
94
|
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
{
|
|
13
13
|
"id": 1,
|
|
14
14
|
"name": "local-no-data-troubleshoot",
|
|
15
|
-
"prompt": "我按文档接了 bk-rum,本地起了 collector 在 4318,但 Network 里没看到 /
|
|
15
|
+
"prompt": "我按文档接了 bk-rum,本地起了 collector 在 4318,但 Network 里没看到 /rum 请求,reportCustomEvent 也没上报,debug 我也开了。可能是什么问题?怎么排查?",
|
|
16
16
|
"expected_output": "排障应覆盖:sampling.rate 是会话级 sticky 采样、未命中时插件不启动且手动事件静默丢弃(建议调试设 rate:1);enabled 是否为 false;建议 spanProcessor:'simple' 便于本地看数据;检查 collector 是否监听 4318、endpoint 是否正确。",
|
|
17
17
|
"files": [],
|
|
18
18
|
"assertions": []
|
|
@@ -185,14 +185,14 @@ new BkOpenTelemetry({
|
|
|
185
185
|
|
|
186
186
|
# 上报与采样
|
|
187
187
|
|
|
188
|
-
SDK 使用 OTLP HTTP exporter 分别上报 traces、metrics、logs。默认 endpoint 是 `http://localhost:4318`,会自动拼接 `/
|
|
188
|
+
SDK 使用 OTLP HTTP exporter 分别上报 traces、metrics、logs。默认 endpoint 是 `http://localhost:4318`,会自动拼接 `/rum`、`/metrics`、`/logs`。
|
|
189
189
|
|
|
190
190
|
## 统一 endpoint
|
|
191
191
|
|
|
192
192
|
```ts
|
|
193
193
|
new BkOpenTelemetry({
|
|
194
194
|
transport: {
|
|
195
|
-
endpoint: 'https://rum-collector.example.com',
|
|
195
|
+
endpoint: 'https://rum-collector.example.com/v1',
|
|
196
196
|
token: 'report-token',
|
|
197
197
|
},
|
|
198
198
|
});
|
|
@@ -200,7 +200,7 @@ new BkOpenTelemetry({
|
|
|
200
200
|
|
|
201
201
|
实际使用的上报地址为:
|
|
202
202
|
|
|
203
|
-
- traces:`https://rum-collector.example.com/v1/
|
|
203
|
+
- traces:`https://rum-collector.example.com/v1/rum`
|
|
204
204
|
- metrics:`https://rum-collector.example.com/v1/metrics`
|
|
205
205
|
- logs:`https://rum-collector.example.com/v1/logs`
|
|
206
206
|
|
|
@@ -217,7 +217,7 @@ new BkOpenTelemetry({
|
|
|
217
217
|
},
|
|
218
218
|
signals: {
|
|
219
219
|
endpoints: {
|
|
220
|
-
traces: 'https://trace-gateway.example.com/v1/
|
|
220
|
+
traces: 'https://trace-gateway.example.com/v1/rum',
|
|
221
221
|
metrics: 'https://metric-gateway.example.com/v1/metrics',
|
|
222
222
|
logs: 'https://log-gateway.example.com/v1/logs',
|
|
223
223
|
},
|
|
@@ -24,7 +24,7 @@ new BkOpenTelemetry({
|
|
|
24
24
|
检查点:
|
|
25
25
|
|
|
26
26
|
- Collector 是否监听 `4318`。
|
|
27
|
-
- 浏览器 Network 中是否有 `/
|
|
27
|
+
- 浏览器 Network 中是否有 `/rum`、`/metrics`、`/logs` 请求。
|
|
28
28
|
- 是否被采样丢弃。
|
|
29
29
|
- `enabled` 是否为 `false`。
|
|
30
30
|
|
|
@@ -206,7 +206,7 @@ new BkOpenTelemetry({
|
|
|
206
206
|
transport: {
|
|
207
207
|
signals: {
|
|
208
208
|
endpoints: {
|
|
209
|
-
traces: 'https://trace-gateway.example.com/v1/
|
|
209
|
+
traces: 'https://trace-gateway.example.com/v1/rum',
|
|
210
210
|
metrics: 'https://metric-gateway.example.com/v1/metrics',
|
|
211
211
|
logs: 'https://log-gateway.example.com/v1/logs',
|
|
212
212
|
},
|