Skip to content

Commit dcf96dd

Browse files
authored
update weaver to 0.15.2 (#1629)
1 parent 873a39c commit dcf96dd

File tree

7 files changed

+725
-129
lines changed

7 files changed

+725
-129
lines changed

script/semantic-conventions/semconv.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ CODE_DIR="${ROOT_DIR}/src/SemConv"
2020
SEMCONV_VERSION=1.32.0
2121
SPEC_VERSION=v$SEMCONV_VERSION
2222
SCHEMA_URL=https://opentelemetry.io/schemas/$SEMCONV_VERSION
23-
OTEL_WEAVER_IMG_VERSION=v0.14.0
23+
OTEL_WEAVER_IMG_VERSION=v0.15.2
2424

2525
rm -rf "${SPEC_DIR}"
2626
mkdir "${SPEC_DIR}"

script/semantic-conventions/templates/registry/php/ResourceAttributeValues.php.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ interface ResourceAttributeValues
2121
* {{ member.brief or member.id }}
2222
*
2323
* @see ResourceAttributes::{{ c.attribute_name(attribute) }}
24-
{% if attribute.deprecated %}
24+
{% if attribute is deprecated %}
2525
* @deprecated {{ attribute.deprecated }}
2626
{% endif %}
2727
*/

script/semantic-conventions/templates/registry/php/weaver.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ text_maps:
1919
template[string[]]: string[]
2020

2121
templates:
22-
- pattern: Attributes.php.j2
22+
- template: Attributes.php.j2
2323
filter: >
2424
semconv_grouped_attributes({
2525
"exclude_root_namespace": $excluded_namespaces,
@@ -31,23 +31,23 @@ templates:
3131
})
3232
application_mode: single
3333
file_name: "TraceAttributes.php"
34-
- pattern: AttributeValues.php.j2
34+
- template: AttributeValues.php.j2
3535
filter: >
3636
semconv_grouped_attributes({
3737
"exclude_root_namespace": $excluded_namespaces,
3838
"exclude_stability": [],
3939
})
4040
application_mode: single
4141
file_name: "TraceAttributeValues.php"
42-
- pattern: ResourceAttributes.php.j2
42+
- template: ResourceAttributes.php.j2
4343
filter: >
4444
semconv_signal("resource"; {})
4545
| map(.attributes[])
4646
| group_by(.name)
4747
| map(.[-1])
4848
application_mode: single
4949
file_name: "ResourceAttributes.php"
50-
- pattern: ResourceAttributeValues.php.j2
50+
- template: ResourceAttributeValues.php.j2
5151
filter: >
5252
semconv_signal("resource"; {})
5353
| map(.attributes[])

src/SemConv/ResourceAttributeValues.php

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -532,12 +532,19 @@ interface ResourceAttributeValues
532532
public const OS_TYPE_SOLARIS = 'solaris';
533533

534534
/**
535-
* IBM z/OS
535+
* Deprecated. Use `zos` instead.
536536
*
537537
* @see ResourceAttributes::OS_TYPE
538538
*/
539539
public const OS_TYPE_Z_OS = 'z_os';
540540

541+
/**
542+
* IBM z/OS
543+
*
544+
* @see ResourceAttributes::OS_TYPE
545+
*/
546+
public const OS_TYPE_ZOS = 'zos';
547+
541548
/**
542549
* cpp
543550
*
@@ -622,4 +629,18 @@ interface ResourceAttributeValues
622629
*/
623630
public const TELEMETRY_SDK_LANGUAGE_WEBJS = 'webjs';
624631

632+
/**
633+
* [branch](https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddefbranchabranch)
634+
*
635+
* @see ResourceAttributes::VCS_REF_TYPE
636+
*/
637+
public const VCS_REF_TYPE_BRANCH = 'branch';
638+
639+
/**
640+
* [tag](https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddeftagatag)
641+
*
642+
* @see ResourceAttributes::VCS_REF_TYPE
643+
*/
644+
public const VCS_REF_TYPE_TAG = 'tag';
645+
625646
}

src/SemConv/ResourceAttributes.php

Lines changed: 117 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,36 @@ interface ResourceAttributes
132132
*/
133133
public const BROWSER_PLATFORM = 'browser.platform';
134134

