cx-datasets
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseDatasets Skill
数据集 Skill
Coralogix data lives in datasets, addressed as —
e.g. , , . Every
DataPrime query starts with , so before querying
an unfamiliar team (or a source you are not sure exists), list what is actually
queryable instead of guessing names.
<dataspace>/<dataset>default/logsdefault/rum.eventssystem/labs.limitViolationssource <dataspace>/<dataset>Coralogix 数据位于 datasets 中,使用 寻址——例如 、、。每个 DataPrime 查询都始于 ,因此,在查询陌生团队(或不确定 source 是否存在)之前,应先列出实际可查询的数据集,而不是猜测名称。
<dataspace>/<dataset>default/logsdefault/rum.eventssystem/labs.limitViolationssource <dataspace>/<dataset>CLI Commands
CLI 命令
| Command | Purpose | Key flags |
|---|---|---|
| List every dataset queryable by the current profile's team | |
| Same, as a JSON array of dataset rows | - |
- Supports (repeatable) for multi-profile fan-out; a
-p <profile>key is added to each JSON row when more than one profile is targeted.profile - Read-only — no confirmation needed.
--yes
| 命令 | 用途 | 关键参数 |
|---|---|---|
| 列出当前 profile 所属团队可查询的所有数据集 | |
| 以 JSON 数组形式返回相同的数据集行 | - |
- 支持使用 (可重复)进行 multi-profile 扇出;针对多个 profile 时,每个 JSON 行都会增加一个
-p <profile>键。profile - 只读操作——无需使用 确认。
--yes
Dataset Row Fields
数据集行字段
| Field | Meaning |
|---|---|
| The dataset's dataspace, e.g. |
| The dataset name inside its dataspace, e.g. |
| The pillar the data belongs to: |
| The entity type behind the dataset, e.g. |
| The latest dataset version |
| The team that owns the dataset |
Only read-enabled, latest-version datasets are returned. The column in
text output is the copy-pasteable argument.
Sourcesource| 字段 | 含义 |
|---|---|
| 数据集所属的 dataspace,例如 |
| dataspace 内的数据集名称,例如 |
| 数据所属的 pillar: |
| 数据集对应的实体类型,例如 |
| 数据集的最新版本 |
| 拥有该数据集的团队 |
仅返回已启用读取权限的最新版本数据集。文本输出中的 列可直接复制,作为 参数。
SourcesourceWorkflow
工作流
-
List the datasets to see what exists:bash
cx datasets list cx datasets list -o json | jq -r '.[] | .dataspace + "/" + .dataset' | sort -
Narrow with a DPXL filter when looking for a specific pillar or dataspace:bash
cx datasets list --filter "<v1> \$d.pillar == 'logs'" cx datasets list --filter "<v1> \$d.dataspace == 'default' && \$d.pillar == 'data'" cx datasets list --filter "<v1> \$d.dataset.contains('rum')" -o json -
Query the dataset with DataPrime, using the full source name:bash
cx dataprime query --source default/checkoutservice_dataset 'filter $d.severity == ERROR' cx dataprime query --source system/labs.limitViolations 'filter $m.timestamp > now()-1h'is a--sourceflag —cx dataprime queryandcx logsalways query the legacycx spans/logsdatasets and take no source override.spans
-
列出数据集,查看存在哪些数据集:bash
cx datasets list cx datasets list -o json | jq -r '.[] | .dataspace + "/" + .dataset' | sort -
使用 DPXL 过滤器缩小范围,查找特定的 pillar 或 dataspace:bash
cx datasets list --filter "<v1> \$d.pillar == 'logs'" cx datasets list --filter "<v1> \$d.dataspace == 'default' && \$d.pillar == 'data'" cx datasets list --filter "<v1> \$d.dataset.contains('rum')" -o json -
使用完整的 source 名称通过 DataPrime 查询数据集:bash
cx dataprime query --source default/checkoutservice_dataset 'filter $d.severity == ERROR' cx dataprime query --source system/labs.limitViolations 'filter $m.timestamp > now()-1h'是--source的 flag——cx dataprime query和cx logs始终查询旧版的cx spans/logs数据集,且不接受 source 覆盖。spans
DPXL Filter Syntax
DPXL 过滤语法
--filter<v1>$\$dAvailable fields: , , , ,
. Compare with / and combine with / . Substring
matching uses method-call syntax — (case-sensitive
substring), not an infix operator.
$d.dataspace$d.dataset$d.pillar$d.entityType$d.teamId==!=&&||$d.dataset.contains('rum')contains--filter<v1>$\$d可用字段包括:、、、、。可使用 / 进行比较,并使用 / 组合条件。子字符串匹配使用方法调用语法——(区分大小写的子字符串),而不是中缀 操作符。
$d.dataspace$d.dataset$d.pillar$d.entityType$d.teamId==!=&&||$d.dataset.contains('rum')containsKey Principles
关键原则
- Never guess dataset names — a query against a wrong source fails or, worse, silently returns the wrong data. List first, then query.
- The source is — both parts are needed in DataPrime
<dataspace>/<dataset>commands;sourcenot justdefault/logs.logs - Use with
-o jsonwhen you need just the source strings:jq.cx datasets list -o json | jq -r '.[] | .dataspace + "/" + .dataset' - Filter server-side with rather than listing everything and grepping locally — same result, less output to parse.
--filter - Multi-profile fan-out with (repeatable) lists datasets across environments in one call.
-p <profile>
- 绝不猜测数据集名称——使用错误的 source 执行查询会失败,更糟的是可能静默返回错误数据。请先列出,再查询。
- source 是 ——DataPrime
<dataspace>/<dataset>命令需要两部分;应使用source,不能只写default/logs。logs - 只需要 source 字符串时,使用 配合
-o json:jq。cx datasets list -o json | jq -r '.[] | .dataspace + "/" + .dataset' - 使用 在服务器端过滤,而不是列出全部内容后在本地 grep——结果相同,但需要解析的输出更少。
--filter - 使用 (可重复)进行 multi-profile 扇出,一次调用即可列出各环境中的数据集。
-p <profile>
Related Skills
相关 Skills
- — run the DataPrime queries against the datasets discovered here (logs, spans, metrics, RUM).
cx-telemetry-querying
- ——针对此处发现的数据集运行 DataPrime 查询(logs、spans、metrics、RUM)。
cx-telemetry-querying