• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2021 The gRPC Authors
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7#     http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14load("@rules_python//python:defs.bzl", "py_library")
15load("//bazel:python_rules.bzl", "py_grpc_library", "py_proto_library")
16
17package(default_visibility = ["//visibility:public"])
18
19py_proto_library(
20    name = "health_py_pb2",
21    imports = ["../../"],
22    deps = ["//src/proto/grpc/health/v1:health_proto"],
23)
24
25py_grpc_library(
26    name = "health_py_pb2_grpc",
27    srcs = ["//src/proto/grpc/health/v1:health_proto"],
28    strip_prefixes = ["src.python.grpcio_health_checking."],
29    deps = [":health_py_pb2"],
30)
31
32py_library(
33    name = "grpc_health",
34    srcs = [
35        "_async.py",
36        "health.py",
37    ],
38    imports = ["../../"],
39    deps = [
40        ":health_py_pb2",
41        ":health_py_pb2_grpc",
42        "//src/python/grpcio/grpc:grpcio",
43    ],
44)
45