Skip to content

Commit 0ede889

Browse files
authored
Merge branch 'main' into openinference
2 parents 6d7d3e4 + fadd494 commit 0ede889

27 files changed

+87
-32
lines changed

content/ja/_index.md

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ description: >-
44
効果的な観測を可能にする、高品質でユビキタスかつポータブルなテレメトリー
55
developer_note:
66
blocks/coverコラム(以下で使用)は、ファイル名に "background" を含む画像ファイルを背景画像として使用します。
7+
default_lang_commit: 902043db
78
---
89

910
<div class="d-none"><a rel="me" href="https://fosstodon.org/@opentelemetry"></a></div>

content/zh/_index.md

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ show_banner: true
66
developer_note:
77
下文所用的 blocks/cover 短代码将使用文件名中包含 "background"
88
的图像文件作为背景图。
9+
default_lang_commit: 6e35a949
910
---
1011

1112
<div class="d-none"><a rel="me" href="https://fosstodon.org/@opentelemetry"></a></div>

content/zh/docs/_index.md

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: 文档
33
menu: { main: { weight: 10 } }
4+
default_lang_commit: 6e35a949
45
---
56

67
OpenTelemetry 也被称为 OTel,是一个供应商中立的、开源的[可观测性](concepts/observability-primer/#what-is-observability)框架,

content/zh/docs/concepts/_index.md

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ linkTitle: 概念
44
description: OpenTelemetry 核心概念
55
aliases: [concepts/overview]
66
weight: 170
7+
default_lang_commit: d638c386
78
---
89

910
在本节中,你将了解 OpenTelemetry 项目的数据来源和关键组件。

content/zh/docs/concepts/components.md

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ title: 组件
33
description: 构成 OpenTelemetry 的主要组件
44
aliases: [data-collection]
55
weight: 20
6+
default_lang_commit: 1ca30b4d
67
---
78

89
OpenTelemetry 项目目前由以下几个主要部分构成:

content/zh/docs/concepts/context-propagation.md

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
title: 上下文传播
33
weight: 10
44
description: 了解实现分布式追踪的概念。
5+
default_lang_commit: 7bb7dbb6
56
---
67

78
通过上下文传播,[信号](/docs/concepts/signals)可以相互关联,

content/zh/docs/concepts/semantic-conventions.md

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
title: 语义约定
33
description: 不同类型的操作和数据的通用名称。
44
weight: 30
5+
default_lang_commit: 71d813acaa3dcb7d8ae3f96451406276f84242f4
56
---
67

78
OpenTelemetry 定义了[语义约定](/docs/specs/semconv/)

content/zh/docs/demo/_index.md

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ cascade:
55
repo: https://github.com/open-telemetry/opentelemetry-demo
66
weight: 2
77
cSpell:ignore: OLJCESPC
8+
default_lang_commit: b7ee690154aacc8d6e43636af00743994fb6dc27
89
---
910

1011
欢迎使用 [OpenTelemetry 演示](/ecosystem/demo/)文档,

content/zh/docs/kubernetes/_index.md

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ title: 使用 Kubernetes 部署 OpenTelemetry
33
linkTitle: Kubernetes
44
weight: 11
55
description: Using OpenTelemetry with Kubernetes
6+
default_lang_commit: 54bc7873eaf53af1314feef7f91797d5d261a57b
67
---
78

89
## 介绍

content/zh/docs/what-is-opentelemetry.md

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
title: 什么是 OpenTelemetry?
33
description: 简短说明 OpenTelemetry 是什么,不是什么。
44
weight: 150
5+
default_lang_commit: d638c386
56
---
67

78
OpenTelemetry

data/registry/collector-builder.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,5 @@ createdAt: 2023-12-18
1717
package:
1818
registry: go
1919
name: go.opentelemetry.io/collector/cmd/builder
20-
version: v0.102.0
20+
version: v0.102.1
2121
quickInstall: false

data/registry/collector-exporter-debug.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ createdAt: 2020-11-05
1616
package:
1717
registry: go-collector
1818
name: go.opentelemetry.io/collector/exporter/debugexporter
19-
version: v0.102.0
19+
version: v0.102.1

data/registry/collector-exporter-nop.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@ createdAt: 2024-04-18
1919
package:
2020
registry: go-collector
2121
name: go.opentelemetry.io/collector/exporter/nopexporter
22-
version: v0.102.0
22+
version: v0.102.1

data/registry/collector-exporter-otlp.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ createdAt: 2020-11-05
1616
package:
1717
registry: go-collector
1818
name: go.opentelemetry.io/collector/exporter/otlpexporter
19-
version: v0.102.0
19+
version: v0.102.1

data/registry/collector-extension-memorylimiter.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ createdAt: 2024-04-18
1818
package:
1919
registry: go-collector
2020
name: go.opentelemetry.io/collector/extension/memorylimiterextension
21-
version: v0.102.0
21+
version: v0.102.1

data/registry/collector-processor-batch.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ createdAt: 2021-02-24
1818
package:
1919
registry: go-collector
2020
name: go.opentelemetry.io/collector/processor/batchprocessor
21-
version: v0.102.0
21+
version: v0.102.1

data/registry/collector-receiver-nop.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ createdAt: 2024-04-18
1818
package:
1919
registry: go-collector
2020
name: go.opentelemetry.io/collector/receiver/nopreceiver
21-
version: v0.102.0
21+
version: v0.102.1

data/registry/collector-receiver-otlp.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ createdAt: 2020-11-05
1616
package:
1717
registry: go-collector
1818
name: go.opentelemetry.io/collector/receiver/otlpreceiver
19-
version: v0.102.0
19+
version: v0.102.1

data/registry/exporter-js-jaeger.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ createdAt: 2020-02-06
1414
package:
1515
registry: npm
1616
name: '@opentelemetry/exporter-jaeger'
17-
version: 1.24.1
17+
version: 1.25.0

data/registry/exporter-js-prometheus.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ createdAt: 2020-02-06
1414
package:
1515
registry: npm
1616
name: '@opentelemetry/exporter-prometheus'
17-
version: 0.51.1
17+
version: 0.52.0

data/registry/exporter-js-zipkin.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ authors:
1111
package:
1212
name: '@opentelemetry/exporter-zipkin'
1313
registry: npm
14-
version: 1.24.1
14+
version: 1.25.0
1515
urls:
1616
repo: https://github.com/open-telemetry/opentelemetry-js/tree/main/packages/opentelemetry-exporter-zipkin
1717
docs: /docs/languages/js/exporters/#zipkin

data/registry/instrumentation-js-fetch.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ createdAt: 2020-11-09
1414
package:
1515
registry: npm
1616
name: '@opentelemetry/instrumentation-fetch'
17-
version: 0.51.1
17+
version: 0.52.0

data/registry/instrumentation-js-grpc.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ createdAt: 2020-11-09
1414
package:
1515
registry: npm
1616
name: '@opentelemetry/instrumentation-grpc'
17-
version: 0.51.1
17+
version: 0.52.0

data/registry/instrumentation-js-http.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ createdAt: 2020-11-09
1414
package:
1515
registry: npm
1616
name: '@opentelemetry/instrumentation-http'
17-
version: 0.51.1
17+
version: 0.52.0

data/registry/instrumentation-js-xml-http-request.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ createdAt: 2020-11-09
1414
package:
1515
registry: npm
1616
name: '@opentelemetry/instrumentation-xml-http-request'
17-
version: 0.51.1
17+
version: 0.52.0

scripts/i18n-check.sh

+58-17
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,30 @@
22
#
33
# Inspired by https://github.com/kubernetes/website/blob/main/scripts/lsync.sh
44

5+
DEFAULT_LANG="en"
6+
DEFAULT_TARGET="content"
57
EXTRA_DIFF_ARGS="--numstat"
8+
FLAG_UPDATE=""
9+
FLAG_VERBOSE=""
10+
I18N_DLC_KEY="default_lang_commit"
611
TARGET_PATHS=""
712

813
function _usage() {
914
cat <<EOS
10-
Usage: $(basename "$0") [options] TARGET_PATH ...
15+
Usage: $(basename "$0") [options] [TARGET_PATH ...]
1116
1217
For each localized page target, this script reports whether the English
1318
language version of that page has changed since the localized file was
1419
first written or last edited.
1520
1621
TARGET_PATH can be a single markdown file of a localized page, such as
1722
'content/ja/_index.md', or a directory of localized pages, such as 'content/ja'.
23+
The default TARGET_PATH is '$DEFAULT_TARGET'.
1824
1925
-h Output this usage info.
2026
-d Output diff details.
21-
-v Verbose mode.
27+
-u Update, or add, target commit hashes to match the last commit they were updated from.
28+
-v Enables verbose command progress and status output.
2229
EOS
2330
}
2431

@@ -29,16 +36,19 @@ function usage() {
2936
}
3037

3138
function process_CLI_args() {
32-
while getopts ":hdv" opt; do
39+
while getopts ":hduv" opt; do
3340
case $opt in
3441
h)
3542
usage
3643
;;
3744
d)
3845
EXTRA_DIFF_ARGS=""
3946
;;
47+
u)
48+
FLAG_UPDATE=1
49+
;;
4050
v)
41-
VERBOSE=1
51+
FLAG_VERBOSE=1
4252
;;
4353
\?)
4454
echo "ERROR: unrecognized flag: -$OPTARG"
@@ -48,48 +58,79 @@ function process_CLI_args() {
4858
done
4959

5060
shift $((OPTIND-1))
51-
if [ "$#" -lt 1 ]; then
52-
echo "ERROR: target path argument is missing" >&2
53-
usage 1
54-
fi
55-
5661
TARGET_PATHS="$@"
5762

63+
if [[ -z "$TARGET_PATHS" ]]; then
64+
TARGET_PATHS="$DEFAULT_TARGET"
65+
if [[ -n $FLAG_VERBOSE ]]; then echo "INFO: using default target path: $TARGET_PATHS"; fi
66+
fi
67+
5868
if [[ -f "TARGET_PATHS" && ! -e "$TARGET_PATHS" ]] ; then
5969
echo "Path not found: '$TARGET_PATHS'" >&2
6070
exit 2
6171
fi
6272
}
6373