135+
/**
136+
* The human readable name of the pipeline within a CI/CD system.
137+
*/
138+
public const CICD_PIPELINE_NAME = 'cicd.pipeline.name';
139+
140+
/**
141+
* The unique identifier of a pipeline run within a CI/CD system.
142+
*/
143+
public const CICD_PIPELINE_RUN_ID = 'cicd.pipeline.run.id';
144+
145+
/**
146+
* The [URL](https://wikipedia.org/wiki/URL) of the pipeline run, providing the complete address in order to locate and identify the pipeline run.
147+
*/
148+
public const CICD_PIPELINE_RUN_URL_FULL = 'cicd.pipeline.run.url.full';
149+
150+
/**
151+
* The unique identifier of a worker within a CICD system.
152+
*/
153+
public const CICD_WORKER_ID = 'cicd.worker.id';
154+
155+
/**
156+
* The name of a worker within a CICD system.
157+
*/
158+
public const CICD_WORKER_NAME = 'cicd.worker.name';
159+
160+
/**
161+
* The [URL](https://wikipedia.org/wiki/URL) of the worker, providing the complete address in order to locate and identify the worker.
162+
*/
163+
public const CICD_WORKER_URL_FULL = 'cicd.worker.url.full';
164+
135165
/**
136166
* The cloud account ID the resource is assigned to.
137167
*/
@@ -157,7 +187,7 @@ interface ResourceAttributes
157187
public const CLOUD_PROVIDER = 'cloud.provider';
158188

