Skip to content

Commit

Permalink
Add opentelemetry-proto 1.5.0 (#3445)
Browse files Browse the repository at this point in the history
  • Loading branch information
keith authored Dec 18, 2024
1 parent 4e716ec commit 2846e40
Show file tree
Hide file tree
Showing 5 changed files with 338 additions and 1 deletion.
11 changes: 11 additions & 0 deletions modules/opentelemetry-proto/1.5.0/MODULE.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
module(
name = "opentelemetry-proto",
version = "1.5.0",
compatibility_level = 0,
)

bazel_dep(name = "grpc", version = "1.66.0.bcr.2", repo_name = "com_github_grpc_grpc")
bazel_dep(name = "protobuf", version = "29.0", repo_name = "com_google_protobuf")
bazel_dep(name = "rules_go", version = "0.50.1", repo_name = "io_bazel_rules_go")
bazel_dep(name = "rules_proto", version = "6.0.0")
bazel_dep(name = "rules_python", version = "0.40.0")
304 changes: 304 additions & 0 deletions modules/opentelemetry-proto/1.5.0/patches/module_dot_bazel.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,304 @@
diff --git a/BUILD.bazel b/BUILD.bazel
new file mode 100644
index 0000000..5b70734
--- /dev/null
+++ b/BUILD.bazel
@@ -0,0 +1,281 @@
+load("@com_github_grpc_grpc//bazel:cc_grpc_library.bzl", "cc_grpc_library")
+load("@com_github_grpc_grpc//bazel:python_rules.bzl", "py_proto_library", "py_grpc_library")
+load("@com_google_protobuf//bazel:cc_proto_library.bzl", "cc_proto_library")
+load("@io_bazel_rules_go//proto:def.bzl", "go_proto_library", "go_grpc_library")
+load("@rules_proto//proto:defs.bzl", "proto_library")
+
+package(default_visibility = ["//visibility:public"])
+
+proto_library(
+ name = "common_proto",
+ srcs = [
+ "opentelemetry/proto/common/v1/common.proto",
+ ],
+)
+
+cc_proto_library(
+ name = "common_proto_cc",
+ deps = [":common_proto"],
+)
+
+py_proto_library(
+ name = "common_proto_py",
+ deps = [":common_proto"],
+)
+
+go_proto_library(
+ name = "common_proto_go",
+ importpath = "go.opentelemetry.io/proto/otlp/common/v1",
+ protos = [":common_proto"],
+)
+
+proto_library(
+ name = "logs_proto",
+ srcs = [
+ "opentelemetry/proto/logs/v1/logs.proto",
+ ],
+ deps = [
+ ":common_proto",
+ ":resource_proto",
+ ],
+)
+
+cc_proto_library(
+ name = "logs_proto_cc",
+ deps = [":logs_proto"],
+)
+
+py_proto_library(
+ name = "logs_proto_py",
+ deps = [":logs_proto"],
+)
+
+go_proto_library(
+ name = "logs_proto_go",
+ importpath = "go.opentelemetry.io/proto/otlp/logs/v1",
+ protos = [":logs_proto"],
+ deps = [
+ ":common_proto_go",
+ ":resource_proto_go",
+ ],
+)
+
+proto_library(
+ name = "logs_service_proto",
+ srcs = [
+ "opentelemetry/proto/collector/logs/v1/logs_service.proto",
+ ],
+ deps = [
+ ":logs_proto",
+ ],
+)
+
+cc_proto_library(
+ name = "logs_service_proto_cc",
+ deps = [":logs_service_proto"],
+)
+
+cc_grpc_library(
+ name = "logs_service_grpc_cc",
+ srcs = [":logs_service_proto"],
+ generate_mocks = True,
+ grpc_only = True,
+ deps = [":logs_service_proto_cc"],
+)
+
+py_proto_library(
+ name = "logs_service_proto_py",
+ deps = [":logs_service_proto"],
+)
+
+py_grpc_library(
+ name = "logs_service_grpc_py",
+ srcs = [":logs_service_proto"],
+ deps = [":logs_service_proto_py"],
+)
+
+go_grpc_library(
+ name = "logs_service_grpc_go",
+ protos = [":logs_service_proto"],
+ importpath = "go.opentelemetry.io/proto/otlp/logs/v1",
+ embed = [
+ ":logs_proto_go",
+ ],
+)
+
+proto_library(
+ name = "metrics_proto",
+ srcs = [
+ "opentelemetry/proto/metrics/v1/metrics.proto",
+ ],
+ deps = [
+ ":common_proto",
+ ":resource_proto",
+ ],
+)
+
+cc_proto_library(
+ name = "metrics_proto_cc",
+ deps = [":metrics_proto"],
+)
+
+py_proto_library(
+ name = "metrics_proto_py",
+ deps = [":metrics_proto"],
+)
+
+go_proto_library(
+ name = "metrics_proto_go",
+ importpath = "go.opentelemetry.io/proto/otlp/metrics/v1",
+ protos = [":metrics_proto"],
+ deps = [
+ ":common_proto_go",
+ ":resource_proto_go",
+ ],
+)
+
+proto_library(
+ name = "metrics_service_proto",
+ srcs = [
+ "opentelemetry/proto/collector/metrics/v1/metrics_service.proto",
+ ],
+ deps = [
+ ":metrics_proto",
+ ],
+)
+
+cc_proto_library(
+ name = "metrics_service_proto_cc",
+ deps = [":metrics_service_proto"],
+)
+
+cc_grpc_library(
+ name = "metrics_service_grpc_cc",
+ srcs = [":metrics_service_proto"],
+ generate_mocks = True,
+ grpc_only = True,
+ deps = [":metrics_service_proto_cc"],
+)
+
+py_proto_library(
+ name = "metrics_service_proto_py",
+ deps = [":metrics_service_proto"],
+)
+
+py_grpc_library(
+ name = "metrics_service_grpc_py",
+ srcs = [":metrics_service_proto"],
+ deps = [":metrics_service_proto_py"],
+)
+
+go_grpc_library(
+ name = "metrics_service_grpc_go",
+ protos = [":metrics_service_proto"],
+ importpath = "go.opentelemetry.io/proto/otlp/metrics/v1",
+ embed = [
+ ":metrics_proto_go",
+ ],
+)
+
+proto_library(
+ name = "resource_proto",
+ srcs = [
+ "opentelemetry/proto/resource/v1/resource.proto",
+ ],
+ deps = [
+ ":common_proto",
+ ],
+)
+
+cc_proto_library(
+ name = "resource_proto_cc",
+ deps = [":resource_proto"],
+)
+
+py_proto_library(
+ name = "resource_proto_py",
+ deps = [":resource_proto"],
+)
+
+go_proto_library(
+ name = "resource_proto_go",
+ importpath = "go.opentelemetry.io/proto/otlp/resource/v1",
+ protos = [":resource_proto"],
+ deps = [
+ ":common_proto_go",
+ ],
+)
+
+proto_library(
+ name = "trace_proto",
+ srcs = [
+ "opentelemetry/proto/trace/v1/trace.proto",
+ ],
+ deps = [
+ ":common_proto",
+ ":resource_proto",
+ ],
+)
+
+cc_proto_library(
+ name = "trace_proto_cc",
+ deps = [":trace_proto"],
+)
+
+py_proto_library(
+ name = "trace_proto_py",
+ deps = [":trace_proto"],
+)
+
+go_proto_library(
+ name = "trace_proto_go",
+ importpath = "go.opentelemetry.io/proto/otlp/trace/v1",
+ protos = [":trace_proto"],
+ deps = [
+ ":common_proto_go",
+ ":resource_proto_go",
+ ],
+)
+
+proto_library(
+ name = "trace_service_proto",
+ srcs = [
+ "opentelemetry/proto/collector/trace/v1/trace_service.proto",
+ ],
+ deps = [
+ ":trace_proto",
+ ],
+)
+
+cc_proto_library(
+ name = "trace_service_proto_cc",
+ deps = [":trace_service_proto"],
+)
+
+cc_grpc_library(
+ name = "trace_service_grpc_cc",
+ srcs = [":trace_service_proto"],
+ generate_mocks = True,
+ grpc_only = True,
+ deps = [":trace_service_proto_cc"],
+)
+
+py_proto_library(
+ name = "trace_service_proto_py",
+ deps = [":trace_service_proto"],
+)
+
+py_grpc_library(
+ name = "trace_service_grpc_py",
+ srcs = [":trace_service_proto"],
+ deps = [":trace_service_proto_py"],
+)
+
+go_grpc_library(
+ name = "trace_service_grpc_go",
+ protos = [":trace_service_proto"],
+ importpath = "go.opentelemetry.io/proto/otlp/trace/v1",
+ embed = [
+ ":trace_proto_go",
+ ],
+)
diff --git a/MODULE.bazel b/MODULE.bazel
new file mode 100644
index 0000000..ea4966f
--- /dev/null
+++ b/MODULE.bazel
@@ -0,0 +1,11 @@
+module(
+ name = "opentelemetry-proto",
+ version = "1.5.0",
+ compatibility_level = 0,
+)
+
+bazel_dep(name = "grpc", version = "1.66.0.bcr.2", repo_name = "com_github_grpc_grpc")
+bazel_dep(name = "protobuf", version = "29.0", repo_name = "com_google_protobuf")
+bazel_dep(name = "rules_go", version = "0.50.1", repo_name = "io_bazel_rules_go")
+bazel_dep(name = "rules_proto", version = "6.0.0")
+bazel_dep(name = "rules_python", version = "0.40.0")
12 changes: 12 additions & 0 deletions modules/opentelemetry-proto/1.5.0/presubmit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
matrix:
platform: ["debian10", "macos", "ubuntu2004"]
bazel: ["7.x", "8.x"]
tasks:
verify_targets:
platform: ${{ platform }}
bazel: ${{ bazel }}
build_flags:
- '--cxxopt=-std=c++14'
- '--host_cxxopt=-std=c++14'
build_targets:
- '@opentelemetry-proto//...'
9 changes: 9 additions & 0 deletions modules/opentelemetry-proto/1.5.0/source.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"integrity": "sha256-CPQGNq28XzPSCEvY57ZOSR3QI50alQIdv/vfHKjOpFQ=",
"strip_prefix": "opentelemetry-proto-1.5.0",
"url": "https://github.com/open-telemetry/opentelemetry-proto/archive/refs/tags/v1.5.0.tar.gz",
"patch_strip": 1,
"patches": {
"module_dot_bazel.patch": "sha256-Da3iBHna6VObwI3t4t8WjCU+22JEq56hFy4TZFJH3aA="
}
}
3 changes: 2 additions & 1 deletion modules/opentelemetry-proto/metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
"1.3.1",
"1.3.2",
"1.4.0",
"1.4.0.bcr.1"
"1.4.0.bcr.1",
"1.5.0"
],
"yanked_versions": {}
}

0 comments on commit 2846e40

Please sign in to comment.