From 3e6928dda855d46b3bbc0fe7a17c36f4996e628b Mon Sep 17 00:00:00 2001 From: Przemyslaw Delewski <102958445+pdelewski@users.noreply.github.com> Date: Tue, 13 Dec 2022 20:07:07 +0100 Subject: [PATCH] Add instrgen directory for source level instrumentation (#3068) * Add instrgen directory for source level instrumentation Co-authored-by: Tyler Yahn --- CHANGELOG.md | 4 ++++ CODEOWNERS | 2 ++ instrgen/README.md | 13 +++++++++++++ instrgen/doc.go | 19 +++++++++++++++++++ instrgen/go.mod | 3 +++ 5 files changed, 41 insertions(+) create mode 100644 instrgen/README.md create mode 100644 instrgen/doc.go create mode 100644 instrgen/go.mod diff --git a/CHANGELOG.md b/CHANGELOG.md index b6410dd1f75..2d6f0c3ddd5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,10 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm ## [Unreleased] +### Added + +- Add the new `go.opentelemetry.io/contrib/instrgen` package to provide auto-generated source code instrumentation. (#3068) + ## [1.12.0/0.37.0/0.6.0] ### Added diff --git a/CODEOWNERS b/CODEOWNERS index c4012ed6ca1..6dc853d0f5b 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -15,3 +15,5 @@ * @jmacd @MrAlias @Aneurysm9 @evantorrie @XSAM @dashpole @MadVikingGod @pellared @hanyuancheung @dmathieu CODEOWNERS @MrAlias @Aneurysm9 @MadVikingGod + +instrgen/ @open-telemetry/go-approvers @MrAlias @pdelewski \ No newline at end of file diff --git a/instrgen/README.md b/instrgen/README.md new file mode 100644 index 00000000000..c60f0d25ed8 --- /dev/null +++ b/instrgen/README.md @@ -0,0 +1,13 @@ +# OpenTelemetry Go Source Automatic Instrumentation + +This package provides a code generation utility that instruments existing source code with [OpenTelemetry]. + +## Project Status + +:construction: This package is currently work in progress. + +### Compatibility + +The `instrgen` utility is based on the Go standard library and is platform agnostic. + +[OpenTelemetry]: https://opentelemetry.io/ diff --git a/instrgen/doc.go b/instrgen/doc.go new file mode 100644 index 00000000000..fe48ff78a54 --- /dev/null +++ b/instrgen/doc.go @@ -0,0 +1,19 @@ +// Copyright The OpenTelemetry Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/* +Package instrgen provides a code generation utility that instruments existing +source code with OpenTelemetry. +*/ +package instrgen // import "go.opentelemetry.io/contrib/instrgen" diff --git a/instrgen/go.mod b/instrgen/go.mod new file mode 100644 index 00000000000..2b60f5633da --- /dev/null +++ b/instrgen/go.mod @@ -0,0 +1,3 @@ +module go.opentelemetry.io/contrib/instrgen + +go 1.18