159189
/**
160-
* The geographical region the resource is running.
190+
* The geographical region within a cloud provider. When associated with a resource, this attribute specifies the region where the resource operates. When calling services or APIs deployed on a cloud, this attribute identifies the region where the called destination is deployed.
161191
*
162192
* Refer to your provider's docs to see the available regions, for example [Alibaba Cloud regions](https://www.alibabacloud.com/help/doc-detail/40654.htm), [AWS regions](https://aws.amazon.com/about-aws/global-infrastructure/regions_az/), [Azure regions](https://azure.microsoft.com/global-infrastructure/geographies/), [Google Cloud regions](https://cloud.google.com/about/locations), or [Tencent Cloud regions](https://www.tencentcloud.com/document/product/213/6091).
163193
*/
@@ -377,7 +407,7 @@ interface ResourceAttributes
377407
* > [!WARNING]> This attribute may contain sensitive (PII) information. Caution should be taken when storing personal data or anything which can identify a user. GDPR and data protection laws may apply,
378408
* > ensure you do your own due diligence.> Due to these reasons, this identifier is not recommended for consumer applications and will likely result in rejection from both Google Play and App Store.
379409
* > However, it may be appropriate for specific enterprise scenarios, such as kiosk devices or enterprise-managed devices, with appropriate compliance clearance.
380-
* > Any instrumentation providing this identifier MUST implement it as an opt-in feature.> See [`app.installation.id`](/docs/attributes-registry/app.md#app-installation-id)> for a more privacy-preserving alternative.
410+
* > Any instrumentation providing this identifier MUST implement it as an opt-in feature.> See [`app.installation.id`](/docs/registry/attributes/app.md#app-installation-id)> for a more privacy-preserving alternative.
381411
*/
382412
public const DEVICE_ID = 'device.id';
383413

@@ -782,6 +812,27 @@ interface ResourceAttributes
782812
*/
783813
public const K8S_HPA_NAME = 'k8s.hpa.name';
784814

815+
/**
816+
* The API version of the target resource to scale for the HorizontalPodAutoscaler.
817+
*
818+
* This maps to the `apiVersion` field in the `scaleTargetRef` of the HPA spec.
819+
*/
820+
public const K8S_HPA_SCALETARGETREF_API_VERSION = 'k8s.hpa.scaletargetref.api_version';
821+
822+
/**
823+
* The kind of the target resource to scale for the HorizontalPodAutoscaler.
824+
*
825+
* This maps to the `kind` field in the `scaleTargetRef` of the HPA spec.
826+
*/
827+
public const K8S_HPA_SCALETARGETREF_KIND = 'k8s.hpa.scaletargetref.kind';
828+
829+
/**
830+
* The name of the target resource to scale for the HorizontalPodAutoscaler.
831+
*
832+
* This maps to the `name` field in the `scaleTargetRef` of the HPA spec.
833+
*/
834+
public const K8S_HPA_SCALETARGETREF_NAME = 'k8s.hpa.scaletargetref.name';
835+
785836
/**
786837
* The UID of the horizontal pod autoscaler.
787838
*/
@@ -970,6 +1021,11 @@ interface ResourceAttributes
9701021
*/
9711022
public const K8S_STATEFULSET_UID = 'k8s.statefulset.uid';
9721023

1024+
/**
1025+
* Name of the logical partition that hosts a systems with a mainframe operating system.
1026+
*/
1027+
public const MAINFRAME_LPAR_NAME = 'mainframe.lpar.name';
1028+
9731029
/**
9741030
* The digest of the OCI image manifest. For container images specifically is the digest by which the container image is known.
9751031
*
@@ -1026,12 +1082,12 @@ interface ResourceAttributes
10261082
public const PROCESS_COMMAND = 'process.command';
10271083

10281084
/**
1029-
* All the command arguments (including the command/executable itself) as received by the process. On Linux-based systems (and some other Unixoid systems supporting procfs), can be set according to the list of null-delimited strings extracted from `proc/[pid]/cmdline`. For libc-based executables, this would be the full argv vector passed to `main`.
1085+
* All the command arguments (including the command/executable itself) as received by the process. On Linux-based systems (and some other Unixoid systems supporting procfs), can be set according to the list of null-delimited strings extracted from `proc/[pid]/cmdline`. For libc-based executables, this would be the full argv vector passed to `main`. SHOULD NOT be collected by default unless there is sanitization that excludes sensitive data.
10301086
*/
10311087
public const PROCESS_COMMAND_ARGS = 'process.command_args';
10321088

10331089
/**
1034-
* The full command used to launch the process as a single string representing the full command. On Windows, can be set to the result of `GetCommandLineW`. Do not set this if you have to assemble it just for monitoring; use `process.command_args` instead.
1090+
* The full command used to launch the process as a single string representing the full command. On Windows, can be set to the result of `GetCommandLineW`. Do not set this if you have to assemble it just for monitoring; use `process.command_args` instead. SHOULD NOT be collected by default unless there is sanitization that excludes sensitive data.
10351091
*/
10361092
public const PROCESS_COMMAND_LINE = 'process.command_line';
10371093

@@ -1173,6 +1229,53 @@ interface ResourceAttributes
11731229
*/
11741230
public const USER_AGENT_ORIGINAL = 'user_agent.original';
11751231

1232+
/**
1233+
* The name of the [reference](https://git-scm.com/docs/gitglossary#def_ref) such as **branch** or **tag** in the repository.
1234+
*
1235+
* `head` refers to where you are right now; the current reference at a
1236+
* given time.
1237+
*/
1238+
public const VCS_REF_HEAD_NAME = 'vcs.ref.head.name';
1239+
1240+
/**
1241+
* The revision, literally [revised version](https://www.merriam-webster.com/dictionary/revision), The revision most often refers to a commit object in Git, or a revision number in SVN.
1242+
*
1243+
* `head` refers to where you are right now; the current reference at a
1244+
* given time.The revision can be a full [hash value (see
1245+
* glossary)](https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-5.pdf),
1246+
* of the recorded change to a ref within a repository pointing to a
1247+
* commit [commit](https://git-scm.com/docs/git-commit) object. It does
1248+
* not necessarily have to be a hash; it can simply define a [revision
1249+
* number](https://svnbook.red-bean.com/en/1.7/svn.tour.revs.specifiers.html)
1250+
* which is an integer that is monotonically increasing. In cases where
1251+
* it is identical to the `ref.head.name`, it SHOULD still be included.
1252+
* It is up to the implementer to decide which value to set as the
1253+
* revision based on the VCS system and situational context.
1254+
*/
1255+
public const VCS_REF_HEAD_REVISION = 'vcs.ref.head.revision';
1256+
1257+
/**
1258+
* The type of the [reference](https://git-scm.com/docs/gitglossary#def_ref) in the repository.
1259+
*/
1260+
public const VCS_REF_TYPE = 'vcs.ref.type';
1261+
1262+
/**
1263+
* The human readable name of the repository. It SHOULD NOT include any additional identifier like Group/SubGroup in GitLab or organization in GitHub.
1264+
*
1265+
* Due to it only being the name, it can clash with forks of the same
1266+
* repository if collecting telemetry across multiple orgs or groups in
1267+
* the same backends.
1268+
*/
1269+
public const VCS_REPOSITORY_NAME = 'vcs.repository.name';
1270+
1271+
/**
1272+
* The [canonical URL](https://support.google.com/webmasters/answer/10347851?hl=en#:~:text=A%20canonical%20URL%20is%20the,Google%20chooses%20one%20as%20canonical.) of the repository providing the complete HTTP(S) address in order to locate and identify the repository through a browser.
1273+
*
1274+
* In Git Version Control Systems, the canonical URL SHOULD NOT include
1275+
* the `.git` extension.
1276+
*/
1277+
public const VCS_REPOSITORY_URL_FULL = 'vcs.repository.url.full';
1278+
11761279
/**
11771280
* Additional description of the web engine (e.g. detailed version and edition information).
11781281
*/
@@ -1188,4 +1291,14 @@ interface ResourceAttributes
11881291
*/
11891292
public const WEBENGINE_VERSION = 'webengine.version';
11901293

1294+
/**
1295+
* The System Management Facility (SMF) Identifier uniquely identified a z/OS system within a SYSPLEX or mainframe environment and is used for system and performance analysis.
1296+
*/
1297+
public const ZOS_SMF_ID = 'zos.smf.id';
1298+
1299+
/**
1300+
* The name of the SYSPLEX to which the z/OS system belongs too.
1301+
*/
1302+
public const ZOS_SYSPLEX_NAME = 'zos.sysplex.name';
1303+
11911304
}

0 commit comments

Comments
 (0)