74+
function update_i18n_hash() {
75+
# Usage: update_i18n_hash <file> <commit>
76+
#
77+
# Adds to or updates the file's front matter's field
78+
# $I18N_DLC_KEY with value <commit>.
79+
80+
local LASTCOMMIT="$1"
81+
local f="$2"
82+
83+
if grep -q "^$I18N_DLC_KEY:" "$f"; then
84+
perl -i -pe "s/(^$I18N_DLC_KEY):.*/\$1: $LASTCOMMIT/" "$f"
85+
else
86+
perl -i -0777 -pe "s/^(---.*?)(\n---\n)/\$1\n$I18N_DLC_KEY: $LASTCOMMIT\$2/sm" "$f"
87+
fi
88+
if [[ -n $FLAG_VERBOSE ]]; then
89+
echo -e "i18n commit ID\t$f $LASTCOMMIT - updated"
90+
fi
91+
}
92+
6493
function main() {
6594
process_CLI_args "$@"
6695

6796
if [ -f "$TARGET_PATHS" ] ; then
6897
TARGETS="$TARGET_PATHS"
6998
else
70-
TARGETS=$(find $TARGET_PATHS -name "*.md")
99+
TARGETS=$(find $TARGET_PATHS -name "*.md" -not -path "*/$DEFAULT_LANG/*")
71100
if [[ -z "$TARGETS" ]]; then
72101
echo "ERROR: target directory contains no markdown files: '$TARGET_PATHS'" >&2
73102
exit 1
74103
fi
75-
# if [[ -n $VERBOSE ]]; then echo -e "All targets: $TARGETS"; fi
104+
# if [[ -n $FLAG_VERBOSE ]]; then echo -e "All targets: $TARGETS"; fi
76105
fi
77106

78107
SYNCED=1
79108
for f in $TARGETS; do
80-
# if [[ -n $VERBOSE ]]; then echo -e "Checking\t$f"; fi
109+
# if [[ -n $FLAG_VERBOSE ]]; then echo -e "Checking\t$f"; fi
81110
EN_VERSION=$(echo "$f" | sed "s/content\/.\{2,5\}\//content\/en\//g")
111+
112+
# Try to get commit ref from file front matter
113+
LASTCOMMIT=$(perl -ne "print \"\$1\" if /^$I18N_DLC_KEY:\\s*(.*)/" "$f")
114+
if [[ -z $LASTCOMMIT ]]; then
115+
# Get commit hash from git commit info
116+
LASTCOMMIT=$(git log -n 1 --pretty=format:%h -- "$f")
117+
fi
118+
119+
if [[ -n $FLAG_UPDATE ]]; then
120+
update_i18n_hash "$LASTCOMMIT" "$f"
121+
fi
122+
82123
if [[ ! -e "$EN_VERSION" ]]; then
83-
echo "Base file renamed or removed: $EN_VERSION"
124+
echo -e "File not found\t$EN_VERSION - $f - $DEFAULT_LANG was removed or renamed"
84125
SYNCED=0
85126
continue
86127
fi
87128

88-
LASTCOMMIT=$(git log -n 1 --pretty=format:%h -- "$f")
89-
git diff --exit-code $EXTRA_DIFF_ARGS $LASTCOMMIT...HEAD "$EN_VERSION"
90-
if [ $? -ne 0 ] ; then
129+
DIFF=$(git diff --exit-code $EXTRA_DIFF_ARGS $LASTCOMMIT...HEAD "$EN_VERSION")
130+
if [[ -n "$DIFF" ]]; then # [[ $? -ne 0 ]]
131+
echo "$DIFF - $f"
91132
SYNCED=0
92-
elif [[ -n $VERBOSE ]]; then
133+
elif [[ -n $FLAG_VERBOSE ]]; then
93134
echo -e "File is in sync\t$f"
94135
fi
95136
done

static/refcache.json

+4
Original file line numberDiff line numberDiff line change
@@ -3303,6 +3303,10 @@
33033303
"StatusCode": 200,
33043304
"LastSeen": "2024-06-05T09:07:28.023907247Z"
33053305
},
3306+
"https://github.com/open-telemetry/opentelemetry-collector/releases/tag/cmd%2Fbuilder%2Fv0.102.1": {
3307+
"StatusCode": 200,
3308+
"LastSeen": "2024-06-06T16:28:34.255663872Z"
3309+
},
33063310
"https://github.com/open-telemetry/opentelemetry-collector/releases/tag/cmd%2Fbuilder%2Fv0.95.0": {
33073311
"StatusCode": 200,
33083312
"LastSeen": "2024-03-01T16:49:42.006164+01:00"

0 commit comments

Comments
 (0)