Skip to content

Commit

Permalink
add has_services to proto_library rules
Browse files Browse the repository at this point in the history
  • Loading branch information
markdroth committed Oct 18, 2024
1 parent 7d67017 commit 0aa2ff3
Show file tree
Hide file tree
Showing 11 changed files with 24 additions and 1 deletion.
3 changes: 2 additions & 1 deletion bazel/grpc_build_system.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,8 @@ def grpc_proto_plugin(name, srcs = [], deps = []):
deps = deps,
)

def grpc_internal_proto_library(name, srcs = [], deps = [], visibility = None):
def grpc_internal_proto_library(name, srcs = [], deps = [], visibility = None,
**kwds):
proto_library(
name = name,
srcs = srcs,
Expand Down
1 change: 1 addition & 0 deletions src/proto/grpc/channelz/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ grpc_package(
grpc_internal_proto_library(
name = "channelz_proto",
srcs = ["channelz.proto"],
has_services = True,
deps = [
"@com_google_protobuf//:any_proto",
"@com_google_protobuf//:duration_proto",
Expand Down
1 change: 1 addition & 0 deletions src/proto/grpc/health/v1/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ grpc_package(
grpc_internal_proto_library(
name = "health_proto",
srcs = ["health.proto"],
has_services = True,
)

grpc_cc_proto_library(
Expand Down
2 changes: 2 additions & 0 deletions src/proto/grpc/lb/v1/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ grpc_package(
grpc_internal_proto_library(
name = "load_balancer_proto",
srcs = ["load_balancer.proto"],
has_services = True,
deps = [
"@com_google_protobuf//:duration_proto",
"@com_google_protobuf//:timestamp_proto",
Expand All @@ -44,6 +45,7 @@ grpc_cc_grpc_library(
grpc_internal_proto_library(
name = "load_reporter_proto",
srcs = ["load_reporter.proto"],
has_services = True,
deps = [
"@com_google_protobuf//:duration_proto",
],
Expand Down
1 change: 1 addition & 0 deletions src/proto/grpc/lookup/v1/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ grpc_package(
grpc_internal_proto_library(
name = "rls_proto",
srcs = ["rls.proto"],
has_services = True,
)

grpc_cc_proto_library(
Expand Down
1 change: 1 addition & 0 deletions src/proto/grpc/reflection/v1/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ grpc_package(
grpc_internal_proto_library(
name = "reflection_proto",
srcs = ["reflection.proto"],
has_services = True,
)

grpc_cc_proto_library(
Expand Down
1 change: 1 addition & 0 deletions src/proto/grpc/reflection/v1alpha/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ grpc_package(
grpc_internal_proto_library(
name = "reflection_proto",
srcs = ["reflection.proto"],
has_services = True,
)

grpc_cc_proto_library(
Expand Down
8 changes: 8 additions & 0 deletions src/proto/grpc/testing/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ exports_files([
grpc_internal_proto_library(
name = "compiler_test_proto",
srcs = ["compiler_test.proto"],
has_services = True,
)

grpc_cc_proto_library(
Expand Down Expand Up @@ -91,6 +92,7 @@ grpc_cc_proto_library(
grpc_internal_proto_library(
name = "echo_proto",
srcs = ["echo.proto"],
has_services = True,
deps = [
"echo_messages_proto",
"simple_messages_proto",
Expand Down Expand Up @@ -158,6 +160,7 @@ py_grpc_library(
grpc_internal_proto_library(
name = "metrics_proto",
srcs = ["metrics.proto"],
has_services = True,
)

grpc_cc_proto_library(
Expand Down Expand Up @@ -189,6 +192,7 @@ py_proto_library(
grpc_internal_proto_library(
name = "benchmark_service_proto",
srcs = ["benchmark_service.proto"],
has_services = True,
deps = [
"messages_proto",
],
Expand Down Expand Up @@ -222,6 +226,7 @@ py_grpc_library(
grpc_internal_proto_library(
name = "report_qps_scenario_service_proto",
srcs = ["report_qps_scenario_service.proto"],
has_services = True,
deps = [
"control_proto",
],
Expand All @@ -244,6 +249,7 @@ grpc_cc_grpc_library(
grpc_internal_proto_library(
name = "worker_service_proto",
srcs = ["worker_service.proto"],
has_services = True,
deps = [
"control_proto",
],
Expand Down Expand Up @@ -302,6 +308,7 @@ py_proto_library(
grpc_internal_proto_library(
name = "test_proto",
srcs = ["test.proto"],
has_services = True,
deps = [
"empty_proto",
"messages_proto",
Expand Down Expand Up @@ -333,6 +340,7 @@ py_grpc_library(
grpc_internal_proto_library(
name = "istio_echo_proto",
srcs = ["istio_echo.proto"],
has_services = True,
deps = [
"@com_google_protobuf//:wrappers_proto",
],
Expand Down
1 change: 1 addition & 0 deletions src/proto/grpc/testing/duplicate/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ grpc_package(
grpc_internal_proto_library(
name = "echo_duplicate_proto",
srcs = ["echo_duplicate.proto"],
has_services = True,
deps = ["//src/proto/grpc/testing:echo_messages_proto"],
)

Expand Down
5 changes: 5 additions & 0 deletions src/proto/grpc/testing/xds/v3/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ grpc_cc_proto_library(
grpc_internal_proto_library(
name = "discovery_proto",
srcs = ["discovery.proto"],
has_services = True,
deps = [
"base_proto",
"@com_google_protobuf//:any_proto",
Expand All @@ -82,6 +83,7 @@ grpc_cc_proto_library(
grpc_internal_proto_library(
name = "ads_proto",
srcs = ["ads.proto"],
has_services = True,
deps = [
"discovery_proto",
],
Expand Down Expand Up @@ -216,6 +218,7 @@ grpc_cc_proto_library(
grpc_internal_proto_library(
name = "lrs_proto",
srcs = ["lrs.proto"],
has_services = True,
deps = [
"base_proto",
"load_report_proto",
Expand Down Expand Up @@ -247,6 +250,7 @@ grpc_cc_proto_library(
grpc_internal_proto_library(
name = "orca_service_proto",
srcs = ["orca_service.proto"],
has_services = True,
deps = [
"orca_load_report_proto",
"@com_google_protobuf//:duration_proto",
Expand Down Expand Up @@ -458,6 +462,7 @@ grpc_cc_proto_library(
grpc_internal_proto_library(
name = "csds_proto",
srcs = ["csds.proto"],
has_services = True,
deps = [
"base_proto",
"config_dump_proto",
Expand Down
1 change: 1 addition & 0 deletions test/core/tsi/alts/fake_handshaker/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ grpc_cc_proto_library(
grpc_internal_proto_library(
name = "handshaker_proto",
srcs = ["handshaker.proto"],
has_services = True,
deps = [
"transport_security_common_proto",
],
Expand Down

0 comments on commit 0aa2ff3

Please sign in to comment.