2019-12-12 01:27:03 +00:00
|
|
|
load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
|
2019-08-30 18:33:25 +00:00
|
|
|
|
|
|
|
go_library(
|
|
|
|
name = "go_default_library",
|
|
|
|
srcs = [
|
2019-12-12 01:27:03 +00:00
|
|
|
"collector.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"counter.go",
|
2019-12-12 01:27:03 +00:00
|
|
|
"desc.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"gauge.go",
|
|
|
|
"histogram.go",
|
2019-12-12 01:27:03 +00:00
|
|
|
"http.go",
|
|
|
|
"labels.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"metric.go",
|
2020-08-10 17:43:49 +00:00
|
|
|
"options.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"opts.go",
|
|
|
|
"processstarttime.go",
|
|
|
|
"registry.go",
|
|
|
|
"summary.go",
|
2019-12-12 01:27:03 +00:00
|
|
|
"value.go",
|
2019-09-27 21:51:53 +00:00
|
|
|
"version.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"version_parser.go",
|
|
|
|
"wrappers.go",
|
|
|
|
],
|
|
|
|
importmap = "k8s.io/kubernetes/vendor/k8s.io/component-base/metrics",
|
|
|
|
importpath = "k8s.io/component-base/metrics",
|
2019-12-12 01:27:03 +00:00
|
|
|
visibility = ["//visibility:public"],
|
2019-08-30 18:33:25 +00:00
|
|
|
deps = [
|
|
|
|
"//staging/src/k8s.io/apimachinery/pkg/version:go_default_library",
|
2019-09-27 21:51:53 +00:00
|
|
|
"//staging/src/k8s.io/component-base/version:go_default_library",
|
2019-08-30 18:33:25 +00:00
|
|
|
"//vendor/github.com/blang/semver:go_default_library",
|
|
|
|
"//vendor/github.com/prometheus/client_golang/prometheus:go_default_library",
|
2019-12-12 01:27:03 +00:00
|
|
|
"//vendor/github.com/prometheus/client_golang/prometheus/promhttp:go_default_library",
|
2019-08-30 18:33:25 +00:00
|
|
|
"//vendor/github.com/prometheus/client_model/go:go_default_library",
|
|
|
|
"//vendor/github.com/prometheus/procfs:go_default_library",
|
2020-08-10 17:43:49 +00:00
|
|
|
"//vendor/github.com/spf13/pflag:go_default_library",
|
|
|
|
"//vendor/k8s.io/klog/v2:go_default_library",
|
2019-08-30 18:33:25 +00:00
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
go_test(
|
|
|
|
name = "go_default_test",
|
|
|
|
srcs = [
|
2019-12-12 01:27:03 +00:00
|
|
|
"collector_test.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"counter_test.go",
|
2020-03-26 21:07:15 +00:00
|
|
|
"desc_test.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"gauge_test.go",
|
|
|
|
"histogram_test.go",
|
2020-08-10 17:43:49 +00:00
|
|
|
"http_test.go",
|
2019-12-12 01:27:03 +00:00
|
|
|
"opts_test.go",
|
2019-08-30 18:33:25 +00:00
|
|
|
"registry_test.go",
|
|
|
|
"summary_test.go",
|
|
|
|
"version_parser_test.go",
|
|
|
|
],
|
|
|
|
embed = [":go_default_library"],
|
|
|
|
deps = [
|
|
|
|
"//staging/src/k8s.io/apimachinery/pkg/version:go_default_library",
|
|
|
|
"//vendor/github.com/blang/semver:go_default_library",
|
|
|
|
"//vendor/github.com/prometheus/client_golang/prometheus:go_default_library",
|
2019-12-12 01:27:03 +00:00
|
|
|
"//vendor/github.com/prometheus/client_golang/prometheus/testutil:go_default_library",
|
2019-08-30 18:33:25 +00:00
|
|
|
"//vendor/github.com/prometheus/common/expfmt:go_default_library",
|
|
|
|
"//vendor/github.com/stretchr/testify/assert:go_default_library",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
filegroup(
|
|
|
|
name = "package-srcs",
|
|
|
|
srcs = glob(["**"]),
|
|
|
|
tags = ["automanaged"],
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
|
|
|
filegroup(
|
|
|
|
name = "all-srcs",
|
|
|
|
srcs = [
|
|
|
|
":package-srcs",
|
|
|
|
"//staging/src/k8s.io/component-base/metrics/legacyregistry:all-srcs",
|
2019-09-27 21:51:53 +00:00
|
|
|
"//staging/src/k8s.io/component-base/metrics/prometheus/clientgo:all-srcs",
|
2019-12-12 01:27:03 +00:00
|
|
|
"//staging/src/k8s.io/component-base/metrics/prometheus/ratelimiter:all-srcs",
|
2019-09-27 21:51:53 +00:00
|
|
|
"//staging/src/k8s.io/component-base/metrics/prometheus/restclient:all-srcs",
|
2019-12-12 01:27:03 +00:00
|
|
|
"//staging/src/k8s.io/component-base/metrics/prometheus/version:all-srcs",
|
2019-09-27 21:51:53 +00:00
|
|
|
"//staging/src/k8s.io/component-base/metrics/prometheus/workqueue:all-srcs",
|
2019-12-12 01:27:03 +00:00
|
|
|
"//staging/src/k8s.io/component-base/metrics/testutil:all-srcs",
|
2019-08-30 18:33:25 +00:00
|
|
|
],
|
|
|
|
tags = ["automanaged"],
|
2019-12-12 01:27:03 +00:00
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
)
|
|
|
|
|
|
|
|
# Packages allowed to import github.com/prometheus
|
|
|
|
package_group(
|
|
|
|
name = "prometheus_import_allow_list",
|
|
|
|
packages = [
|
|
|
|
"//cluster/images/etcd-version-monitor",
|
|
|
|
"//pkg/scheduler/framework/v1alpha1",
|
|
|
|
"//pkg/volume/util/operationexecutor",
|
|
|
|
"//staging/src/k8s.io/apiserver/pkg/util/flowcontrol/metrics",
|
|
|
|
"//staging/src/k8s.io/component-base/metrics/...",
|
|
|
|
"//test/e2e_node",
|
2020-08-10 17:43:49 +00:00
|
|
|
"//test/integration/apiserver/flowcontrol",
|
2019-12-12 01:27:03 +00:00
|
|
|
"//vendor/...",
|
|
|
|
],
|
2019-08-30 18:33:25 +00:00
|
|
|
)
|