diff --git a/app/kumactl/cmd/completion/testdata/bash.golden b/app/kumactl/cmd/completion/testdata/bash.golden index 37eb491c8555..7625ccbdb286 100644 --- a/app/kumactl/cmd/completion/testdata/bash.golden +++ b/app/kumactl/cmd/completion/testdata/bash.golden @@ -3789,10 +3789,6 @@ _kumactl_install_logging() flags_with_completion=() flags_completion=() - flags+=("--namespace=") - two_word_flags+=("--namespace") - local_nonpersistent_flags+=("--namespace") - local_nonpersistent_flags+=("--namespace=") flags+=("--api-timeout=") two_word_flags+=("--api-timeout") flags+=("--config-file=") @@ -3820,6 +3816,37 @@ _kumactl_install_metrics() flags_with_completion=() flags_completion=() + flags+=("--api-timeout=") + two_word_flags+=("--api-timeout") + flags+=("--config-file=") + two_word_flags+=("--config-file") + flags+=("--log-level=") + two_word_flags+=("--log-level") + flags+=("--no-config") + + must_have_one_flag=() + must_have_one_noun=() + noun_aliases=() +} + +_kumactl_install_observability() +{ + last_command="kumactl_install_observability" + + command_aliases=() + + commands=() + + flags=() + two_word_flags=() + local_nonpersistent_flags=() + flags_with_completion=() + flags_completion=() + + flags+=("--components=") + two_word_flags+=("--components") + local_nonpersistent_flags+=("--components") + local_nonpersistent_flags+=("--components=") flags+=("--jaeger-address=") two_word_flags+=("--jaeger-address") local_nonpersistent_flags+=("--jaeger-address") @@ -3839,10 +3866,10 @@ _kumactl_install_metrics() two_word_flags+=("--namespace") local_nonpersistent_flags+=("--namespace") local_nonpersistent_flags+=("--namespace=") - flags+=("--without-grafana") - local_nonpersistent_flags+=("--without-grafana") - flags+=("--without-prometheus") - local_nonpersistent_flags+=("--without-prometheus") + flags+=("--prometheus-address=") + two_word_flags+=("--prometheus-address") + local_nonpersistent_flags+=("--prometheus-address") + local_nonpersistent_flags+=("--prometheus-address=") flags+=("--api-timeout=") two_word_flags+=("--api-timeout") flags+=("--config-file=") @@ -3870,10 +3897,6 @@ _kumactl_install_tracing() flags_with_completion=() flags_completion=() - flags+=("--namespace=") - two_word_flags+=("--namespace") - local_nonpersistent_flags+=("--namespace") - local_nonpersistent_flags+=("--namespace=") flags+=("--api-timeout=") two_word_flags+=("--api-timeout") flags+=("--config-file=") @@ -3985,6 +4008,7 @@ _kumactl_install() commands+=("gateway") commands+=("logging") commands+=("metrics") + commands+=("observability") commands+=("tracing") commands+=("transparent-proxy") diff --git a/app/kumactl/cmd/install/context/install_logging_context.go b/app/kumactl/cmd/install/context/install_logging_context.go deleted file mode 100644 index d607e4c22db5..000000000000 --- a/app/kumactl/cmd/install/context/install_logging_context.go +++ /dev/null @@ -1,17 +0,0 @@ -package context - -type LoggingTemplateArgs struct { - Namespace string -} - -type InstallLoggingContext struct { - TemplateArgs LoggingTemplateArgs -} - -func DefaultInstallLoggingContext() InstallLoggingContext { - return InstallLoggingContext{ - TemplateArgs: LoggingTemplateArgs{ - Namespace: "kuma-logging", - }, - } -} diff --git a/app/kumactl/cmd/install/context/install_metrics_context.go b/app/kumactl/cmd/install/context/install_metrics_context.go deleted file mode 100644 index 6d69efb358b9..000000000000 --- a/app/kumactl/cmd/install/context/install_metrics_context.go +++ /dev/null @@ -1,36 +0,0 @@ -package context - -type Dashboard struct { - FileName string - Content string -} - -type MetricsTemplateArgs struct { - Namespace string - Mesh string - KumaCpAddress string - JaegerAddress string - LokiAddress string - KumaCpApiAddress string - WithoutPrometheus bool - WithoutGrafana bool - Dashboards []Dashboard -} - -type InstallMetricsContext struct { - TemplateArgs MetricsTemplateArgs -} - -func DefaultInstallMetricsContext() InstallMetricsContext { - return InstallMetricsContext{ - TemplateArgs: MetricsTemplateArgs{ - Namespace: "kuma-metrics", - KumaCpAddress: "http://kuma-control-plane.kuma-system:5676", - KumaCpApiAddress: "http://kuma-control-plane.kuma-system:5681", - JaegerAddress: "http://jaeger-query.kuma-tracing", - LokiAddress: "http://loki.kuma-logging:3100", - WithoutPrometheus: false, - WithoutGrafana: false, - }, - } -} diff --git a/app/kumactl/cmd/install/context/install_observability_context.go b/app/kumactl/cmd/install/context/install_observability_context.go new file mode 100644 index 000000000000..2aed1bd08684 --- /dev/null +++ b/app/kumactl/cmd/install/context/install_observability_context.go @@ -0,0 +1,37 @@ +package context + +type Dashboard struct { + FileName string + Content string +} + +type ObservabilityTemplateArgs struct { + Namespace string + Mesh string + KumaCpAddress string + JaegerAddress string + LokiAddress string + PrometheusAddress string + KumaCpApiAddress string + Components []string + ComponentsMap map[string]bool + Dashboards []Dashboard +} + +type InstallObservabilityContext struct { + TemplateArgs ObservabilityTemplateArgs +} + +func DefaultInstallObservabilityContext() InstallObservabilityContext { + return InstallObservabilityContext{ + TemplateArgs: ObservabilityTemplateArgs{ + Namespace: "mesh-observability", + KumaCpAddress: "http://kuma-control-plane.kuma-system:5676", + KumaCpApiAddress: "http://kuma-control-plane.kuma-system:5681", + JaegerAddress: "http://jaeger-query.mesh-observability", + LokiAddress: "http://loki.mesh-observability:3100", + PrometheusAddress: "http://prometheus-server.mesh-observability", + Components: []string{"grafana", "prometheus", "loki", "jaeger"}, + }, + } +} diff --git a/app/kumactl/cmd/install/context/install_tracing_context.go b/app/kumactl/cmd/install/context/install_tracing_context.go deleted file mode 100644 index 3abfeaef7e7f..000000000000 --- a/app/kumactl/cmd/install/context/install_tracing_context.go +++ /dev/null @@ -1,17 +0,0 @@ -package context - -type TracingTemplateArgs struct { - Namespace string -} - -type InstallTracingContext struct { - TemplateArgs TracingTemplateArgs -} - -func DefaultInstallTracingContext() InstallTracingContext { - return InstallTracingContext{ - TemplateArgs: TracingTemplateArgs{ - Namespace: "kuma-tracing", - }, - } -} diff --git a/app/kumactl/cmd/install/install.go b/app/kumactl/cmd/install/install.go index 64e85d6f36e2..0069604a22cf 100644 --- a/app/kumactl/cmd/install/install.go +++ b/app/kumactl/cmd/install/install.go @@ -16,9 +16,10 @@ func NewInstallCmd(pctx *kumactl_cmd.RootContext) *cobra.Command { // sub-commands cmd.AddCommand(newInstallControlPlaneCmd(&pctx.InstallCpContext)) cmd.AddCommand(newInstallCrdsCmd(&pctx.InstallCRDContext)) - cmd.AddCommand(newInstallMetrics(pctx)) - cmd.AddCommand(newInstallTracing(pctx)) - cmd.AddCommand(newInstallLogging(pctx)) + cmd.AddCommand(newInstallObservability(pctx)) + cmd.AddCommand(newInstallMetrics()) + cmd.AddCommand(newInstallTracing()) + cmd.AddCommand(newInstallLogging()) cmd.AddCommand(newInstallDemoCmd(&pctx.InstallDemoContext)) cmd.AddCommand(newInstallGatewayCmd(pctx)) cmd.AddCommand(newInstallTransparentProxy()) diff --git a/app/kumactl/cmd/install/install_logging.go b/app/kumactl/cmd/install/install_logging.go index b62fd4169924..ff813f1f7a0c 100644 --- a/app/kumactl/cmd/install/install_logging.go +++ b/app/kumactl/cmd/install/install_logging.go @@ -3,51 +3,16 @@ package install import ( "github.com/pkg/errors" "github.com/spf13/cobra" - - kumactl_data "github.com/kumahq/kuma/app/kumactl/data" - kumactl_cmd "github.com/kumahq/kuma/app/kumactl/pkg/cmd" - "github.com/kumahq/kuma/app/kumactl/pkg/install/data" - "github.com/kumahq/kuma/app/kumactl/pkg/install/k8s" ) -type loggingTemplateArgs struct { - Namespace string -} - -func newInstallLogging(pctx *kumactl_cmd.RootContext) *cobra.Command { - args := pctx.InstallLoggingContext.TemplateArgs +func newInstallLogging() *cobra.Command { cmd := &cobra.Command{ Use: "logging", Short: "Install Logging backend in Kubernetes cluster (Loki)", Long: `Install Logging backend in Kubernetes cluster (Loki) in its own namespace.`, RunE: func(cmd *cobra.Command, _ []string) error { - templateArgs := loggingTemplateArgs{ - Namespace: args.Namespace, - } - - templateFiles, err := data.ReadFiles(kumactl_data.InstallLoggingFS()) - if err != nil { - return errors.Wrap(err, "Failed to read template files") - } - - renderedFiles, err := renderFiles(templateFiles, templateArgs, simpleTemplateRenderer) - if err != nil { - return errors.Wrap(err, "Failed to render template files") - } - - sortedResources, err := k8s.SortResourcesByKind(renderedFiles) - if err != nil { - return errors.Wrap(err, "Failed to sort resources by kind") - } - - singleFile := data.JoinYAML(sortedResources) - - if _, err := cmd.OutOrStdout().Write(singleFile.Data); err != nil { - return errors.Wrap(err, "Failed to output rendered resources") - } - return nil + return errors.New("we're migrating to `observability`, please use `install observability`") }, } - cmd.Flags().StringVar(&args.Namespace, "namespace", args.Namespace, "namespace to install logging to") return cmd } diff --git a/app/kumactl/cmd/install/install_logging_test.go b/app/kumactl/cmd/install/install_logging_test.go deleted file mode 100644 index 767931daca54..000000000000 --- a/app/kumactl/cmd/install/install_logging_test.go +++ /dev/null @@ -1,68 +0,0 @@ -package install_test - -import ( - "bytes" - "path/filepath" - - . "github.com/onsi/ginkgo/v2" - . "github.com/onsi/gomega" - - "github.com/kumahq/kuma/pkg/util/test" - kuma_version "github.com/kumahq/kuma/pkg/version" -) - -var _ = Describe("kumactl install logging", func() { - - var stdout *bytes.Buffer - var stderr *bytes.Buffer - - BeforeEach(func() { - stdout = &bytes.Buffer{} - stderr = &bytes.Buffer{} - }) - - type testCase struct { - extraArgs []string - goldenFile string - } - - BeforeEach(func() { - kuma_version.Build = kuma_version.BuildInfo{ - Version: "0.0.1", - GitTag: "v0.0.1", - GitCommit: "91ce236824a9d875601679aa80c63783fb0e8725", - BuildDate: "2019-08-07T11:26:06Z", - } - }) - - DescribeTable("should generate Kubernetes resources", - func(given testCase) { - // given - rootCmd := test.DefaultTestingRootCmd() - rootCmd.SetArgs(append([]string{"install", "logging"}, given.extraArgs...)) - rootCmd.SetOut(stdout) - rootCmd.SetErr(stderr) - - // when - err := rootCmd.Execute() - - // then - Expect(err).ToNot(HaveOccurred()) - Expect(stderr.String()).To(BeEmpty()) - - // and output matches golden files - actual := stdout.Bytes() - ExpectMatchesGoldenFiles(actual, filepath.Join("testdata", given.goldenFile)) - }, - Entry("should generate Kubernetes resources with default settings", testCase{ - extraArgs: nil, - goldenFile: "install-logging.defaults.golden.yaml", - }), - Entry("should generate Kubernetes resources with custom settings", testCase{ - extraArgs: []string{ - "--namespace", "kuma", - }, - goldenFile: "install-logging.overrides.golden.yaml", - }), - ) -}) diff --git a/app/kumactl/cmd/install/install_metrics.go b/app/kumactl/cmd/install/install_metrics.go index 37f4c2f1a4ca..758eff925dc8 100644 --- a/app/kumactl/cmd/install/install_metrics.go +++ b/app/kumactl/cmd/install/install_metrics.go @@ -1,121 +1,18 @@ package install import ( - "strings" - "github.com/pkg/errors" "github.com/spf13/cobra" - - "github.com/kumahq/kuma/app/kumactl/cmd/install/context" - kumactl_data "github.com/kumahq/kuma/app/kumactl/data" - kumactl_cmd "github.com/kumahq/kuma/app/kumactl/pkg/cmd" - "github.com/kumahq/kuma/app/kumactl/pkg/install/data" - "github.com/kumahq/kuma/app/kumactl/pkg/install/k8s" ) -func newInstallMetrics(pctx *kumactl_cmd.RootContext) *cobra.Command { - args := pctx.InstallMetricsContext.TemplateArgs +func newInstallMetrics() *cobra.Command { cmd := &cobra.Command{ Use: "metrics", Short: "Install Metrics backend in Kubernetes cluster (Prometheus + Grafana)", Long: `Install Metrics backend in Kubernetes cluster (Prometheus + Grafana) in its own namespace.`, RunE: func(cmd *cobra.Command, _ []string) error { - installMetricsFS := kumactl_data.InstallMetricsFS() - templateFiles, err := data.ReadFiles(installMetricsFS) - if err != nil { - return errors.Wrap(err, "Failed to read template files") - } - yamlTemplateFiles := templateFiles.Filter(func(file data.File) bool { - return strings.HasSuffix(file.Name, ".yaml") - }) - - dashboard, err := data.ReadFile(installMetricsFS, "grafana/kuma-dataplane.json") - if err != nil { - return err - } - args.Dashboards = append(args.Dashboards, context.Dashboard{ - FileName: "kuma-dataplane.json", - Content: dashboard.String(), - }) - - dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-mesh.json") - if err != nil { - return err - } - args.Dashboards = append(args.Dashboards, context.Dashboard{ - FileName: "kuma-mesh.json", - Content: dashboard.String(), - }) - - dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-service-to-service.json") - if err != nil { - return err - } - args.Dashboards = append(args.Dashboards, context.Dashboard{ - FileName: "kuma-service-to-service.json", - Content: dashboard.String(), - }) - - dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-cp.json") - if err != nil { - return err - } - args.Dashboards = append(args.Dashboards, context.Dashboard{ - FileName: "kuma-cp.json", - Content: dashboard.String(), - }) - - dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-service.json") - if err != nil { - return err - } - args.Dashboards = append(args.Dashboards, context.Dashboard{ - FileName: "kuma-service.json", - Content: dashboard.String(), - }) - - filter := getExcludePrefixesFilter(args.WithoutPrometheus, args.WithoutGrafana) - - renderedFiles, err := renderFilesWithFilter(yamlTemplateFiles, args, simpleTemplateRenderer, filter) - if err != nil { - return errors.Wrap(err, "Failed to render template files") - } - - sortedResources, err := k8s.SortResourcesByKind(renderedFiles) - if err != nil { - return errors.Wrap(err, "Failed to sort resources by kind") - } - - singleFile := data.JoinYAML(sortedResources) - - if _, err := cmd.OutOrStdout().Write(singleFile.Data); err != nil { - return errors.Wrap(err, "Failed to output rendered resources") - } - return nil + return errors.New("we're migrating to `observability`, please use `install observability`") }, } - cmd.Flags().StringVar(&args.Namespace, "namespace", args.Namespace, "namespace to install metrics to") - cmd.PersistentFlags().StringVarP(&args.Mesh, "mesh", "m", "default", "mesh to use") - cmd.Flags().StringVar(&args.KumaCpAddress, "kuma-cp-address", args.KumaCpAddress, "the address of Kuma CP") - cmd.Flags().StringVar(&args.JaegerAddress, "jaeger-address", args.JaegerAddress, "the address of jaeger to query") - cmd.Flags().StringVar(&args.LokiAddress, "loki-address", args.LokiAddress, "the address of the loki to query") - cmd.Flags().BoolVar(&args.WithoutPrometheus, "without-prometheus", args.WithoutPrometheus, "disable Prometheus resources generation") - cmd.Flags().BoolVar(&args.WithoutGrafana, "without-grafana", args.WithoutGrafana, "disable Grafana resources generation") return cmd } - -func getExcludePrefixesFilter(withoutPrometheus, withoutGrafana bool) ExcludePrefixesFilter { - prefixes := []string{} - - if withoutPrometheus { - prefixes = append(prefixes, "prometheus") - } - - if withoutGrafana { - prefixes = append(prefixes, "grafana") - } - - return ExcludePrefixesFilter{ - Prefixes: prefixes, - } -} diff --git a/app/kumactl/cmd/install/install_observability.go b/app/kumactl/cmd/install/install_observability.go new file mode 100644 index 000000000000..208d1e771658 --- /dev/null +++ b/app/kumactl/cmd/install/install_observability.go @@ -0,0 +1,181 @@ +package install + +import ( + "strings" + + "github.com/pkg/errors" + "github.com/spf13/cobra" + + "github.com/kumahq/kuma/app/kumactl/cmd/install/context" + kumactl_data "github.com/kumahq/kuma/app/kumactl/data" + kumactl_cmd "github.com/kumahq/kuma/app/kumactl/pkg/cmd" + "github.com/kumahq/kuma/app/kumactl/pkg/install/data" + "github.com/kumahq/kuma/app/kumactl/pkg/install/k8s" +) + +var components = []string{"prometheus", "grafana", "loki", "jaeger"} + +func newInstallObservability(pctx *kumactl_cmd.RootContext) *cobra.Command { + args := pctx.InstallObservabilityContext.TemplateArgs + cmd := &cobra.Command{ + Use: "observability", + Short: "Install Observability (Metrics, Logging, Tracing) backend in Kubernetes cluster (Prometheus + Grafana + Loki + Jaeger + Zipkin)", + Long: `Install Observability (Metrics, Logging, Tracing) backend in Kubernetes cluster (Prometheus + Grafana + Loki + Jaeger + Zipkin) in its own namespace.`, + RunE: func(cmd *cobra.Command, _ []string) error { + componentsMap := map[string]bool{} + for _, component := range args.Components { + componentsMap[component] = true + } + args.ComponentsMap = componentsMap + metrics, err := getMetrics(&args) + if err != nil { + return err + } + logging, err := getLogging(&args) + if err != nil { + return err + } + tracing, err := getTracing(&args) + if err != nil { + return err + } + combinedResources := make([]data.File, len(metrics)+len(logging)+len(tracing)) + combinedResources = append(combinedResources, metrics...) + combinedResources = append(combinedResources, logging...) + combinedResources = append(combinedResources, tracing...) + + singleFile := data.JoinYAML(combinedResources) + + if _, err := cmd.OutOrStdout().Write(singleFile.Data); err != nil { + return errors.Wrap(err, "Failed to output rendered resources") + } + return nil + }, + } + cmd.Flags().StringVar(&args.Namespace, "namespace", args.Namespace, "namespace to install observability to") + cmd.PersistentFlags().StringVarP(&args.Mesh, "mesh", "m", "default", "mesh to use") + cmd.Flags().StringVar(&args.KumaCpAddress, "kuma-cp-address", args.KumaCpAddress, "the address of Kuma CP") + cmd.Flags().StringVar(&args.JaegerAddress, "jaeger-address", args.JaegerAddress, "the address of jaeger to query") + cmd.Flags().StringVar(&args.LokiAddress, "loki-address", args.LokiAddress, "the address of the loki to query") + cmd.Flags().StringVar(&args.PrometheusAddress, "prometheus-address", args.PrometheusAddress, "the address of the prometheus server") + cmd.Flags().StringSliceVar(&args.Components, "components", args.Components, "list of components") + return cmd +} + +func getMetrics(args *context.ObservabilityTemplateArgs) ([]data.File, error) { + installMetricsFS := kumactl_data.InstallMetricsFS() + templateFiles, err := data.ReadFiles(installMetricsFS) + if err != nil { + return nil, errors.Wrap(err, "Failed to read template files") + } + yamlTemplateFiles := templateFiles.Filter(func(file data.File) bool { + return strings.HasSuffix(file.Name, ".yaml") + }) + + dashboard, err := data.ReadFile(installMetricsFS, "grafana/kuma-dataplane.json") + if err != nil { + return nil, err + } + args.Dashboards = append(args.Dashboards, context.Dashboard{ + FileName: "kuma-dataplane.json", + Content: dashboard.String(), + }) + + dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-mesh.json") + if err != nil { + return nil, err + } + args.Dashboards = append(args.Dashboards, context.Dashboard{ + FileName: "kuma-mesh.json", + Content: dashboard.String(), + }) + + dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-service-to-service.json") + if err != nil { + return nil, err + } + args.Dashboards = append(args.Dashboards, context.Dashboard{ + FileName: "kuma-service-to-service.json", + Content: dashboard.String(), + }) + + dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-cp.json") + if err != nil { + return nil, err + } + args.Dashboards = append(args.Dashboards, context.Dashboard{ + FileName: "kuma-cp.json", + Content: dashboard.String(), + }) + + dashboard, err = data.ReadFile(installMetricsFS, "grafana/kuma-service.json") + if err != nil { + return nil, err + } + args.Dashboards = append(args.Dashboards, context.Dashboard{ + FileName: "kuma-service.json", + Content: dashboard.String(), + }) + + filter := getExcludePrefixesFilter(args) + renderedFiles, err := renderFilesWithFilter(yamlTemplateFiles, args, simpleTemplateRenderer, filter) + if err != nil { + return nil, errors.Wrap(err, "Failed to render template files") + } + + sortedResources, err := k8s.SortResourcesByKind(renderedFiles) + if err != nil { + return nil, errors.Wrap(err, "Failed to sort resources by kind") + } + return sortedResources, nil +} + +func getLogging(args *context.ObservabilityTemplateArgs) ([]data.File, error) { + templateFiles, err := data.ReadFiles(kumactl_data.InstallLoggingFS()) + if err != nil { + return nil, errors.Wrap(err, "Failed to read template files") + } + + filter := getExcludePrefixesFilter(args) + renderedFiles, err := renderFilesWithFilter(templateFiles, args, simpleTemplateRenderer, filter) + if err != nil { + return nil, errors.Wrap(err, "Failed to render template files") + } + + sortedResources, err := k8s.SortResourcesByKind(renderedFiles) + if err != nil { + return nil, errors.Wrap(err, "Failed to sort resources by kind") + } + return sortedResources, nil +} + +func getTracing(args *context.ObservabilityTemplateArgs) ([]data.File, error) { + templateFiles, err := data.ReadFiles(kumactl_data.InstallTracingFS()) + if err != nil { + return nil, errors.Wrap(err, "Failed to read template files") + } + + filter := getExcludePrefixesFilter(args) + renderedFiles, err := renderFilesWithFilter(templateFiles, args, simpleTemplateRenderer, filter) + if err != nil { + return nil, errors.Wrap(err, "Failed to render template files") + } + + sortedResources, err := k8s.SortResourcesByKind(renderedFiles) + if err != nil { + return nil, errors.Wrap(err, "Failed to sort resources by kind") + } + return sortedResources, nil +} + +func getExcludePrefixesFilter(args *context.ObservabilityTemplateArgs) ExcludePrefixesFilter { + prefixes := []string{} + for _, key := range components { + if !args.ComponentsMap[key] { + prefixes = append(prefixes, key) + } + } + return ExcludePrefixesFilter{ + Prefixes: prefixes, + } +} diff --git a/app/kumactl/cmd/install/install_metrics_test.go b/app/kumactl/cmd/install/install_observability_test.go similarity index 67% rename from app/kumactl/cmd/install/install_metrics_test.go rename to app/kumactl/cmd/install/install_observability_test.go index 32e899cca208..a6077cf0b681 100644 --- a/app/kumactl/cmd/install/install_metrics_test.go +++ b/app/kumactl/cmd/install/install_observability_test.go @@ -13,7 +13,7 @@ import ( kuma_version "github.com/kumahq/kuma/pkg/version" ) -var _ = Describe("kumactl install metrics", func() { +var _ = Describe("kumactl install observability", func() { var stdout *bytes.Buffer var stderr *bytes.Buffer @@ -43,7 +43,7 @@ var _ = Describe("kumactl install metrics", func() { rootCtx := kumactl_cmd.DefaultRootContext() rootCtx.Runtime.NewAPIServerClient = test.GetMockNewAPIServerClient() rootCmd := cmd.NewRootCmd(rootCtx) - rootCmd.SetArgs(append([]string{"install", "metrics"}, given.extraArgs...)) + rootCmd.SetArgs(append([]string{"install", "observability"}, given.extraArgs...)) rootCmd.SetOut(stdout) rootCmd.SetErr(stderr) @@ -60,7 +60,7 @@ var _ = Describe("kumactl install metrics", func() { }, Entry("should generate Kubernetes resources with default settings", testCase{ extraArgs: nil, - goldenFile: "install-metrics.defaults.golden.yaml", + goldenFile: "install-observability.defaults.golden.yaml", }), Entry("should generate Kubernetes resources with custom settings", testCase{ extraArgs: []string{ @@ -68,19 +68,31 @@ var _ = Describe("kumactl install metrics", func() { "--mesh", "mesh-1", "--kuma-cp-address", "http://kuma.local:5681", }, - goldenFile: "install-metrics.overrides.golden.yaml", + goldenFile: "install-observability.overrides.golden.yaml", }), Entry("should generate Kubernetes resources without prometheus", testCase{ extraArgs: []string{ - "--without-prometheus", + "--components", "grafana,jaeger,loki", }, - goldenFile: "install-metrics.no-prometheus.golden.yaml", + goldenFile: "install-observability.no-prometheus.golden.yaml", }), Entry("should generate Kubernetes resources without grafana", testCase{ extraArgs: []string{ - "--without-grafana", + "--components", "prometheus,jaeger,loki", }, - goldenFile: "install-metrics.no-grafana.golden.yaml", + goldenFile: "install-observability.no-grafana.golden.yaml", + }), + Entry("should generate Kubernetes resources without loki", testCase{ + extraArgs: []string{ + "--components", "prometheus,jaeger,grafana", + }, + goldenFile: "install-observability.no-loki.golden.yaml", + }), + Entry("should generate Kubernetes resources without jaeger", testCase{ + extraArgs: []string{ + "--components", "prometheus,grafana,loki", + }, + goldenFile: "install-observability.no-jaeger.golden.yaml", }), ) }) diff --git a/app/kumactl/cmd/install/install_tracing.go b/app/kumactl/cmd/install/install_tracing.go index bfe3b0f9eb27..ae00dd200372 100644 --- a/app/kumactl/cmd/install/install_tracing.go +++ b/app/kumactl/cmd/install/install_tracing.go @@ -3,51 +3,16 @@ package install import ( "github.com/pkg/errors" "github.com/spf13/cobra" - - kumactl_data "github.com/kumahq/kuma/app/kumactl/data" - kumactl_cmd "github.com/kumahq/kuma/app/kumactl/pkg/cmd" - "github.com/kumahq/kuma/app/kumactl/pkg/install/data" - "github.com/kumahq/kuma/app/kumactl/pkg/install/k8s" ) -type tracingTemplateArgs struct { - Namespace string -} - -func newInstallTracing(pctx *kumactl_cmd.RootContext) *cobra.Command { - args := pctx.InstallTracingContext.TemplateArgs +func newInstallTracing() *cobra.Command { cmd := &cobra.Command{ Use: "tracing", Short: "Install Tracing backend in Kubernetes cluster (Jaeger)", Long: `Install Tracing backend in Kubernetes cluster (Jaeger) in its own namespace.`, RunE: func(cmd *cobra.Command, _ []string) error { - templateArgs := tracingTemplateArgs{ - Namespace: args.Namespace, - } - - templateFiles, err := data.ReadFiles(kumactl_data.InstallTracingFS()) - if err != nil { - return errors.Wrap(err, "Failed to read template files") - } - - renderedFiles, err := renderFiles(templateFiles, templateArgs, simpleTemplateRenderer) - if err != nil { - return errors.Wrap(err, "Failed to render template files") - } - - sortedResources, err := k8s.SortResourcesByKind(renderedFiles) - if err != nil { - return errors.Wrap(err, "Failed to sort resources by kind") - } - - singleFile := data.JoinYAML(sortedResources) - - if _, err := cmd.OutOrStdout().Write(singleFile.Data); err != nil { - return errors.Wrap(err, "Failed to output rendered resources") - } - return nil + return errors.New("we're migrating to `observability`, please use `install observability`") }, } - cmd.Flags().StringVar(&args.Namespace, "namespace", args.Namespace, "namespace to install tracing to") return cmd } diff --git a/app/kumactl/cmd/install/install_tracing_test.go b/app/kumactl/cmd/install/install_tracing_test.go deleted file mode 100644 index 7959272e78a8..000000000000 --- a/app/kumactl/cmd/install/install_tracing_test.go +++ /dev/null @@ -1,58 +0,0 @@ -package install_test - -import ( - "bytes" - "path/filepath" - - . "github.com/onsi/ginkgo/v2" - . "github.com/onsi/gomega" - - "github.com/kumahq/kuma/pkg/util/test" -) - -var _ = Describe("kumactl install tracing", func() { - - var stdout *bytes.Buffer - var stderr *bytes.Buffer - - BeforeEach(func() { - stdout = &bytes.Buffer{} - stderr = &bytes.Buffer{} - }) - - type testCase struct { - extraArgs []string - goldenFile string - } - - DescribeTable("should generate Kubernetes resources", - func(given testCase) { - // given - rootCmd := test.DefaultTestingRootCmd() - rootCmd.SetArgs(append([]string{"install", "tracing"}, given.extraArgs...)) - rootCmd.SetOut(stdout) - rootCmd.SetErr(stderr) - - // when - err := rootCmd.Execute() - - // then - Expect(err).ToNot(HaveOccurred()) - Expect(stderr.String()).To(BeEmpty()) - - // and output matches golden files - actual := stdout.Bytes() - ExpectMatchesGoldenFiles(actual, filepath.Join("testdata", given.goldenFile)) - }, - Entry("should generate Kubernetes resources with default settings", testCase{ - extraArgs: nil, - goldenFile: "install-tracing.defaults.golden.yaml", - }), - Entry("should generate Kubernetes resources with custom settings", testCase{ - extraArgs: []string{ - "--namespace", "kuma", - }, - goldenFile: "install-tracing.overrides.golden.yaml", - }), - ) -}) diff --git a/app/kumactl/cmd/install/testdata/install-logging.defaults.golden.yaml b/app/kumactl/cmd/install/testdata/install-logging.defaults.golden.yaml deleted file mode 100644 index 28fd9927268c..000000000000 --- a/app/kumactl/cmd/install/testdata/install-logging.defaults.golden.yaml +++ /dev/null @@ -1,727 +0,0 @@ - ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kuma-logging ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kuma-logging ---- -apiVersion: policy/v1beta1 -kind: PodSecurityPolicy -metadata: - name: loki - namespace: kuma-logging - labels: - app: loki - release: loki -spec: - privileged: false - allowPrivilegeEscalation: false - volumes: - - 'configMap' - - 'emptyDir' - - 'persistentVolumeClaim' - - 'secret' - hostNetwork: false - hostIPC: false - hostPID: false - runAsUser: - rule: 'MustRunAsNonRoot' - seLinux: - rule: 'RunAsAny' - supplementalGroups: - rule: 'MustRunAs' - ranges: - - min: 1 - max: 65535 - fsGroup: - rule: 'MustRunAs' - ranges: - - min: 1 - max: 65535 - readOnlyRootFilesystem: true - requiredDropCapabilities: - - ALL ---- -apiVersion: policy/v1beta1 -kind: PodSecurityPolicy -metadata: - name: loki-promtail - namespace: kuma-logging - labels: - app: promtail - release: loki -spec: - privileged: false - allowPrivilegeEscalation: false - volumes: - - 'secret' - - 'configMap' - - 'hostPath' - hostNetwork: false - hostIPC: false - hostPID: false - runAsUser: - rule: 'RunAsAny' - seLinux: - rule: 'RunAsAny' - supplementalGroups: - rule: 'RunAsAny' - fsGroup: - rule: 'RunAsAny' - readOnlyRootFilesystem: true - requiredDropCapabilities: - - ALL ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - app: loki - release: loki - annotations: - {} - name: loki - namespace: kuma-logging ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - app: promtail - release: loki - name: loki-promtail - namespace: kuma-logging ---- -apiVersion: v1 -kind: Secret -metadata: - name: loki - namespace: kuma-logging - labels: - app: loki - release: loki -data: - loki.yaml: YXV0aF9lbmFibGVkOiBmYWxzZQpjaHVua19zdG9yZV9jb25maWc6CiAgbWF4X2xvb2tfYmFja19wZXJpb2Q6IDBzCmluZ2VzdGVyOgogIGNodW5rX2Jsb2NrX3NpemU6IDI2MjE0NAogIGNodW5rX2lkbGVfcGVyaW9kOiAzbQogIGNodW5rX3JldGFpbl9wZXJpb2Q6IDFtCiAgbGlmZWN5Y2xlcjoKICAgIHJpbmc6CiAgICAgIGt2c3RvcmU6CiAgICAgICAgc3RvcmU6IGlubWVtb3J5CiAgICAgIHJlcGxpY2F0aW9uX2ZhY3RvcjogMQogIHdhbDoKICAgIGVuYWJsZWQ6IGZhbHNlCmxpbWl0c19jb25maWc6CiAgZW5mb3JjZV9tZXRyaWNfbmFtZTogZmFsc2UKc2NoZW1hX2NvbmZpZzoKICBjb25maWdzOgogIC0gZnJvbTogIjIwMTgtMDQtMTUiCiAgICBpbmRleDoKICAgICAgcGVyaW9kOiAxNjhoCiAgICAgIHByZWZpeDogaW5kZXhfCiAgICBvYmplY3Rfc3RvcmU6IGZpbGVzeXN0ZW0KICAgIHNjaGVtYTogdjkKICAgIHN0b3JlOiBib2x0ZGIKc2VydmVyOgogIGh0dHBfbGlzdGVuX3BvcnQ6IDMxMDAKc3RvcmFnZV9jb25maWc6CiAgYm9sdGRiOgogICAgZGlyZWN0b3J5OiAvZGF0YS9sb2tpL2luZGV4CiAgZmlsZXN5c3RlbToKICAgIGRpcmVjdG9yeTogL2RhdGEvbG9raS9jaHVua3MKdGFibGVfbWFuYWdlcjoKICByZXRlbnRpb25fZGVsZXRlc19lbmFibGVkOiBmYWxzZQogIHJldGVudGlvbl9wZXJpb2Q6IDBzCg== ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: loki-promtail - namespace: kuma-logging - labels: - app: promtail - release: loki -data: - promtail.yaml: | - client: - backoff_config: - max_period: 5s - max_retries: 20 - min_period: 100ms - batchsize: 102400 - batchwait: 1s - external_labels: {} - timeout: 10s - positions: - filename: /run/promtail/positions.yaml - server: - http_listen_port: 3101 - target_config: - sync_period: 10s - scrape_configs: - - job_name: kubernetes-pods-name - pipeline_stages: - - docker: {} - - match: - selector: '{container="kuma-sidecar"}' - stages: - - regex: - expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' - - labels: - mesh: mesh - - timestamp: - format: RFC3339Nano - source: timestamp - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: replace - separator: '.' - replacement: "$1" - source_labels: - - __meta_kubernetes_pod_annotation_kuma_io_mesh - - __meta_kubernetes_pod_name - - __meta_kubernetes_namespace - target_label: node_id - - source_labels: - - __meta_kubernetes_pod_label_name - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-app - pipeline_stages: - - docker: {} - - match: - selector: '{container="kuma-sidecar"}' - stages: - - regex: - expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' - - labels: - mesh: mesh - - timestamp: - format: RFC3339Nano - source: timestamp - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: replace - separator: '.' - replacement: "$1" - source_labels: - - __meta_kubernetes_pod_annotation_kuma_io_mesh - - __meta_kubernetes_pod_name - - __meta_kubernetes_namespace - target_label: node_id - - action: drop - regex: .+ - source_labels: - - __meta_kubernetes_pod_label_name - - source_labels: - - __meta_kubernetes_pod_label_app - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-direct-controllers - pipeline_stages: - - docker: {} - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: drop - regex: .+ - separator: '' - source_labels: - - __meta_kubernetes_pod_label_name - - __meta_kubernetes_pod_label_app - - action: drop - regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' - source_labels: - - __meta_kubernetes_pod_controller_name - - source_labels: - - __meta_kubernetes_pod_controller_name - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-indirect-controller - pipeline_stages: - - docker: {} - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: drop - regex: .+ - separator: '' - source_labels: - - __meta_kubernetes_pod_label_name - - __meta_kubernetes_pod_label_app - - action: keep - regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' - source_labels: - - __meta_kubernetes_pod_controller_name - - action: replace - regex: '([0-9a-z-.]+)-[0-9a-f]{8,10}' - source_labels: - - __meta_kubernetes_pod_controller_name - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-static - pipeline_stages: - - docker: {} - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: drop - regex: '' - source_labels: - - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror - - action: replace - source_labels: - - __meta_kubernetes_pod_label_component - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror - - __meta_kubernetes_pod_container_name - target_label: __path__ ---- -kind: ClusterRole -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - labels: - app: promtail - release: loki - name: loki-promtail-clusterrole - namespace: kuma-logging -rules: - - apiGroups: [""] # "" indicates the core API group - resources: - - nodes - - nodes/proxy - - services - - endpoints - - pods - verbs: ["get", "watch", "list"] ---- -kind: ClusterRoleBinding -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - name: loki-promtail-clusterrolebinding - labels: - app: promtail - release: loki -subjects: - - kind: ServiceAccount - name: loki-promtail - namespace: kuma-logging -roleRef: - kind: ClusterRole - name: loki-promtail-clusterrole - apiGroup: rbac.authorization.k8s.io ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: loki-promtail - namespace: kuma-logging - labels: - app: promtail - release: loki -rules: - - apiGroups: ['extensions'] - resources: ['podsecuritypolicies'] - verbs: ['use'] - resourceNames: [loki-promtail] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: loki - namespace: kuma-logging - labels: - app: loki - release: loki -rules: - - apiGroups: ['extensions'] - resources: ['podsecuritypolicies'] - verbs: ['use'] - resourceNames: [loki] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: loki - namespace: kuma-logging - labels: - app: loki - release: loki -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: loki -subjects: - - kind: ServiceAccount - name: loki ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: loki-promtail - namespace: kuma-logging - labels: - app: promtail - release: loki -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: loki-promtail -subjects: - - kind: ServiceAccount - name: loki-promtail ---- -apiVersion: v1 -kind: Service -metadata: - name: loki-headless - namespace: kuma-logging - labels: - app: loki - release: loki - variant: headless -spec: - clusterIP: None - ports: - - port: 3100 - protocol: TCP - name: http-metrics - targetPort: http-metrics - selector: - app: loki - release: loki ---- -apiVersion: v1 -kind: Service -metadata: - name: loki - namespace: kuma-logging - labels: - app: loki - release: loki - annotations: - {} -spec: - type: ClusterIP - ports: - - port: 3100 - protocol: TCP - name: http-metrics - targetPort: http-metrics - selector: - app: loki - release: loki ---- -apiVersion: apps/v1 -kind: DaemonSet -metadata: - name: loki-promtail - namespace: kuma-logging - labels: - app: promtail - release: loki - annotations: - {} -spec: - selector: - matchLabels: - app: promtail - release: loki - updateStrategy: - {} - template: - metadata: - labels: - app: promtail - release: loki - annotations: - checksum/config: bce7daf9d5acc773342c4f42e700668ef8bdc8f34fa1499c766263fa0c1944e0 - prometheus.io/port: http-metrics - prometheus.io/scrape: "true" - spec: - serviceAccountName: loki-promtail - containers: - - name: promtail - image: "grafana/promtail:2.4.1" - imagePullPolicy: IfNotPresent - args: - - "-config.file=/etc/promtail/promtail.yaml" - - "-client.url=http://loki.kuma-logging:3100/loki/api/v1/push" - volumeMounts: - - name: config - mountPath: /etc/promtail - - name: run - mountPath: /run/promtail - - mountPath: /var/lib/docker/containers - name: docker - readOnly: true - - mountPath: /var/log/pods - name: pods - readOnly: true - env: - - name: HOSTNAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - ports: - - containerPort: 3101 - name: http-metrics - securityContext: - readOnlyRootFilesystem: true - runAsGroup: 0 - runAsUser: 0 - readinessProbe: - failureThreshold: 5 - httpGet: - path: /ready - port: http-metrics - initialDelaySeconds: 10 - periodSeconds: 10 - successThreshold: 1 - timeoutSeconds: 1 - resources: - {} - nodeSelector: - {} - affinity: - {} - tolerations: - - effect: NoSchedule - key: node-role.kubernetes.io/master - operator: Exists - volumes: - - name: config - configMap: - name: loki-promtail - - name: run - hostPath: - path: /run/promtail - - hostPath: - path: /var/lib/docker/containers - name: docker - - hostPath: - path: /var/log/pods - name: pods ---- -apiVersion: apps/v1 -kind: StatefulSet -metadata: - name: loki - namespace: kuma-logging - labels: - app: loki - release: loki - annotations: - {} -spec: - podManagementPolicy: OrderedReady - replicas: 1 - selector: - matchLabels: - app: loki - release: loki - serviceName: loki-headless - updateStrategy: - type: RollingUpdate - template: - metadata: - labels: - app: loki - name: loki - release: loki - annotations: - checksum/config: d4c94f4c6a73353362c10d2f844340cec8999b291ca88481ac162fbb5942617d - prometheus.io/port: http-metrics - prometheus.io/scrape: "true" - spec: - serviceAccountName: loki - securityContext: - fsGroup: 10001 - runAsGroup: 10001 - runAsNonRoot: true - runAsUser: 10001 - initContainers: - [] - containers: - - name: loki - image: "grafana/loki:2.4.1" - imagePullPolicy: IfNotPresent - args: - - "-config.file=/etc/loki/loki.yaml" - - "-target=all,table-manager" - volumeMounts: - - name: config - mountPath: /etc/loki - - name: storage - mountPath: "/data" - ports: - - name: http-metrics - containerPort: 3100 - protocol: TCP - livenessProbe: - httpGet: - path: /ready - port: http-metrics - initialDelaySeconds: 45 - readinessProbe: - httpGet: - path: /ready - port: http-metrics - initialDelaySeconds: 45 - resources: - {} - securityContext: - readOnlyRootFilesystem: true - nodeSelector: - {} - affinity: - {} - tolerations: - [] - terminationGracePeriodSeconds: 4800 - volumes: - - name: config - secret: - secretName: loki - - name: storage - emptyDir: {} diff --git a/app/kumactl/cmd/install/testdata/install-logging.overrides.golden.yaml b/app/kumactl/cmd/install/testdata/install-logging.overrides.golden.yaml deleted file mode 100644 index 579e52138225..000000000000 --- a/app/kumactl/cmd/install/testdata/install-logging.overrides.golden.yaml +++ /dev/null @@ -1,727 +0,0 @@ - ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kuma ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kuma ---- -apiVersion: policy/v1beta1 -kind: PodSecurityPolicy -metadata: - name: loki - namespace: kuma - labels: - app: loki - release: loki -spec: - privileged: false - allowPrivilegeEscalation: false - volumes: - - 'configMap' - - 'emptyDir' - - 'persistentVolumeClaim' - - 'secret' - hostNetwork: false - hostIPC: false - hostPID: false - runAsUser: - rule: 'MustRunAsNonRoot' - seLinux: - rule: 'RunAsAny' - supplementalGroups: - rule: 'MustRunAs' - ranges: - - min: 1 - max: 65535 - fsGroup: - rule: 'MustRunAs' - ranges: - - min: 1 - max: 65535 - readOnlyRootFilesystem: true - requiredDropCapabilities: - - ALL ---- -apiVersion: policy/v1beta1 -kind: PodSecurityPolicy -metadata: - name: loki-promtail - namespace: kuma - labels: - app: promtail - release: loki -spec: - privileged: false - allowPrivilegeEscalation: false - volumes: - - 'secret' - - 'configMap' - - 'hostPath' - hostNetwork: false - hostIPC: false - hostPID: false - runAsUser: - rule: 'RunAsAny' - seLinux: - rule: 'RunAsAny' - supplementalGroups: - rule: 'RunAsAny' - fsGroup: - rule: 'RunAsAny' - readOnlyRootFilesystem: true - requiredDropCapabilities: - - ALL ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - app: loki - release: loki - annotations: - {} - name: loki - namespace: kuma ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - app: promtail - release: loki - name: loki-promtail - namespace: kuma ---- -apiVersion: v1 -kind: Secret -metadata: - name: loki - namespace: kuma - labels: - app: loki - release: loki -data: - loki.yaml: YXV0aF9lbmFibGVkOiBmYWxzZQpjaHVua19zdG9yZV9jb25maWc6CiAgbWF4X2xvb2tfYmFja19wZXJpb2Q6IDBzCmluZ2VzdGVyOgogIGNodW5rX2Jsb2NrX3NpemU6IDI2MjE0NAogIGNodW5rX2lkbGVfcGVyaW9kOiAzbQogIGNodW5rX3JldGFpbl9wZXJpb2Q6IDFtCiAgbGlmZWN5Y2xlcjoKICAgIHJpbmc6CiAgICAgIGt2c3RvcmU6CiAgICAgICAgc3RvcmU6IGlubWVtb3J5CiAgICAgIHJlcGxpY2F0aW9uX2ZhY3RvcjogMQogIHdhbDoKICAgIGVuYWJsZWQ6IGZhbHNlCmxpbWl0c19jb25maWc6CiAgZW5mb3JjZV9tZXRyaWNfbmFtZTogZmFsc2UKc2NoZW1hX2NvbmZpZzoKICBjb25maWdzOgogIC0gZnJvbTogIjIwMTgtMDQtMTUiCiAgICBpbmRleDoKICAgICAgcGVyaW9kOiAxNjhoCiAgICAgIHByZWZpeDogaW5kZXhfCiAgICBvYmplY3Rfc3RvcmU6IGZpbGVzeXN0ZW0KICAgIHNjaGVtYTogdjkKICAgIHN0b3JlOiBib2x0ZGIKc2VydmVyOgogIGh0dHBfbGlzdGVuX3BvcnQ6IDMxMDAKc3RvcmFnZV9jb25maWc6CiAgYm9sdGRiOgogICAgZGlyZWN0b3J5OiAvZGF0YS9sb2tpL2luZGV4CiAgZmlsZXN5c3RlbToKICAgIGRpcmVjdG9yeTogL2RhdGEvbG9raS9jaHVua3MKdGFibGVfbWFuYWdlcjoKICByZXRlbnRpb25fZGVsZXRlc19lbmFibGVkOiBmYWxzZQogIHJldGVudGlvbl9wZXJpb2Q6IDBzCg== ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: loki-promtail - namespace: kuma - labels: - app: promtail - release: loki -data: - promtail.yaml: | - client: - backoff_config: - max_period: 5s - max_retries: 20 - min_period: 100ms - batchsize: 102400 - batchwait: 1s - external_labels: {} - timeout: 10s - positions: - filename: /run/promtail/positions.yaml - server: - http_listen_port: 3101 - target_config: - sync_period: 10s - scrape_configs: - - job_name: kubernetes-pods-name - pipeline_stages: - - docker: {} - - match: - selector: '{container="kuma-sidecar"}' - stages: - - regex: - expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' - - labels: - mesh: mesh - - timestamp: - format: RFC3339Nano - source: timestamp - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: replace - separator: '.' - replacement: "$1" - source_labels: - - __meta_kubernetes_pod_annotation_kuma_io_mesh - - __meta_kubernetes_pod_name - - __meta_kubernetes_namespace - target_label: node_id - - source_labels: - - __meta_kubernetes_pod_label_name - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-app - pipeline_stages: - - docker: {} - - match: - selector: '{container="kuma-sidecar"}' - stages: - - regex: - expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' - - labels: - mesh: mesh - - timestamp: - format: RFC3339Nano - source: timestamp - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: replace - separator: '.' - replacement: "$1" - source_labels: - - __meta_kubernetes_pod_annotation_kuma_io_mesh - - __meta_kubernetes_pod_name - - __meta_kubernetes_namespace - target_label: node_id - - action: drop - regex: .+ - source_labels: - - __meta_kubernetes_pod_label_name - - source_labels: - - __meta_kubernetes_pod_label_app - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-direct-controllers - pipeline_stages: - - docker: {} - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: drop - regex: .+ - separator: '' - source_labels: - - __meta_kubernetes_pod_label_name - - __meta_kubernetes_pod_label_app - - action: drop - regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' - source_labels: - - __meta_kubernetes_pod_controller_name - - source_labels: - - __meta_kubernetes_pod_controller_name - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-indirect-controller - pipeline_stages: - - docker: {} - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: drop - regex: .+ - separator: '' - source_labels: - - __meta_kubernetes_pod_label_name - - __meta_kubernetes_pod_label_app - - action: keep - regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' - source_labels: - - __meta_kubernetes_pod_controller_name - - action: replace - regex: '([0-9a-z-.]+)-[0-9a-f]{8,10}' - source_labels: - - __meta_kubernetes_pod_controller_name - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_uid - - __meta_kubernetes_pod_container_name - target_label: __path__ - - job_name: kubernetes-pods-static - pipeline_stages: - - docker: {} - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: drop - regex: '' - source_labels: - - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror - - action: replace - source_labels: - - __meta_kubernetes_pod_label_component - target_label: __service__ - - source_labels: - - __meta_kubernetes_pod_node_name - target_label: __host__ - - action: drop - regex: '' - source_labels: - - __service__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - replacement: $1 - separator: / - source_labels: - - __meta_kubernetes_namespace - - __service__ - target_label: job - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: pod - - action: replace - source_labels: - - __meta_kubernetes_pod_container_name - target_label: container - - replacement: /var/log/pods/*$1/*.log - separator: / - source_labels: - - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror - - __meta_kubernetes_pod_container_name - target_label: __path__ ---- -kind: ClusterRole -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - labels: - app: promtail - release: loki - name: loki-promtail-clusterrole - namespace: kuma -rules: - - apiGroups: [""] # "" indicates the core API group - resources: - - nodes - - nodes/proxy - - services - - endpoints - - pods - verbs: ["get", "watch", "list"] ---- -kind: ClusterRoleBinding -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - name: loki-promtail-clusterrolebinding - labels: - app: promtail - release: loki -subjects: - - kind: ServiceAccount - name: loki-promtail - namespace: kuma -roleRef: - kind: ClusterRole - name: loki-promtail-clusterrole - apiGroup: rbac.authorization.k8s.io ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: loki-promtail - namespace: kuma - labels: - app: promtail - release: loki -rules: - - apiGroups: ['extensions'] - resources: ['podsecuritypolicies'] - verbs: ['use'] - resourceNames: [loki-promtail] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: loki - namespace: kuma - labels: - app: loki - release: loki -rules: - - apiGroups: ['extensions'] - resources: ['podsecuritypolicies'] - verbs: ['use'] - resourceNames: [loki] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: loki - namespace: kuma - labels: - app: loki - release: loki -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: loki -subjects: - - kind: ServiceAccount - name: loki ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: loki-promtail - namespace: kuma - labels: - app: promtail - release: loki -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: loki-promtail -subjects: - - kind: ServiceAccount - name: loki-promtail ---- -apiVersion: v1 -kind: Service -metadata: - name: loki-headless - namespace: kuma - labels: - app: loki - release: loki - variant: headless -spec: - clusterIP: None - ports: - - port: 3100 - protocol: TCP - name: http-metrics - targetPort: http-metrics - selector: - app: loki - release: loki ---- -apiVersion: v1 -kind: Service -metadata: - name: loki - namespace: kuma - labels: - app: loki - release: loki - annotations: - {} -spec: - type: ClusterIP - ports: - - port: 3100 - protocol: TCP - name: http-metrics - targetPort: http-metrics - selector: - app: loki - release: loki ---- -apiVersion: apps/v1 -kind: DaemonSet -metadata: - name: loki-promtail - namespace: kuma - labels: - app: promtail - release: loki - annotations: - {} -spec: - selector: - matchLabels: - app: promtail - release: loki - updateStrategy: - {} - template: - metadata: - labels: - app: promtail - release: loki - annotations: - checksum/config: bce7daf9d5acc773342c4f42e700668ef8bdc8f34fa1499c766263fa0c1944e0 - prometheus.io/port: http-metrics - prometheus.io/scrape: "true" - spec: - serviceAccountName: loki-promtail - containers: - - name: promtail - image: "grafana/promtail:2.4.1" - imagePullPolicy: IfNotPresent - args: - - "-config.file=/etc/promtail/promtail.yaml" - - "-client.url=http://loki.kuma:3100/loki/api/v1/push" - volumeMounts: - - name: config - mountPath: /etc/promtail - - name: run - mountPath: /run/promtail - - mountPath: /var/lib/docker/containers - name: docker - readOnly: true - - mountPath: /var/log/pods - name: pods - readOnly: true - env: - - name: HOSTNAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - ports: - - containerPort: 3101 - name: http-metrics - securityContext: - readOnlyRootFilesystem: true - runAsGroup: 0 - runAsUser: 0 - readinessProbe: - failureThreshold: 5 - httpGet: - path: /ready - port: http-metrics - initialDelaySeconds: 10 - periodSeconds: 10 - successThreshold: 1 - timeoutSeconds: 1 - resources: - {} - nodeSelector: - {} - affinity: - {} - tolerations: - - effect: NoSchedule - key: node-role.kubernetes.io/master - operator: Exists - volumes: - - name: config - configMap: - name: loki-promtail - - name: run - hostPath: - path: /run/promtail - - hostPath: - path: /var/lib/docker/containers - name: docker - - hostPath: - path: /var/log/pods - name: pods ---- -apiVersion: apps/v1 -kind: StatefulSet -metadata: - name: loki - namespace: kuma - labels: - app: loki - release: loki - annotations: - {} -spec: - podManagementPolicy: OrderedReady - replicas: 1 - selector: - matchLabels: - app: loki - release: loki - serviceName: loki-headless - updateStrategy: - type: RollingUpdate - template: - metadata: - labels: - app: loki - name: loki - release: loki - annotations: - checksum/config: d4c94f4c6a73353362c10d2f844340cec8999b291ca88481ac162fbb5942617d - prometheus.io/port: http-metrics - prometheus.io/scrape: "true" - spec: - serviceAccountName: loki - securityContext: - fsGroup: 10001 - runAsGroup: 10001 - runAsNonRoot: true - runAsUser: 10001 - initContainers: - [] - containers: - - name: loki - image: "grafana/loki:2.4.1" - imagePullPolicy: IfNotPresent - args: - - "-config.file=/etc/loki/loki.yaml" - - "-target=all,table-manager" - volumeMounts: - - name: config - mountPath: /etc/loki - - name: storage - mountPath: "/data" - ports: - - name: http-metrics - containerPort: 3100 - protocol: TCP - livenessProbe: - httpGet: - path: /ready - port: http-metrics - initialDelaySeconds: 45 - readinessProbe: - httpGet: - path: /ready - port: http-metrics - initialDelaySeconds: 45 - resources: - {} - securityContext: - readOnlyRootFilesystem: true - nodeSelector: - {} - affinity: - {} - tolerations: - [] - terminationGracePeriodSeconds: 4800 - volumes: - - name: config - secret: - secretName: loki - - name: storage - emptyDir: {} diff --git a/app/kumactl/cmd/install/testdata/install-metrics.no-grafana.golden.yaml b/app/kumactl/cmd/install/testdata/install-metrics.no-grafana.golden.yaml deleted file mode 100644 index 7154db10a773..000000000000 --- a/app/kumactl/cmd/install/testdata/install-metrics.no-grafana.golden.yaml +++ /dev/null @@ -1,1009 +0,0 @@ - ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kuma-metrics - labels: - kuma.io/sidecar-injection: enabled - annotations: - kuma.io/mesh: default ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "kube-state-metrics" - app: prometheus - name: prometheus-kube-state-metrics - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ConfigMap -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -data: - alertmanager.yml: | - global: {} - receivers: - - name: default-receiver - route: - group_interval: 5m - group_wait: 10s - receiver: default-receiver - repeat_interval: 3h ---- -apiVersion: v1 -kind: ConfigMap -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server - namespace: kuma-metrics -data: - alerting_rules.yml: | - {} - alerts: | - {} - prometheus.yml: | - global: - evaluation_interval: 1m - scrape_interval: 10s - scrape_timeout: 10s - rule_files: - - /etc/config/recording_rules.yml - - /etc/config/alerting_rules.yml - - /etc/config/rules - - /etc/config/alerts - scrape_configs: - - job_name: prometheus - static_configs: - - targets: - - localhost:9090 - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - job_name: kubernetes-apiservers - kubernetes_sd_configs: - - role: endpoints - relabel_configs: - - action: keep - regex: default;kubernetes;https - source_labels: - - __meta_kubernetes_namespace - - __meta_kubernetes_service_name - - __meta_kubernetes_endpoint_port_name - scheme: https - tls_config: - ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt - insecure_skip_verify: true - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - job_name: kubernetes-nodes - kubernetes_sd_configs: - - role: node - relabel_configs: - - action: labelmap - regex: __meta_kubernetes_node_label_(.+) - - replacement: kubernetes.default.svc:443 - target_label: __address__ - - regex: (.+) - replacement: /api/v1/nodes/$1/proxy/metrics - source_labels: - - __meta_kubernetes_node_name - target_label: __metrics_path__ - scheme: https - tls_config: - ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt - insecure_skip_verify: true - - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - job_name: kubernetes-nodes-cadvisor - kubernetes_sd_configs: - - role: node - relabel_configs: - - action: labelmap - regex: __meta_kubernetes_node_label_(.+) - - replacement: kubernetes.default.svc:443 - target_label: __address__ - - regex: (.+) - replacement: /api/v1/nodes/$1/proxy/metrics/cadvisor - source_labels: - - __meta_kubernetes_node_name - target_label: __metrics_path__ - scheme: https - tls_config: - ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt - insecure_skip_verify: true - - job_name: kubernetes-service-endpoints - kubernetes_sd_configs: - - role: endpoints - relabel_configs: - - action: keep - regex: true - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_scrape - - action: replace - regex: (https?) - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_scheme - target_label: __scheme__ - - action: replace - regex: (.+) - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_path - target_label: __metrics_path__ - - action: replace - regex: ([^:]+)(?::\d+)?;(\d+) - replacement: $1:$2 - source_labels: - - __address__ - - __meta_kubernetes_service_annotation_prometheus_io_port - target_label: __address__ - - action: labelmap - regex: __meta_kubernetes_service_label_(.+) - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: kubernetes_namespace - - action: replace - source_labels: - - __meta_kubernetes_service_name - target_label: kubernetes_name - - action: replace - source_labels: - - __meta_kubernetes_pod_node_name - target_label: kubernetes_node - - job_name: kubernetes-service-endpoints-slow - kubernetes_sd_configs: - - role: endpoints - relabel_configs: - - action: keep - regex: true - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_scrape_slow - - action: replace - regex: (https?) - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_scheme - target_label: __scheme__ - - action: replace - regex: (.+) - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_path - target_label: __metrics_path__ - - action: replace - regex: ([^:]+)(?::\d+)?;(\d+) - replacement: $1:$2 - source_labels: - - __address__ - - __meta_kubernetes_service_annotation_prometheus_io_port - target_label: __address__ - - action: labelmap - regex: __meta_kubernetes_service_label_(.+) - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: kubernetes_namespace - - action: replace - source_labels: - - __meta_kubernetes_service_name - target_label: kubernetes_name - - action: replace - source_labels: - - __meta_kubernetes_pod_node_name - target_label: kubernetes_node - scrape_interval: 5m - scrape_timeout: 30s - - honor_labels: true - job_name: prometheus-pushgateway - kubernetes_sd_configs: - - role: service - relabel_configs: - - action: keep - regex: pushgateway - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_probe - - job_name: kubernetes-services - kubernetes_sd_configs: - - role: service - metrics_path: /probe - params: - module: - - http_2xx - relabel_configs: - - action: keep - regex: true - source_labels: - - __meta_kubernetes_service_annotation_prometheus_io_probe - - source_labels: - - __address__ - target_label: __param_target - - replacement: blackbox - target_label: __address__ - - source_labels: - - __param_target - target_label: instance - - action: labelmap - regex: __meta_kubernetes_service_label_(.+) - - source_labels: - - __meta_kubernetes_namespace - target_label: kubernetes_namespace - - source_labels: - - __meta_kubernetes_service_name - target_label: kubernetes_name - - job_name: kubernetes-pods - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: keep - regex: true - source_labels: - - __meta_kubernetes_pod_annotation_prometheus_io_scrape - - action: replace - regex: (.+) - source_labels: - - __meta_kubernetes_pod_annotation_prometheus_io_path - target_label: __metrics_path__ - - action: replace - regex: ([^:]+)(?::\d+)?;(\d+) - replacement: $1:$2 - source_labels: - - __address__ - - __meta_kubernetes_pod_annotation_prometheus_io_port - target_label: __address__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: kubernetes_namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: kubernetes_pod_name - - job_name: kubernetes-pods-slow - kubernetes_sd_configs: - - role: pod - relabel_configs: - - action: keep - regex: true - source_labels: - - __meta_kubernetes_pod_annotation_prometheus_io_scrape_slow - - action: replace - regex: (.+) - source_labels: - - __meta_kubernetes_pod_annotation_prometheus_io_path - target_label: __metrics_path__ - - action: replace - regex: ([^:]+)(?::\d+)?;(\d+) - replacement: $1:$2 - source_labels: - - __address__ - - __meta_kubernetes_pod_annotation_prometheus_io_port - target_label: __address__ - - action: labelmap - regex: __meta_kubernetes_pod_label_(.+) - - action: replace - source_labels: - - __meta_kubernetes_namespace - target_label: kubernetes_namespace - - action: replace - source_labels: - - __meta_kubernetes_pod_name - target_label: kubernetes_pod_name - scrape_interval: 5m - scrape_timeout: 30s - - job_name: 'kuma-dataplanes' - scrape_interval: "5s" - relabel_configs: - - source_labels: - - k8s_kuma_io_name - regex: "(.*)" - target_label: pod - - source_labels: - - k8s_kuma_io_namespace - regex: "(.*)" - target_label: namespace - - source_labels: - - __meta_kuma_mesh - regex: "(.*)" - target_label: mesh - - source_labels: - - __meta_kuma_dataplane - regex: "(.*)" - target_label: dataplane - - source_labels: - - __meta_kuma_service - regex: "(.*)" - target_label: service - - action: labelmap - regex: __meta_kuma_label_(.+) - kuma_sd_configs: - - server: http://kuma-control-plane.kuma-system:5676 - alerting: - alertmanagers: - - kubernetes_sd_configs: - - role: pod - tls_config: - ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token - relabel_configs: - - source_labels: [__meta_kubernetes_namespace] - regex: default - action: keep - - source_labels: [__meta_kubernetes_pod_label_app] - regex: prometheus - action: keep - - source_labels: [__meta_kubernetes_pod_label_component] - regex: alertmanager - action: keep - - source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_probe] - regex: .* - action: keep - - source_labels: [__meta_kubernetes_pod_container_port_number] - regex: - action: drop - recording_rules.yml: | - {} - rules: | - {} ---- -apiVersion: v1 -kind: PersistentVolumeClaim -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -spec: - accessModes: - - ReadWriteOnce - resources: - requests: - storage: "2Gi" ---- -apiVersion: v1 -kind: PersistentVolumeClaim -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server - namespace: kuma-metrics -spec: - accessModes: - - ReadWriteOnce - resources: - requests: - storage: "8Gi" ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server -rules: - - apiGroups: - - "" - resources: - - nodes - - nodes/proxy - - nodes/metrics - - services - - endpoints - - pods - - ingresses - - configmaps - verbs: - - get - - list - - watch - - apiGroups: - - "extensions" - resources: - - ingresses/status - - ingresses - verbs: - - get - - list - - watch - - nonResourceURLs: - - "/metrics" - verbs: - - get ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - labels: - component: "kube-state-metrics" - app: prometheus - name: prometheus-kube-state-metrics -rules: - - apiGroups: - - "" - resources: - - namespaces - - nodes - - persistentvolumeclaims - - pods - - services - - resourcequotas - - replicationcontrollers - - limitranges - - persistentvolumeclaims - - persistentvolumes - - endpoints - - secrets - - configmaps - verbs: - - list - - watch - - apiGroups: - - extensions - resources: - - daemonsets - - deployments - - ingresses - - replicasets - verbs: - - list - - watch - - apiGroups: - - apps - resources: - - daemonsets - - deployments - - statefulsets - - replicasets - verbs: - - get - - list - - watch - - apiGroups: - - batch - resources: - - cronjobs - - jobs - verbs: - - list - - watch - - apiGroups: - - autoscaling - resources: - - horizontalpodautoscalers - verbs: - - list - - watch - - apiGroups: - - policy - resources: - - poddisruptionbudgets - verbs: - - list - - watch - - apiGroups: - - storage.k8s.io - resources: - - storageclasses - - volumeattachments - verbs: - - list - - watch - - apiGroups: - - certificates.k8s.io - resources: - - certificatesigningrequests - verbs: - - list - - watch - - apiGroups: - - networking.k8s.io - resources: - - networkpolicies - verbs: - - list - - watch - - apiGroups: - - admissionregistration.k8s.io - resources: - - validatingwebhookconfigurations - - mutatingwebhookconfigurations - verbs: - - list - - watch ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - labels: - component: "kube-state-metrics" - app: prometheus - name: prometheus-kube-state-metrics -subjects: - - kind: ServiceAccount - name: prometheus-kube-state-metrics - namespace: kuma-metrics -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-kube-state-metrics ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -subjects: - - kind: ServiceAccount - name: prometheus-pushgateway - namespace: kuma-metrics -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-pushgateway ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server -subjects: - - kind: ServiceAccount - name: prometheus-server - namespace: kuma-metrics -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-server ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -subjects: - - kind: ServiceAccount - name: prometheus-alertmanager - namespace: kuma-metrics -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-alertmanager ---- -apiVersion: v1 -kind: Service -metadata: - annotations: - prometheus.io/scrape: "true" - labels: - component: "kube-state-metrics" - app: prometheus - name: prometheus-kube-state-metrics - namespace: kuma-metrics -spec: - clusterIP: None - ports: - - name: http - port: 80 - protocol: TCP - targetPort: 8080 - - name: telemetry - port: 81 - protocol: TCP - targetPort: 8081 - selector: - component: "kube-state-metrics" - app: prometheus - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service -metadata: - annotations: - prometheus.io/scrape: "true" - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma-metrics -spec: - clusterIP: None - ports: - - name: metrics - port: 9100 - protocol: TCP - targetPort: 9100 - selector: - component: "node-exporter" - app: prometheus - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service -metadata: - annotations: - prometheus.io/probe: pushgateway - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma-metrics -spec: - ports: - - name: http - port: 9091 - protocol: TCP - targetPort: 9091 - selector: - component: "pushgateway" - app: prometheus - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server - namespace: kuma-metrics -spec: - ports: - - name: http - port: 80 - protocol: TCP - targetPort: 9090 - selector: - component: "server" - app: prometheus - sessionAffinity: None - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -spec: - ports: - - name: http - port: 80 - protocol: TCP - targetPort: 9093 - selector: - component: alertmanager - app: prometheus - sessionAffinity: None - type: "ClusterIP" ---- -apiVersion: apps/v1 -kind: DaemonSet -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "node-exporter" - app: prometheus - updateStrategy: - type: RollingUpdate - template: - metadata: - labels: - component: "node-exporter" - app: prometheus - kuma.io/sidecar-injection: "disabled" # disabled for now, injecting DP crashes K8S cluster - spec: - serviceAccountName: prometheus-node-exporter - containers: - - name: prometheus-node-exporter - image: "prom/node-exporter:v1.3.1" - imagePullPolicy: "IfNotPresent" - args: - - --path.procfs=/host/proc - - --path.sysfs=/host/sys - ports: - - name: metrics - containerPort: 9100 - hostPort: 9100 - resources: - {} - volumeMounts: - - name: proc - mountPath: /host/proc - readOnly: true - - name: sys - mountPath: /host/sys - readOnly: true - hostNetwork: true - hostPID: true - volumes: - - name: proc - hostPath: - path: /proc - - name: sys - hostPath: - path: /sys ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "kube-state-metrics" - app: prometheus - name: prometheus-kube-state-metrics - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "kube-state-metrics" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "kube-state-metrics" - app: prometheus - spec: - serviceAccountName: prometheus-kube-state-metrics - containers: - - name: prometheus-kube-state-metrics - image: "quay.io/coreos/kube-state-metrics:v1.9.8" - imagePullPolicy: "IfNotPresent" - ports: - - name: metrics - containerPort: 8080 - - name: telemetry - containerPort: 8081 - resources: - {} - securityContext: - runAsUser: 65534 ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "pushgateway" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "pushgateway" - app: prometheus - spec: - serviceAccountName: prometheus-pushgateway - containers: - - name: prometheus-pushgateway - image: "prom/pushgateway:v1.4.2" - imagePullPolicy: "IfNotPresent" - args: - ports: - - containerPort: 9091 - resources: - {} - securityContext: - runAsUser: 65534 ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "server" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "server" - app: prometheus - annotations: - kuma.io/direct-access-services: "*" - spec: - serviceAccountName: prometheus-server - containers: - - name: prometheus-server-configmap-reload - image: "jimmidyson/configmap-reload:v0.6.1" - imagePullPolicy: "IfNotPresent" - args: - - --volume-dir=/etc/config - - --webhook-url=http://127.0.0.1:9090/-/reload - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - readOnly: true - - name: prometheus-server - image: "prom/prometheus:v2.32.1" - imagePullPolicy: "IfNotPresent" - args: - - --storage.tsdb.retention.time=15d - - --config.file=/etc/config/prometheus.yml - - --storage.tsdb.path=/data - - --web.console.libraries=/etc/prometheus/console_libraries - - --web.console.templates=/etc/prometheus/consoles - - --web.enable-lifecycle - ports: - - containerPort: 9090 - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - - name: storage-volume - mountPath: /data - subPath: "" - securityContext: - fsGroup: 65534 - runAsGroup: 65534 - runAsUser: 65534 - terminationGracePeriodSeconds: 300 - volumes: - - name: config-volume - configMap: - name: prometheus-server - - name: storage-volume - persistentVolumeClaim: - claimName: prometheus-server ---- -# Source: prometheus/templates/alertmanager-deployment.yaml -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "alertmanager" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "alertmanager" - app: prometheus - spec: - serviceAccountName: prometheus-alertmanager - containers: - - name: prometheus-alertmanager - image: "prom/alertmanager:v0.23.0" - imagePullPolicy: "IfNotPresent" - env: - - name: POD_IP - valueFrom: - fieldRef: - apiVersion: v1 - fieldPath: status.podIP - args: - - --config.file=/etc/config/alertmanager.yml - - --storage.path=/data - - --cluster.advertise-address=$(POD_IP):6783 - - --web.external-url=http://localhost:9093 - ports: - - containerPort: 9093 - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - - name: storage-volume - mountPath: "/data" - subPath: "" - - name: prometheus-alertmanager-configmap-reload - image: "jimmidyson/configmap-reload:v0.6.1" - imagePullPolicy: "IfNotPresent" - args: - - --volume-dir=/etc/config - - --webhook-url=http://127.0.0.1:9093/-/reload - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - readOnly: true - securityContext: - fsGroup: 65534 - runAsGroup: 65534 - runAsUser: 65534 - volumes: - - name: config-volume - configMap: - name: prometheus-alertmanager - - name: storage-volume - persistentVolumeClaim: - claimName: prometheus-alertmanager diff --git a/app/kumactl/cmd/install/testdata/install-observability.defaults.golden.yaml b/app/kumactl/cmd/install/testdata/install-observability.defaults.golden.yaml new file mode 100644 index 000000000000..55b3714c7f2c --- /dev/null +++ b/app/kumactl/cmd/install/testdata/install-observability.defaults.golden.yaml @@ -0,0 +1,12299 @@ + +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability + labels: + kuma.io/sidecar-injection: enabled + annotations: + kuma.io/mesh: default +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: grafana + namespace: mesh-observability + labels: + app: grafana + annotations: + seccomp.security.alpha.kubernetes.io/allowedProfileNames: 'docker/default' + seccomp.security.alpha.kubernetes.io/defaultProfileName: 'docker/default' + apparmor.security.beta.kubernetes.io/allowedProfileNames: 'runtime/default' + apparmor.security.beta.kubernetes.io/defaultProfileName: 'runtime/default' +spec: + privileged: false + allowPrivilegeEscalation: false + requiredDropCapabilities: + # Default set from Docker, without DAC_OVERRIDE or CHOWN + - FOWNER + - FSETID + - KILL + - SETGID + - SETUID + - SETPCAP + - NET_BIND_SERVICE + - NET_RAW + - SYS_CHROOT + - MKNOD + - AUDIT_WRITE + - SETFCAP + volumes: + - 'configMap' + - 'emptyDir' + - 'projected' + - 'secret' + - 'downwardAPI' + - 'persistentVolumeClaim' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'RunAsAny' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'RunAsAny' + fsGroup: + rule: 'RunAsAny' + readOnlyRootFilesystem: false +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: mesh-observability +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: grafana + name: grafana + namespace: mesh-observability +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: grafana + namespace: mesh-observability + labels: + app: grafana +data: + grafana.ini: | + [analytics] + check_for_updates = true + [grafana_net] + url = https://grafana.net + [log] + mode = console + [paths] + data = /var/lib/grafana/data + logs = /var/log/grafana + plugins = /var/lib/grafana/plugins + provisioning = /etc/grafana/provisioning + [plugins] + # Required until we have grafana sign our plugin. + allow_loading_unsigned_plugins = "kumahq-kuma-datasource" +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-datasource + namespace: mesh-observability + labels: + app: grafana +data: + datasource.yaml: | + # config file version + apiVersion: 1 + + # list of datasources that should be deleted from the database + deleteDatasources: + - name: Prometheus + orgId: 1 + + # list of datasources to insert/update depending + # whats available in the database + datasources: + # name of the datasource. Required + - name: Prometheus + uid: prometheus + # datasource type. Required + type: prometheus + # access mode. direct or proxy. Required + access: proxy + # org id. will default to orgId 1 if not specified + orgId: 1 + # url + url: http://prometheus-server.mesh-observability + # database password, if used + password: + # database user, if used + user: + # database name, if used + database: + # enable/disable basic auth + basicAuth: false + # basic auth username, if used + basicAuthUser: + # basic auth password, if used + basicAuthPassword: + # enable/disable with credentials headers + withCredentials: + # mark as default datasource. Max one per org + isDefault: true + # fields that will be converted to json and stored in json_data + jsonData: + graphiteVersion: "1.1" + tlsAuth: false + tlsAuthWithCACert: false + # json object of data that will be encrypted. + secureJsonData: + tlsCACert: "..." + tlsClientCert: "..." + tlsClientKey: "..." + version: 1 + # allow users to edit datasources from the UI. + editable: true + - name: Kuma + uid: kuma + editable: true + type: kumahq-kuma-datasource + url: http://kuma-control-plane.kuma-system:5681 + jsonData: + prometheusDataSourceId: "1" + - name: Jaeger + type: jaeger + access: proxy + editable: true + uid: jaeger + url: http://jaeger-query.mesh-observability + jsonData: + tracesToLogs: + datasourceUid: loki + tags: ["node_id"] + - name: Loki + type: loki + access: proxy + editable: true + uid: loki + url: http://loki.mesh-observability:3100 + jsonData: + derivedFields: + - datasourceUid: jaeger + matcherRegex: '"([0-9a-f]{16})"' + name: "traceId" + url: '$${__value.raw}' +--- +apiVersion: v1 +kind: ConfigMap +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +data: + alerting_rules.yml: | + {} + alerts: | + {} + prometheus.yml: | + global: + evaluation_interval: 1m + scrape_interval: 10s + scrape_timeout: 10s + rule_files: + - /etc/config/recording_rules.yml + - /etc/config/alerting_rules.yml + - /etc/config/rules + - /etc/config/alerts + scrape_configs: + - job_name: prometheus + static_configs: + - targets: + - localhost:9090 + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-apiservers + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: default;kubernetes;https + source_labels: + - __meta_kubernetes_namespace + - __meta_kubernetes_service_name + - __meta_kubernetes_endpoint_port_name + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-nodes + kubernetes_sd_configs: + - role: node + relabel_configs: + - action: labelmap + regex: __meta_kubernetes_node_label_(.+) + - replacement: kubernetes.default.svc:443 + target_label: __address__ + - regex: (.+) + replacement: /api/v1/nodes/$1/proxy/metrics + source_labels: + - __meta_kubernetes_node_name + target_label: __metrics_path__ + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-nodes-cadvisor + kubernetes_sd_configs: + - role: node + relabel_configs: + - action: labelmap + regex: __meta_kubernetes_node_label_(.+) + - replacement: kubernetes.default.svc:443 + target_label: __address__ + - regex: (.+) + replacement: /api/v1/nodes/$1/proxy/metrics/cadvisor + source_labels: + - __meta_kubernetes_node_name + target_label: __metrics_path__ + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - job_name: kubernetes-service-endpoints + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scrape + - action: replace + regex: (https?) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scheme + target_label: __scheme__ + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_service_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - action: replace + source_labels: + - __meta_kubernetes_pod_node_name + target_label: kubernetes_node + - job_name: kubernetes-service-endpoints-slow + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scrape_slow + - action: replace + regex: (https?) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scheme + target_label: __scheme__ + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_service_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - action: replace + source_labels: + - __meta_kubernetes_pod_node_name + target_label: kubernetes_node + scrape_interval: 5m + scrape_timeout: 30s + - honor_labels: true + job_name: prometheus-pushgateway + kubernetes_sd_configs: + - role: service + relabel_configs: + - action: keep + regex: pushgateway + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_probe + - job_name: kubernetes-services + kubernetes_sd_configs: + - role: service + metrics_path: /probe + params: + module: + - http_2xx + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_probe + - source_labels: + - __address__ + target_label: __param_target + - replacement: blackbox + target_label: __address__ + - source_labels: + - __param_target + target_label: instance + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - job_name: kubernetes-pods + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_scrape + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_pod_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: kubernetes_pod_name + - job_name: kubernetes-pods-slow + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_scrape_slow + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_pod_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: kubernetes_pod_name + scrape_interval: 5m + scrape_timeout: 30s + - job_name: 'kuma-dataplanes' + scrape_interval: "5s" + relabel_configs: + - source_labels: + - k8s_kuma_io_name + regex: "(.*)" + target_label: pod + - source_labels: + - k8s_kuma_io_namespace + regex: "(.*)" + target_label: namespace + - source_labels: + - __meta_kuma_mesh + regex: "(.*)" + target_label: mesh + - source_labels: + - __meta_kuma_dataplane + regex: "(.*)" + target_label: dataplane + - source_labels: + - __meta_kuma_service + regex: "(.*)" + target_label: service + - action: labelmap + regex: __meta_kuma_label_(.+) + kuma_sd_configs: + - server: http://kuma-control-plane.kuma-system:5676 + alerting: + alertmanagers: + - kubernetes_sd_configs: + - role: pod + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + relabel_configs: + - source_labels: [__meta_kubernetes_namespace] + regex: default + action: keep + - source_labels: [__meta_kubernetes_pod_label_app] + regex: prometheus + action: keep + - source_labels: [__meta_kubernetes_pod_label_component] + regex: alertmanager + action: keep + - source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_probe] + regex: .* + action: keep + - source_labels: [__meta_kubernetes_pod_container_port_number] + regex: + action: drop + recording_rules.yml: | + {} + rules: | + {} +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards + namespace: mesh-observability + labels: + app: grafana +data: + dashboards.yaml: | + apiVersion: 1 + + providers: + - name: 'Prometheus' + orgId: 1 + folder: '' + type: file + disableDeletion: false + editable: true + options: + path: /etc/grafana/provisioning/dashboards +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-0 + namespace: mesh-observability + labels: + app: grafana +data: + kuma-dataplane.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "description": "Statistics of a single Dataplane in Kuma Service Mesh", + "editable": true, + "gnetId": 11775, + "graphTooltip": 0, + "id": 3, + "iteration": 1619601583109, + "links": [], + "panels": [ + { + "collapsed": false, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 22, + "panels": [], + "title": "Dataplane", + "type": "row" + }, + { + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": {}, + "displayName": "", + "mappings": [ + { + "from": "", + "id": 1, + "operator": "", + "text": "LIVE", + "to": "", + "type": 1, + "value": "1" + }, + { + "from": "", + "id": 2, + "operator": "", + "text": "OFF", + "to": "", + "type": 1, + "value": "0" + } + ], + "max": 1, + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 1 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 5, + "x": 0, + "y": 1 + }, + "id": 16, + "interval": "", + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": false, + "text": {} + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(envoy_server_live{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"} OR on() vector(0))", + "interval": "", + "intervalFactor": 1, + "legendFormat": "", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Status", + "type": "gauge" + }, + { + "cacheTimeout": null, + "colorBackground": false, + "colorPrefix": false, + "colorValue": false, + "colors": [ + "#299c46", + "rgba(237, 129, 40, 0.89)", + "#d44a3a" + ], + "datasource": "Prometheus", + "decimals": 2, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "format": "s", + "gauge": { + "maxValue": 100, + "minValue": 0, + "show": false, + "thresholdLabels": false, + "thresholdMarkers": true + }, + "gridPos": { + "h": 7, + "w": 4, + "x": 5, + "y": 1 + }, + "id": 18, + "interval": null, + "links": [], + "mappingType": 1, + "mappingTypes": [ + { + "name": "value to text", + "value": 1 + }, + { + "name": "range to text", + "value": 2 + } + ], + "maxDataPoints": 100, + "nullPointMode": "connected", + "nullText": null, + "postfix": "", + "postfixFontSize": "50%", + "prefix": "", + "prefixFontSize": "50%", + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "sparkline": { + "fillColor": "rgba(31, 118, 189, 0.18)", + "full": false, + "lineColor": "rgb(31, 120, 193)", + "show": false, + "ymax": null, + "ymin": null + }, + "tableColumn": "", + "targets": [ + { + "expr": "envoy_server_uptime{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "refId": "A" + } + ], + "thresholds": "", + "timeFrom": null, + "timeShift": null, + "title": "Uptime", + "type": "singlestat", + "valueFontSize": "80%", + "valueMaps": [ + { + "op": "=", + "text": "N/A", + "value": "null" + } + ], + "valueName": "max" + }, + { + "cacheTimeout": null, + "colorBackground": false, + "colorValue": false, + "colors": [ + "#299c46", + "rgba(237, 129, 40, 0.89)", + "#d44a3a" + ], + "datasource": "Prometheus", + "decimals": 2, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "format": "bytes", + "gauge": { + "maxValue": 100, + "minValue": 0, + "show": false, + "thresholdLabels": false, + "thresholdMarkers": true + }, + "gridPos": { + "h": 7, + "w": 4, + "x": 9, + "y": 1 + }, + "id": 25, + "interval": null, + "links": [], + "mappingType": 1, + "mappingTypes": [ + { + "name": "value to text", + "value": 1 + }, + { + "name": "range to text", + "value": 2 + } + ], + "maxDataPoints": 100, + "nullPointMode": "connected", + "nullText": null, + "postfix": "", + "postfixFontSize": "50%", + "prefix": "", + "prefixFontSize": "50%", + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "sparkline": { + "fillColor": "rgba(31, 118, 189, 0.18)", + "full": false, + "lineColor": "rgb(31, 120, 193)", + "show": false, + "ymax": null, + "ymin": null + }, + "tableColumn": "", + "targets": [ + { + "expr": "envoy_server_memory_heap_size{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "refId": "A" + } + ], + "thresholds": "", + "timeFrom": null, + "timeShift": null, + "title": "Heap size", + "type": "singlestat", + "valueFontSize": "80%", + "valueMaps": [ + { + "op": "=", + "text": "N/A", + "value": "null" + } + ], + "valueName": "avg" + }, + { + "cacheTimeout": null, + "colorBackground": false, + "colorValue": false, + "colors": [ + "#299c46", + "rgba(237, 129, 40, 0.89)", + "#d44a3a" + ], + "datasource": "Prometheus", + "decimals": 2, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "format": "bytes", + "gauge": { + "maxValue": 100, + "minValue": 0, + "show": false, + "thresholdLabels": false, + "thresholdMarkers": true + }, + "gridPos": { + "h": 7, + "w": 4, + "x": 13, + "y": 1 + }, + "id": 26, + "interval": null, + "links": [], + "mappingType": 1, + "mappingTypes": [ + { + "name": "value to text", + "value": 1 + }, + { + "name": "range to text", + "value": 2 + } + ], + "maxDataPoints": 100, + "nullPointMode": "connected", + "nullText": null, + "postfix": "", + "postfixFontSize": "50%", + "prefix": "", + "prefixFontSize": "50%", + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "sparkline": { + "fillColor": "rgba(31, 118, 189, 0.18)", + "full": false, + "lineColor": "rgb(31, 120, 193)", + "show": false, + "ymax": null, + "ymin": null + }, + "tableColumn": "", + "targets": [ + { + "expr": "envoy_server_memory_allocated{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "refId": "A" + } + ], + "thresholds": "", + "timeFrom": null, + "timeShift": null, + "title": "Memory allocated", + "type": "singlestat", + "valueFontSize": "80%", + "valueMaps": [ + { + "op": "=", + "text": "N/A", + "value": "null" + } + ], + "valueName": "avg" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Note that if Control Plane does not sent FIN segment, Dataplanes can still think that connection is up waiting for new update even that Control Plane is down.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 7, + "x": 17, + "y": 1 + }, + "hiddenSeries": false, + "id": 20, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_control_plane_connected_state{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "legendFormat": "Connected", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection to the Control Plane", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 8 + }, + "id": 10, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 2 + }, + "hiddenSeries": false, + "id": 6, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_upstream_cx_active{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Connections to this Dataplane", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 2 + }, + "hiddenSeries": false, + "id": 4, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_connect_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection time (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 2 + }, + "hiddenSeries": false, + "id": 32, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_length_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection length (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 10 + }, + "hiddenSeries": false, + "id": 31, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_tx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes received from requests", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 10 + }, + "hiddenSeries": false, + "id": 13, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_rx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes sent in responses", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": "", + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if TrafficPermission policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 10 + }, + "hiddenSeries": false, + "id": 28, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_rbac_allowed{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Allowed - {{listener}}", + "refId": "A" + }, + { + "expr": "irate(envoy_rbac_shadow_allowed{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Shadow allowed - {{listener}}", + "refId": "D" + }, + { + "expr": "irate(envoy_rbac_denied{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Denied - {{listener}}", + "refId": "B" + }, + { + "expr": "irate(envoy_rbac_shadow_denied{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Shadow denied - {{listener}}", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic permissions", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 18 + }, + "hiddenSeries": false, + "id": 30, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": true, + "values": true + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "hide": true, + "legendFormat": "connection destroyed by the client - {{envoy_cluster_name}}", + "refId": "A" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_connect_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "connection timeout - {{envoy_cluster_name}}", + "refId": "B" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "hide": true, + "legendFormat": "connection destroyed by local Envoy - {{envoy_cluster_name}}", + "refId": "C" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_failure_eject{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "pending failure ejection - {{envoy_cluster_name}}", + "refId": "D" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "pending overflow - {{envoy_cluster_name}}", + "refId": "E" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "request timeout - {{envoy_cluster_name}}", + "refId": "F" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_rx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "response reset by the client - {{envoy_cluster_name}}", + "refId": "G" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_tx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "request reset by local Envoy - {{envoy_cluster_name}}", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Incoming traffic", + "type": "row" + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 9 + }, + "id": 12, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 10 + }, + "hiddenSeries": false, + "id": 8, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_upstream_cx_active{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}", + "interval": "", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Connections to other Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:203", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:204", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 10 + }, + "hiddenSeries": false, + "id": 33, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_connect_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection time (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 10 + }, + "hiddenSeries": false, + "id": 34, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_length_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection length (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 18 + }, + "hiddenSeries": false, + "id": 14, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_rx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes received from other Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "bytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 18 + }, + "hiddenSeries": false, + "id": 3, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_tx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes sent to other Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "bytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "columns": [], + "datasource": "Prometheus", + "description": "Data is only available if TrafficPermission policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fontSize": "100%", + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 18 + }, + "id": 24, + "pageSize": null, + "showHeader": true, + "sort": { + "col": 0, + "desc": true + }, + "styles": [ + { + "alias": "Time", + "align": "auto", + "dateFormat": "YYYY-MM-DD HH:mm:ss", + "pattern": "Time", + "type": "date" + }, + { + "alias": "", + "align": "auto", + "colorMode": null, + "colors": [ + "rgba(245, 54, 54, 0.9)", + "rgba(237, 129, 40, 0.89)", + "rgba(50, 172, 45, 0.97)" + ], + "decimals": 2, + "pattern": "/.*/", + "thresholds": [ + "" + ], + "type": "number", + "unit": "short" + } + ], + "targets": [ + { + "expr": "envoy_cluster_ssl_handshake{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"} > 0", + "format": "time_series", + "interval": "", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Secured destinations by mTLS", + "transform": "timeseries_aggregations", + "type": "table-old" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 26 + }, + "hiddenSeries": false, + "id": 29, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "hide": true, + "legendFormat": "destroyed by remote Envoy - {{envoy_cluster_name}}", + "refId": "A" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_connect_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "connection timeout - {{envoy_cluster_name}}", + "refId": "B" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "hide": true, + "legendFormat": "destroyed by local Envoy - {{envoy_cluster_name}}", + "refId": "C" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_failure_eject{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "pending failure ejection - {{envoy_cluster_name}}", + "refId": "D" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "pending overflow - {{envoy_cluster_name}}", + "refId": "E" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "request timeout - {{envoy_cluster_name}}", + "refId": "F" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_rx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "request reset by other Envoy - {{envoy_cluster_name}}", + "refId": "G" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_tx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "response reset by local Envoy - {{envoy_cluster_name}}", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Outgoing traffic", + "type": "row" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 10 + }, + "id": 49, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 11 + }, + "hiddenSeries": false, + "id": 51, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p99", + "refId": "B" + }, + { + "expr": "sum(histogram_quantile(0.95, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p95", + "refId": "A" + }, + { + "expr": "sum(histogram_quantile(0.50, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p50", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 11 + }, + "hiddenSeries": false, + "id": 53, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Incoming", + "refId": "B" + }, + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",dataplane=\"$dataplane\",envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\", envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Outgoing", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 11 + }, + "hiddenSeries": false, + "id": 55, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",dataplane=\"$dataplane\", envoy_cluster_name=~\"localhost_.*\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Incoming {{envoy_response_code_class}}xx", + "refId": "A" + }, + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",dataplane=\"$dataplane\", envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\", envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Outgoing {{envoy_response_code_class}}xx", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Status codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 20 + }, + "id": 36, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 4 + }, + "hiddenSeries": false, + "id": 38, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_health_check_healthy{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks - healthy service instances", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:353", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:354", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 4 + }, + "hiddenSeries": false, + "id": 39, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_membership_total{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"} - envoy_cluster_health_check_healthy{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks - failing service instances", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:384", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:385", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Health Checks", + "type": "row" + }, + { + "collapsed": true, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 21 + }, + "id": 45, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "description": "Total times that the cluster’s connection circuit breaker overflowed", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 12 + }, + "hiddenSeries": false, + "id": 43, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "interval": "", + "legendFormat": "Connection overflow", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Pending request overflow", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_retry_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Retry overflow", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Thresholds Overflow", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:72", + "format": "ops", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:73", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied. Note that passive health checks are executed on healthy instances marked by active health checks.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 12 + }, + "hiddenSeries": false, + "id": 47, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "1 - sum(envoy_cluster_outlier_detection_ejections_active{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}) / sum(envoy_cluster_membership_total{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "interval": "", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Outlier detection", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:312", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "$$hashKey": "object:313", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Circuit Breakers", + "type": "row" + } + ], + "schemaVersion": 27, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "Prometheus-mesh-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "kuma-demo-backend-v0-56db47c579-pjztb.kuma-demo", + "value": "kuma-demo-backend-v0-56db47c579-pjztb.kuma-demo" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, dataplane)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Dataplane", + "multi": false, + "name": "dataplane", + "options": [], + "query": { + "query": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, dataplane)", + "refId": "Prometheus-dataplane-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma Dataplane", + "uid": "-SZYLFyWz", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-1 + namespace: mesh-observability + labels: + app: grafana +data: + kuma-mesh.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "description": "Statistics of the single Mesh in Kuma Service Mesh", + "editable": true, + "gnetId": 11774, + "graphTooltip": 0, + "id": 4, + "iteration": 1617606288684, + "links": [], + "panels": [ + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 30, + "panels": [], + "title": "Service Map", + "type": "row" + }, + { + "datasource": "Kuma", + "gridPos": { + "h": 14, + "w": 24, + "x": 0, + "y": 1 + }, + "id": 32, + "interval": "1m", + "targets": [ + { + "hide": false, + "mesh": "$mesh", + "queryType": "mesh-graph", + "refId": "A" + } + ], + "title": "Service Map", + "type": "nodeGraph" + }, + { + "collapsed": false, + "datasource": null, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 15 + }, + "id": 23, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 16 + }, + "hiddenSeries": false, + "id": 25, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",envoy_cluster_name=~\"localhost_.*\"}[1m]))) by (kuma_io_service)", + "hide": false, + "interval": "", + "legendFormat": "{{ kuma_io_service }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 16 + }, + "hiddenSeries": false, + "id": 26, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",envoy_cluster_name=~\"localhost_.*\"}[1m])) by (kuma_io_service)", + "hide": false, + "interval": "", + "legendFormat": "{{ kuma_io_service }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 16 + }, + "hiddenSeries": false, + "id": 28, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",envoy_cluster_name=~\"localhost_.*\", envoy_response_code_class=~\"4|5\"}[1m])) by (kuma_io_service,envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "{{ kuma_io_service}} {{ envoy_response_code_class }}xx", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Error Status Codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 25 + }, + "id": 16, + "panels": [], + "title": "Health Checks", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 24, + "x": 0, + "y": 26 + }, + "hiddenSeries": false, + "id": 9, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "((sum(rate(envoy_cluster_health_check_success{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m])) / sum(rate(envoy_cluster_health_check_attempt{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))))", + "legendFormat": "Success rate", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": null, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 33 + }, + "id": 19, + "panels": [], + "title": "Circuit Breakers", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "description": "Total times that the cluster’s connection circuit breaker overflowed", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 34 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "interval": "", + "legendFormat": "Connection overflow", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Pending request overflow", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_retry_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Retry overflow", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Thresholds Overflow", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:72", + "format": "ops", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:73", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied. Note that passive health checks are executed on healthy instances marked by active health checks.", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 34 + }, + "hiddenSeries": false, + "id": 17, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "1 - sum(envoy_cluster_outlier_detection_ejections_active{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}) / sum(envoy_cluster_membership_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "interval": "", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Outlier detection", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 42 + }, + "id": 12, + "panels": [], + "title": "Data Plane Proxies", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 12, + "x": 0, + "y": 43 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:224", + "alias": "Off", + "color": "#F2495C" + }, + { + "$$hashKey": "object:225", + "alias": "Live", + "color": "#73BF69" + } + ], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "count(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}) - sum(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "hide": false, + "legendFormat": "Off", + "refId": "B" + }, + { + "expr": "sum(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "hide": false, + "legendFormat": "Live", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:238", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:239", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Note that if Control Plane does not sent FIN segment, Dataplanes can still think that connection is up waiting for new update even that Control Plane is down.", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 12, + "x": 12, + "y": 43 + }, + "hiddenSeries": false, + "id": 3, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:293", + "alias": "Disconnected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:294", + "alias": "Connected", + "color": "#73BF69" + } + ], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "count(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}) - sum(envoy_control_plane_connected_state{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "legendFormat": "Disconnected", + "refId": "B" + }, + { + "expr": "sum(envoy_control_plane_connected_state{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "legendFormat": "Connected", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Dataplanes connected to the Control Plane", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:307", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:308", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 50 + }, + "hiddenSeries": false, + "id": 5, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_tx_bytes_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Sent", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_rx_bytes_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Received", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes flowing through Envoy", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 50 + }, + "hiddenSeries": false, + "id": 7, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": false, + "hideZero": false, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by the client", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_connect_timeout{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Connection timeout", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by local Envoy", + "refId": "C" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_failure_eject{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Pending failure ejection", + "refId": "D" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Pending overflow", + "refId": "E" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_timeout{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Request timeout", + "refId": "F" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_rx_reset{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Response reset", + "refId": "G" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_tx_reset{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Request reset", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "refresh": "5s", + "schemaVersion": 30, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "Prometheus-mesh-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma Mesh", + "uid": "GW0DqjsWz", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-2 + namespace: mesh-observability + labels: + app: grafana +data: + kuma-service-to-service.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "description": "Statistics of the traffic between services in Kuma Service Mesh", + "editable": true, + "gnetId": 11776, + "graphTooltip": 0, + "id": 4, + "iteration": 1617905663030, + "links": [], + "panels": [ + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 10, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 1 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_tx_bytes_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Bytes sent", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_rx_bytes_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Bytes received", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic from source service perspective", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 1 + }, + "hiddenSeries": false, + "id": 14, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": false, + "hideZero": false, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by the client", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_connect_timeout{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Connection timeout", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by local Envoy", + "refId": "C" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_failure_eject{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Pending failure ejection", + "refId": "D" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Pending overflow", + "refId": "E" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_timeout{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Request timeout", + "refId": "F" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_rx_reset{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Response reset", + "refId": "G" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_tx_reset{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Request reset", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors from source service perspective", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 9 + }, + "hiddenSeries": false, + "id": 4, + "interval": "", + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(envoy_cluster_upstream_cx_active{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "legendFormat": "Connections", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Connections between services", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 9 + }, + "hiddenSeries": false, + "id": 6, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_connect_ms_bucket{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])))", + "legendFormat": "Time", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection time (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 9 + }, + "hiddenSeries": false, + "id": 8, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_length_ms_bucket{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])))", + "legendFormat": "Time", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection length (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Traffic", + "type": "row" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 1 + }, + "id": 25, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "color": {}, + "custom": {}, + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 2 + }, + "hiddenSeries": false, + "id": 27, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_service=\"$source_service\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=\"$destination_cluster\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p99", + "refId": "A" + }, + { + "expr": "max(histogram_quantile(0.95, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_service=\"$source_service\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=\"$destination_cluster\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p95", + "refId": "C" + }, + { + "expr": "max(histogram_quantile(0.50, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_service=\"$source_service\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=\"$destination_cluster\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p50", + "refId": "D" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:631", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:632", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 2 + }, + "hiddenSeries": false, + "id": 29, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_service=\"$source_service\", envoy_cluster_name=\"$destination_cluster\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Requests", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:429", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:430", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 2 + }, + "hiddenSeries": false, + "id": 31, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_service=\"$source_service\", envoy_cluster_name=\"$destination_cluster\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "{{envoy_response_code_class}}xx", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Status codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 11 + }, + "id": 18, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 24, + "x": 0, + "y": 12 + }, + "hiddenSeries": false, + "id": 12, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(envoy_cluster_health_check_healthy{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}) / sum(envoy_cluster_membership_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:347", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "$$hashKey": "object:348", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Health Checks", + "type": "row" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 12 + }, + "id": 23, + "panels": [], + "title": "Circuit Breakers", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "description": "Total times that the cluster’s connection circuit breaker overflowed", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 13 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "interval": "", + "legendFormat": "Connection overflow", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Pending request overflow", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_retry_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Retry overflow", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Thresholds Overflow", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:72", + "format": "ops", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:73", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if CircuitBreaker policy is applied", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 13 + }, + "hiddenSeries": false, + "id": 19, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "1 - sum(envoy_cluster_outlier_detection_ejections_active{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}) / sum(envoy_cluster_membership_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "interval": "", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Outlier detection", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:402", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "$$hashKey": "object:403", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "refresh": "5s", + "schemaVersion": 27, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "Prometheus-mesh-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "backend_kuma-demo_svc_3001", + "value": "backend_kuma-demo_svc_3001" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_service)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Source service", + "multi": false, + "name": "source_service", + "options": [], + "query": { + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_service)", + "refId": "Prometheus-source_service-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "frontend_kuma-demo_svc_8080", + "value": "frontend_kuma-demo_svc_8080" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_cluster_upstream_cx_active{kuma_io_service=\"$source_service\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}, envoy_cluster_name)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Destination service", + "multi": false, + "name": "destination_cluster", + "options": [], + "query": { + "query": "label_values(envoy_cluster_upstream_cx_active{kuma_io_service=\"$source_service\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}, envoy_cluster_name)", + "refId": "Prometheus-destination_cluster-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-1h", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma Service to Service", + "uid": "QdCgOqyWz", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-3 + namespace: mesh-observability + labels: + app: grafana +data: + kuma-cp.json: | + { + "__inputs": [ + { + "name": "DS_PROMETHEUS", + "label": "Prometheus", + "description": "", + "type": "datasource", + "pluginId": "prometheus", + "pluginName": "Prometheus" + } + ], + "__elements": [], + "__requires": [ + { + "type": "grafana", + "id": "grafana", + "name": "Grafana", + "version": "8.3.3" + }, + { + "type": "panel", + "id": "graph", + "name": "Graph (old)", + "version": "" + }, + { + "type": "datasource", + "id": "prometheus", + "name": "Prometheus", + "version": "1.0.0" + }, + { + "type": "panel", + "id": "stat", + "name": "Stat", + "version": "" + }, + { + "type": "panel", + "id": "table", + "name": "Table", + "version": "" + } + ], + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": null, + "iteration": 1645785455248, + "links": [], + "liveNow": false, + "panels": [ + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 44, + "panels": [], + "title": "Overview", + "type": "row" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [ + { + "options": { + "from": 1, + "result": { + "color": "green", + "index": 0, + "text": "LIVE" + }, + "to": 9999 + }, + "type": "range" + }, + { + "options": { + "from": 0, + "result": { + "color": "red", + "index": 1, + "text": "UNAVAILABLE" + }, + "to": 0.999 + }, + "type": "range" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 1 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 6, + "x": 0, + "y": 1 + }, + "id": 39, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "auto" + }, + "pluginVersion": "8.3.3", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(cp_info{instance=~\"$instance\"} OR on() vector(0))", + "instant": false, + "interval": "", + "intervalFactor": 1, + "legendFormat": "", + "refId": "A" + } + ], + "title": "Condition", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "displayMode": "auto" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 6, + "y": 1 + }, + "id": 41, + "maxDataPoints": 1, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true + }, + "pluginVersion": "8.3.3", + "targets": [ + { + "expr": "cp_info{instance=~\"$instance\"}", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Control Plane information", + "transformations": [ + { + "id": "labelsToFields", + "options": {} + }, + { + "id": "merge", + "options": {} + }, + { + "id": "organize", + "options": { + "excludeByName": { + "Time": true, + "Value": true, + "build_date": true, + "cluster_id": true, + "git_commit": true, + "git_tag": true, + "job": true, + "kubernetes_name": true, + "kubernetes_namespace": true, + "kubernetes_node": true, + "product": true + }, + "indexByName": {}, + "renameByName": { + "instance": "Instance", + "instance_id": "Instance ID", + "mode": "Mode", + "version": "Version" + } + } + }, + { + "id": "merge", + "options": {} + } + ], + "type": "table" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Only one instance should be a leader at a given point of time in every zone", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 18, + "y": 1 + }, + "hiddenSeries": false, + "id": 68, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (zone, instance) (leader)", + "interval": "", + "legendFormat": "{{ zone }} - {{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Leader", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:3281", + "format": "short", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:3282", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 9 + }, + "id": 16, + "panels": [], + "title": "Aggregated Discovery Service (XDS): CP-DP communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 4, + "x": 0, + "y": 10 + }, + "hiddenSeries": false, + "id": 20, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "xds_streams_active{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "XDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:258", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:259", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of ADS messages exchanged between Control Plane and Dataplane over XDS", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 4, + "y": 10 + }, + "hiddenSeries": false, + "id": 18, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:630", + "alias": "Configuration sent", + "color": "#5794F2" + }, + { + "$$hashKey": "object:631", + "alias": "Configuration accepted", + "color": "#73BF69" + }, + { + "$$hashKey": "object:632", + "alias": "Configuration rejected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:633", + "alias": "RPC Errors", + "color": "#C4162A" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(xds_responses_sent{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Configuration sent", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(xds_requests_received{confirmation=\"ACK\",instance=~\"$instance\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Configuration accepted", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(xds_requests_received{confirmation=\"NACK\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Configuration rejected", + "refId": "C" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(grpc_server_handled_total{grpc_service=\"envoy.service.discovery.v3.AggregatedDiscoveryService\",grpc_code!=\"OK\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "RPC Errors", + "refId": "D" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(grpc_server_started_total{grpc_service=\"envoy.service.discovery.v3.AggregatedDiscoveryService\",instance=~\"$instance\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Rate", + "refId": "E" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "XDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:458", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:459", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of Envoy XDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected dataplanes * KUMA_XDS_SERVER_DATAPLANE_CONFIGURATION_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 9, + "y": 10 + }, + "hiddenSeries": false, + "id": 28, + "legend": { + "avg": false, + "current": false, + "hideZero": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:1365", + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(xds_generation_count{instance=~\"$instance\"}[1m])) - sum(rate(xds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "expr": "sum(rate(xds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "XDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:456", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:457", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "How much it took to generate Envoy configuration for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 14, + "y": 10 + }, + "hiddenSeries": false, + "id": 24, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "xds_generation{quantile=\"0.99\",instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of XDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to deliver Envoy configuration and receive ACK/NACK for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 19, + "y": 10 + }, + "hiddenSeries": false, + "id": 82, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "xds_delivery{quantile=\"0.99\",instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of XDS config delivery (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Cache protects ClusterLoadAssignments resources by sharing them between many goroutines which reconcile Dataplanes.\n\nhit - request was retrieved from the cache.\n\nhit-wait - request was retrieved from the cache after waiting for a concurrent request to fetch it from the database.\n\nmiss - request was fetched from the database\n\nRefer to https://kuma.io/docs/latest/documentation/fine-tuning/#snapshot-generation", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 13, + "x": 0, + "y": 18 + }, + "hiddenSeries": false, + "id": 70, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": true, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(cla_cache{result=\"hit\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit", + "refId": "A" + }, + { + "expr": "sum(rate(cla_cache{result=\"hit-wait\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit Wait", + "refId": "C" + }, + { + "expr": "sum(rate(cla_cache{result=\"miss\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Miss", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Endpoints cache performance", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:645", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:646", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Mesh Cache protects hashes calculated periodically for each Mesh in order to avoid the excessive generation of xDS resources.\n\nhit - request was retrieved from the cache.\n\nhit-wait - request was retrieved from the cache after waiting for a concurrent request to fetch it from the database.\n\nmiss - request was fetched from the database\n\nRefer to https://kuma.io/docs/latest/documentation/fine-tuning/#snapshot-generation", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 11, + "x": 13, + "y": 18 + }, + "hiddenSeries": false, + "id": 71, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": true, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(mesh_cache{result=\"hit\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit", + "refId": "A" + }, + { + "expr": "sum(rate(mesh_cache{result=\"hit-wait\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit Wait", + "refId": "C" + }, + { + "expr": "sum(rate(mesh_cache{result=\"miss\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Miss", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Mesh resources hash cache performance", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:645", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:646", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 26 + }, + "id": 73, + "panels": [], + "title": "Health Discovery Service (HDS): CP-DP communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 0, + "y": 27 + }, + "hiddenSeries": false, + "id": 75, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(hds_responses_sent{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "endpoint health responses", + "refId": "A" + }, + { + "expr": "sum(rate(hds_requests_received{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "health check requests", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "HDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:310", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:311", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 6, + "y": 27 + }, + "hiddenSeries": false, + "id": 77, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "hds_streams_active{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "HDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:797", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:798", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of Envoy HDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected dataplanes * KUMA_DP_SERVER_HDS_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 12, + "y": 27 + }, + "hiddenSeries": false, + "id": 79, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:1727", + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(hds_generation_count{instance=~\"$instance\"}[1m])) - sum(rate(hds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(hds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "HDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1493", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:1494", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to generate Envoy configuration for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 18, + "y": 27 + }, + "hiddenSeries": false, + "id": 81, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "hds_generation{quantile=\"0.99\",instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of HDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1825", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1826", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 35 + }, + "id": 5, + "panels": [], + "title": "API Server - Management of the Control Plane", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 16, + "x": 0, + "y": 36 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, sum by (handler, le) (rate(api_server_http_request_duration_seconds_bucket{instance=~\"$instance\"}[1m])))", + "interval": "", + "legendFormat": "{{handler}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of API Server Requests (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:853", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:854", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 36 + }, + "hiddenSeries": false, + "id": 9, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:695", + "alias": "/2.*/", + "color": "#73BF69" + }, + { + "$$hashKey": "object:696", + "alias": "/4.*/", + "color": "#FADE2A" + }, + { + "$$hashKey": "object:697", + "alias": "/5.*/", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (code) (rate(api_server_http_request_duration_seconds_count{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "{{code}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Response Codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:796", + "format": "cps", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:797", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 44 + }, + "id": 54, + "panels": [], + "title": "Dataplane Server: CP-DP communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "XDS and SDS requests are not taken into account because they are long-running requests", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 16, + "x": 0, + "y": 45 + }, + "hiddenSeries": false, + "id": 55, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, sum by (handler, le) (rate(dp_server_http_request_duration_seconds_bucket{instance=~\"$instance\"}[1m])))", + "interval": "", + "legendFormat": "{{handler}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of Dataplane Server Requests (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:853", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:854", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "XDS and SDS requests are not taken into account because they are long-running requests", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 8, + "x": 16, + "y": 45 + }, + "hiddenSeries": false, + "id": 56, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:695", + "alias": "/2.*/", + "color": "#73BF69" + }, + { + "$$hashKey": "object:696", + "alias": "/4.*/", + "color": "#FADE2A" + }, + { + "$$hashKey": "object:697", + "alias": "/5.*/", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (code) (rate(dp_server_http_response_size_bytes_count{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "{{code}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Response Codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:796", + "format": "cps", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:797", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 52 + }, + "id": 26, + "panels": [], + "title": "Kuma Discovery Service (KDS) - Mutltizone communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "This metric presents if policies are properly propagated from Global to Zones. All instances of global and zones in the system should have the same number of policies. This metric have additional latency of 1 minute (it is not computed on the fly when scraping is done)", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 53 + }, + "hiddenSeries": false, + "id": 61, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum by (zone, instance) (resources_count{instance=~\"$instance\",resource_type!~\"Dataplane|DataplaneInsight|Zone|ZoneInsight|ZoneIngress|ZoneIngressInsight|ZoneEgress|ZoneEgressInsight\"})", + "interval": "", + "legendFormat": "{{ zone }} - {{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Policies count (sync check)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "This metric presents if Dataplanes are properly propagated from Zones to Global. Keep in mind that Dataplanes from all zones != Dataplanes from global. All zones receive additional one dataplane of Ingress from other Zones. This metric have additional latency of 1 minute (it is not computed on the fly when scraping is done)", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 53 + }, + "hiddenSeries": false, + "id": 66, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (zone, instance) (resources_count{instance=~\"$instance\",resource_type=\"Dataplane\"})", + "interval": "", + "legendFormat": "{{ zone }} - {{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Dataplane count", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of zone CP connected to Global.", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 4, + "x": 0, + "y": 61 + }, + "hiddenSeries": false, + "id": 58, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "kds_streams_active{instance=~\"$instance\",zone=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - KDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of KDS messages exchanged between Global Control Plane and Zone Control Plane over KDS. Global sends to Zone policies and Ingress Dataplanes", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 4, + "y": 61 + }, + "hiddenSeries": false, + "id": 57, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:194", + "alias": "Configuration sent", + "color": "#5794F2" + }, + { + "$$hashKey": "object:195", + "alias": "Configuration accepted", + "color": "#73BF69" + }, + { + "$$hashKey": "object:196", + "alias": "Configuration rejected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:197", + "alias": "RPC Errors", + "color": "#C4162A" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_responses_sent{instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration sent", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"ACK\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Configuration accepted", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"NACK\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration rejected", + "refId": "C" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_handled_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",grpc_code!=\"OK\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "RPC Errors", + "refId": "D" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_started_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Rate", + "refId": "E" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - KDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1007", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:1008", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of KDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected control planes * KUMA_MULTIZONE_GLOBAL_KDS_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 9, + "y": 61 + }, + "hiddenSeries": false, + "id": 59, + "legend": { + "avg": false, + "current": false, + "hideZero": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(kds_generation_count{instance=~\"$instance\",zone=\"Global\"}[1m])) - sum(rate(kds_generation_errors{instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "expr": "sum(rate(kds_generation_errors{instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - KDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:850", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:851", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to generate KDS configuration for a single zone control plane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 14, + "y": 61 + }, + "hiddenSeries": false, + "id": 60, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_generation{quantile=\"0.99\",instance=~\"$instance\",zone=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - Latency of KDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:988", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:989", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to deliver Envoy configuration and receive ACK/NACK for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 19, + "y": 61 + }, + "hiddenSeries": false, + "id": 83, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_delivery{quantile=\"0.99\",instance=~\"$instance\",zone=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - Latency of KDS config delivery (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of global CP connected to Zone.", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 4, + "x": 0, + "y": 69 + }, + "hiddenSeries": false, + "id": 63, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "kds_streams_active{instance=~\"$instance\",zone!=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - KDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of KDS messages exchanged between Global Control Plane and Zone Control Plane over KDS. Zone sends to Global its Dataplanes and DataplaneInsights", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 4, + "y": 69 + }, + "hiddenSeries": false, + "id": 62, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:194", + "alias": "Configuration sent", + "color": "#5794F2" + }, + { + "$$hashKey": "object:195", + "alias": "Configuration accepted", + "color": "#73BF69" + }, + { + "$$hashKey": "object:196", + "alias": "Configuration rejected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:197", + "alias": "RPC Errors", + "color": "#C4162A" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_responses_sent{instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration sent", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"ACK\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Configuration accepted", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"NACK\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration rejected", + "refId": "C" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_handled_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",grpc_code!=\"OK\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "RPC Errors", + "refId": "D" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_started_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Rate", + "refId": "E" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - KDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1007", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:1008", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of KDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected control planes * KUMA_MULTIZONE_ZONE_KDS_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 9, + "y": 69 + }, + "hiddenSeries": false, + "id": 64, + "legend": { + "avg": false, + "current": false, + "hideZero": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(kds_generation_count{instance=~\"$instance\",zone!=\"Global\"}[1m])) - sum(rate(kds_generation_errors{instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "expr": "sum(rate(kds_generation_errors{instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - KDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:850", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:851", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to generate KDS configuration for a global control plane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 14, + "y": 69 + }, + "hiddenSeries": false, + "id": 65, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_generation{quantile=\"0.99\",instance=~\"$instance\",zone!=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - Latency of KDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:988", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:989", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to deliver Envoy configuration and receive ACK/NACK for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 19, + "y": 69 + }, + "hiddenSeries": false, + "id": 84, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_delivery{quantile=\"0.99\",instance=~\"$instance\",zone!=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - Latency of KDS config delivery (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 77 + }, + "id": 11, + "panels": [], + "title": "Store", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Latency of underlying storage (API Server on K8S, Postgres on Universal etc.)", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 7, + "x": 0, + "y": 78 + }, + "hiddenSeries": false, + "id": 12, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, sum by (operation, le) (rate(store_bucket{instance=~\"$instance\"}[1m])))", + "interval": "", + "legendFormat": "{{operation}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of Store operations (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:545", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:546", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Cache protects underlying storage by sharing responses between many goroutines accessing the storage.\n\nhit - request was retrieved from the cache.\n\nhit-wait - request was retrieved from the cache after waiting for a concurrent request to fetch it from the database.\n\nmiss - request was fetched from the database\n\nRefer to https://kuma.io/docs/latest/documentation/fine-tuning/#snapshot-generation", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 5, + "x": 7, + "y": 78 + }, + "hiddenSeries": false, + "id": 14, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": true, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(store_cache{result=\"hit\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit", + "refId": "A" + }, + { + "expr": "sum(rate(store_cache{result=\"hit-wait\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit Wait", + "refId": "C" + }, + { + "expr": "sum(rate(store_cache{result=\"miss\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Miss", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Store cache performance", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:645", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:646", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Real requests executed on the underlying storage (Postgres/Kubernetes API Server)", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 12, + "x": 12, + "y": 78 + }, + "hiddenSeries": false, + "id": 13, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (operation, resource_type) (rate(store_count{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "{{operation}} - {{resource_type}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Store operations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "decimals": 2, + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 87 + }, + "id": 35, + "panels": [], + "title": "Go Runtime", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 0, + "y": 88 + }, + "hiddenSeries": false, + "id": 30, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_goroutines{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Goroutines", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1463", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1464", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 6, + "y": 88 + }, + "hiddenSeries": false, + "id": 31, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_threads{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Threads", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1544", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1545", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 12, + "y": 88 + }, + "hiddenSeries": false, + "id": 33, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_memstats_alloc_bytes{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Memory allocated", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1693", + "format": "bytes", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1694", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 18, + "y": 88 + }, + "hiddenSeries": false, + "id": 32, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_gc_duration_seconds{instance=~\"$instance\", quantile=\"0.75\"}", + "interval": "", + "legendFormat": "{{ instance}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of GC time (75th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1774", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1775", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + } + ], + "refresh": "5s", + "schemaVersion": 34, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": {}, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "definition": "label_values(cp_info, zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": false, + "name": "zone", + "options": [], + "query": { + "query": "label_values(cp_info, zone)", + "refId": "Prometheus-zone-Variable-Query" + }, + "refresh": 2, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "current": {}, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "definition": "label_values(cp_info{zone=~\"$zone\"}, instance)", + "hide": 0, + "includeAll": true, + "label": "Instance", + "multi": false, + "name": "instance", + "options": [], + "query": { + "query": "label_values(cp_info{zone=~\"$zone\"}, instance)", + "refId": "Prometheus-instance-Variable-Query" + }, + "refresh": 2, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma CP", + "uid": "z6C1v-NGk", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-4 + namespace: mesh-observability + labels: + app: grafana +data: + kuma-service.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "editable": true, + "gnetId": null, + "graphTooltip": 0, + "id": 1, + "iteration": 1619601383600, + "links": [], + "panels": [ + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "fixedColor": "green", + "mode": "fixed" + }, + "custom": {}, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 0 + }, + "id": 12, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "auto" + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "count(envoy_server_live{kuma_io_services=~\".*$service.*\"})", + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Dataplanes", + "transformations": [], + "type": "stat" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": null, + "filterable": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 0 + }, + "id": 23, + "options": { + "showHeader": false + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Dataplanes", + "transformations": [ + { + "id": "labelsToFields", + "options": {} + }, + { + "id": "organize", + "options": { + "excludeByName": { + "Time": true, + "Value": true, + "app": true, + "apps": true, + "env": true, + "envs": true, + "instance": true, + "job": true, + "k8s_kuma_io_name": true, + "k8s_kuma_io_namespace": true, + "kuma_io_protocol": true, + "kuma_io_protocols": true, + "kuma_io_service": true, + "kuma_io_services": true, + "mesh": true, + "namespace": true, + "pod": true, + "pod_template_hash": true, + "pod_template_hashs": true, + "version": true, + "versions": true + }, + "indexByName": {}, + "renameByName": { + "dataplane": "Dataplanes", + "env": "" + } + } + }, + { + "id": "merge", + "options": {} + } + ], + "type": "table" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": {}, + "displayName": "Incoming", + "mappings": [], + "noValue": "0", + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "reqps" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 8, + "x": 16, + "y": 0 + }, + "id": 15, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "value_and_name" + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\",envoy_cluster_name=~\"localhost_.*\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "C" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "", + "type": "stat" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": {}, + "displayName": "Outgoing", + "mappings": [], + "noValue": "0", + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "reqps" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 8, + "x": 16, + "y": 4 + }, + "id": 22, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "value_and_name" + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\",envoy_cluster_name!~\"localhost_.*\",envoy_cluster_name!=\"kuma_envoy_admin\",envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "C" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "", + "type": "stat" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 8 + }, + "id": 14, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "color": {}, + "custom": {}, + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 9 + }, + "hiddenSeries": false, + "id": 4, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_services=~\".*$service.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p99", + "refId": "A" + }, + { + "expr": "max(histogram_quantile(0.95, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_services=~\".*$service.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p95", + "refId": "C" + }, + { + "expr": "max(histogram_quantile(0.50, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_services=~\".*$service.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p50", + "refId": "D" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:631", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:632", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 9 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name=~\"localhost_.*\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Incoming", + "refId": "C" + }, + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\",envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Outgoing", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:429", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:430", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 9 + }, + "hiddenSeries": false, + "id": 10, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name=~\"localhost_.*\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Incoming {{envoy_response_code_class}}xx", + "refId": "A" + }, + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\", envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Outgoing {{envoy_response_code_class}}xx", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Status codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 18 + }, + "id": 17, + "panels": [], + "title": "Kubernetes", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 19 + }, + "hiddenSeries": false, + "id": 8, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(sum(rate(container_cpu_usage_seconds_total[1m])) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane) /\nmax(sum(kube_pod_container_resource_limits_cpu_cores) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "hide": false, + "interval": "", + "legendFormat": "{{ dataplane }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "CPU", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:854", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:855", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 19 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(sum(container_memory_working_set_bytes{image!=\"\"}) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "hide": false, + "interval": "", + "legendFormat": "{{ dataplane }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Memory Utilization", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:44", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:45", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 19 + }, + "hiddenSeries": false, + "id": 7, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(sum(container_memory_working_set_bytes) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane) / max(sum(kube_pod_container_resource_limits_memory_bytes) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "hide": false, + "interval": "", + "legendFormat": "{{ dataplane }}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Memory Saturation", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:854", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:855", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "refresh": "5s", + "schemaVersion": 27, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": null, + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "backend_kuma-demo_svc_3001", + "value": "backend_kuma-demo_svc_3001" + }, + "datasource": null, + "definition": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, kuma_io_service)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Service", + "multi": false, + "name": "service", + "options": [], + "query": { + "query": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, kuma_io_service)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Kuma Service", + "uid": "FkJ7AxwMz", + "version": 1 + } +--- +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "8Gi" +--- +kind: ClusterRole +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + labels: + app: grafana + name: grafana-clusterrole +rules: [] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics +rules: + - apiGroups: + - "" + resources: + - namespaces + - nodes + - persistentvolumeclaims + - pods + - services + - resourcequotas + - replicationcontrollers + - limitranges + - persistentvolumeclaims + - persistentvolumes + - endpoints + - secrets + - configmaps + verbs: + - list + - watch + - apiGroups: + - extensions + resources: + - daemonsets + - deployments + - ingresses + - replicasets + verbs: + - list + - watch + - apiGroups: + - apps + resources: + - daemonsets + - deployments + - statefulsets + - replicasets + verbs: + - get + - list + - watch + - apiGroups: + - batch + resources: + - cronjobs + - jobs + verbs: + - list + - watch + - apiGroups: + - autoscaling + resources: + - horizontalpodautoscalers + verbs: + - list + - watch + - apiGroups: + - policy + resources: + - poddisruptionbudgets + verbs: + - list + - watch + - apiGroups: + - storage.k8s.io + resources: + - storageclasses + - volumeattachments + verbs: + - list + - watch + - apiGroups: + - certificates.k8s.io + resources: + - certificatesigningrequests + verbs: + - list + - watch + - apiGroups: + - networking.k8s.io + resources: + - networkpolicies + verbs: + - list + - watch + - apiGroups: + - admissionregistration.k8s.io + resources: + - validatingwebhookconfigurations + - mutatingwebhookconfigurations + verbs: + - list + - watch +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server +rules: + - apiGroups: + - "" + resources: + - nodes + - nodes/proxy + - nodes/metrics + - services + - endpoints + - pods + - ingresses + - configmaps + verbs: + - get + - list + - watch + - apiGroups: + - "extensions" + resources: + - ingresses/status + - ingresses + verbs: + - get + - list + - watch + - nonResourceURLs: + - "/metrics" + verbs: + - get +--- +kind: ClusterRoleBinding +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + name: grafana-clusterrolebinding + labels: + app: grafana +subjects: + - kind: ServiceAccount + name: grafana + namespace: mesh-observability +roleRef: + kind: ClusterRole + name: grafana-clusterrole + apiGroup: rbac.authorization.k8s.io +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics +subjects: + - kind: ServiceAccount + name: prometheus-kube-state-metrics + namespace: mesh-observability +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: prometheus-kube-state-metrics +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server +subjects: + - kind: ServiceAccount + name: prometheus-server + namespace: mesh-observability +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: prometheus-server +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: grafana + namespace: mesh-observability + labels: + app: grafana +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [grafana] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: grafana + namespace: default + labels: + app: grafana +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: grafana +subjects: + - kind: ServiceAccount + name: grafana + namespace: mesh-observability +--- +apiVersion: v1 +kind: Service +metadata: + name: grafana + namespace: mesh-observability + labels: + app: grafana +spec: + type: ClusterIP + ports: + - name: service + port: 80 + protocol: TCP + targetPort: 3000 + selector: + app: grafana +--- +apiVersion: v1 +kind: Service +metadata: + annotations: + prometheus.io/scrape: "true" + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: mesh-observability +spec: + clusterIP: None + ports: + - name: http + port: 80 + protocol: TCP + targetPort: 8080 + - name: telemetry + port: 81 + protocol: TCP + targetPort: 8081 + selector: + component: "kube-state-metrics" + app: prometheus + type: "ClusterIP" +--- +apiVersion: v1 +kind: Service +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +spec: + ports: + - name: http + port: 80 + protocol: TCP + targetPort: 9090 + selector: + component: "server" + app: prometheus + sessionAffinity: None + type: "ClusterIP" +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: grafana + namespace: mesh-observability + labels: + app: grafana +spec: + replicas: 1 + selector: + matchLabels: + app: grafana + strategy: + type: RollingUpdate + template: + metadata: + labels: + app: grafana + annotations: + checksum/config: 4fbce6ca7985bb33289922e68acc9af246f301cf9650f061fbcd0155925665df + checksum/dashboards-json-config: 01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b + checksum/sc-dashboard-provider-config: 01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b + checksum/secret: 281444758252a4bdd272546732dfb8e2be87be71b795d2aadc3726e3524f63e3 + spec: + serviceAccountName: grafana + securityContext: + fsGroup: 472 + runAsUser: 472 + initContainers: + - name: init-plugins + image: alpine + command: [ '/bin/sh', '-c', 'wget -O /tmp/kuma.zip https://github.com/kumahq/kuma-grafana-datasource/releases/download/v0.1.0/kumahq-kuma-datasource-0.1.0.zip && unzip /tmp/kuma.zip -d /var/lib/grafana/plugins/ && rm /tmp/kuma.zip'] + volumeMounts: + - name: plugins-volume + mountPath: /var/lib/grafana/plugins + containers: + - name: grafana + image: "grafana/grafana:8.5.2" + imagePullPolicy: IfNotPresent + volumeMounts: + - name: config + mountPath: "/etc/grafana/grafana.ini" + subPath: grafana.ini + readOnly: true + - name: storage + mountPath: "/var/lib/grafana" + - name: provisioning-datasource + mountPath: /etc/grafana/provisioning/datasources + readOnly: true + - name: provisioning-dashboards + mountPath: /etc/grafana/provisioning/dashboards + readOnly: true + - name: plugins-volume + mountPath: /var/lib/grafana/plugins + readOnly: true + ports: + - name: service + containerPort: 80 + protocol: TCP + - name: grafana + containerPort: 3000 + protocol: TCP + livenessProbe: + failureThreshold: 10 + httpGet: + path: /api/health + port: 3000 + initialDelaySeconds: 60 + timeoutSeconds: 30 + readinessProbe: + httpGet: + path: /api/health + port: 3000 + resources: + {} + volumes: + - name: config + configMap: + name: grafana + - name: provisioning-datasource + configMap: + name: provisioning-datasource + - name: provisioning-dashboards + projected: + sources: + - configMap: + name: provisioning-dashboards + + - configMap: + name: provisioning-dashboards-0 + + - configMap: + name: provisioning-dashboards-1 + + - configMap: + name: provisioning-dashboards-2 + + - configMap: + name: provisioning-dashboards-3 + + - configMap: + name: provisioning-dashboards-4 + + - name: storage + emptyDir: {} + - name: plugins-volume + emptyDir: {} +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: mesh-observability +spec: + selector: + matchLabels: + component: "kube-state-metrics" + app: prometheus + replicas: 1 + template: + metadata: + labels: + component: "kube-state-metrics" + app: prometheus + spec: + serviceAccountName: prometheus-kube-state-metrics + containers: + - name: prometheus-kube-state-metrics + image: "quay.io/coreos/kube-state-metrics:v1.9.8" + imagePullPolicy: "IfNotPresent" + ports: + - name: metrics + containerPort: 8080 + - name: telemetry + containerPort: 8081 + resources: + {} + securityContext: + runAsUser: 65534 +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +spec: + selector: + matchLabels: + component: "server" + app: prometheus + replicas: 1 + template: + metadata: + labels: + component: "server" + app: prometheus + annotations: + kuma.io/direct-access-services: "*" + spec: + serviceAccountName: prometheus-server + containers: + - name: prometheus-server-configmap-reload + image: "jimmidyson/configmap-reload:v0.6.1" + imagePullPolicy: "IfNotPresent" + args: + - --volume-dir=/etc/config + - --webhook-url=http://127.0.0.1:9090/-/reload + resources: + {} + volumeMounts: + - name: config-volume + mountPath: /etc/config + readOnly: true + - name: prometheus-server + image: "prom/prometheus:v2.35.0" + imagePullPolicy: "IfNotPresent" + args: + - --storage.tsdb.retention.time=15d + - --config.file=/etc/config/prometheus.yml + - --storage.tsdb.path=/data + - --web.console.libraries=/etc/prometheus/console_libraries + - --web.console.templates=/etc/prometheus/consoles + - --web.enable-lifecycle + ports: + - containerPort: 9090 + resources: + {} + volumeMounts: + - name: config-volume + mountPath: /etc/config + - name: storage-volume + mountPath: /data + subPath: "" + securityContext: + fsGroup: 65534 + runAsGroup: 65534 + runAsUser: 65534 + terminationGracePeriodSeconds: 300 + volumes: + - name: config-volume + configMap: + name: prometheus-server + - name: storage-volume + persistentVolumeClaim: + claimName: prometheus-server +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'configMap' + - 'emptyDir' + - 'persistentVolumeClaim' + - 'secret' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'MustRunAsNonRoot' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + fsGroup: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'secret' + - 'configMap' + - 'hostPath' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'RunAsAny' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'RunAsAny' + fsGroup: + rule: 'RunAsAny' + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: loki + release: loki + annotations: + {} + name: loki + namespace: mesh-observability +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: promtail + release: loki + name: loki-promtail + namespace: mesh-observability +--- +apiVersion: v1 +kind: Secret +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +data: + loki.yaml: YXV0aF9lbmFibGVkOiBmYWxzZQpjaHVua19zdG9yZV9jb25maWc6CiAgbWF4X2xvb2tfYmFja19wZXJpb2Q6IDBzCmluZ2VzdGVyOgogIGNodW5rX2Jsb2NrX3NpemU6IDI2MjE0NAogIGNodW5rX2lkbGVfcGVyaW9kOiAzbQogIGNodW5rX3JldGFpbl9wZXJpb2Q6IDFtCiAgbGlmZWN5Y2xlcjoKICAgIHJpbmc6CiAgICAgIGt2c3RvcmU6CiAgICAgICAgc3RvcmU6IGlubWVtb3J5CiAgICAgIHJlcGxpY2F0aW9uX2ZhY3RvcjogMQogIHdhbDoKICAgIGVuYWJsZWQ6IGZhbHNlCmxpbWl0c19jb25maWc6CiAgZW5mb3JjZV9tZXRyaWNfbmFtZTogZmFsc2UKc2NoZW1hX2NvbmZpZzoKICBjb25maWdzOgogIC0gZnJvbTogIjIwMTgtMDQtMTUiCiAgICBpbmRleDoKICAgICAgcGVyaW9kOiAxNjhoCiAgICAgIHByZWZpeDogaW5kZXhfCiAgICBvYmplY3Rfc3RvcmU6IGZpbGVzeXN0ZW0KICAgIHNjaGVtYTogdjkKICAgIHN0b3JlOiBib2x0ZGIKc2VydmVyOgogIGh0dHBfbGlzdGVuX3BvcnQ6IDMxMDAKc3RvcmFnZV9jb25maWc6CiAgYm9sdGRiOgogICAgZGlyZWN0b3J5OiAvZGF0YS9sb2tpL2luZGV4CiAgZmlsZXN5c3RlbToKICAgIGRpcmVjdG9yeTogL2RhdGEvbG9raS9jaHVua3MKdGFibGVfbWFuYWdlcjoKICByZXRlbnRpb25fZGVsZXRlc19lbmFibGVkOiBmYWxzZQogIHJldGVudGlvbl9wZXJpb2Q6IDBzCg== +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +data: + promtail.yaml: | + client: + backoff_config: + max_period: 5s + max_retries: 20 + min_period: 100ms + batchsize: 102400 + batchwait: 1s + external_labels: {} + timeout: 10s + positions: + filename: /run/promtail/positions.yaml + server: + http_listen_port: 3101 + target_config: + sync_period: 10s + scrape_configs: + - job_name: kubernetes-pods-name + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - source_labels: + - __meta_kubernetes_pod_label_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-app + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - action: drop + regex: .+ + source_labels: + - __meta_kubernetes_pod_label_name + - source_labels: + - __meta_kubernetes_pod_label_app + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-direct-controllers + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: drop + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-indirect-controller + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: keep + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - action: replace + regex: '([0-9a-z-.]+)-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-static + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: '' + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - action: replace + source_labels: + - __meta_kubernetes_pod_label_component + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - __meta_kubernetes_pod_container_name + target_label: __path__ +--- +kind: ClusterRole +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + labels: + app: promtail + release: loki + name: loki-promtail-clusterrole + namespace: mesh-observability +rules: + - apiGroups: [""] # "" indicates the core API group + resources: + - nodes + - nodes/proxy + - services + - endpoints + - pods + verbs: ["get", "watch", "list"] +--- +kind: ClusterRoleBinding +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + name: loki-promtail-clusterrolebinding + labels: + app: promtail + release: loki +subjects: + - kind: ServiceAccount + name: loki-promtail + namespace: mesh-observability +roleRef: + kind: ClusterRole + name: loki-promtail-clusterrole + apiGroup: rbac.authorization.k8s.io +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki-promtail] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki +subjects: + - kind: ServiceAccount + name: loki +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki-promtail +subjects: + - kind: ServiceAccount + name: loki-promtail +--- +apiVersion: v1 +kind: Service +metadata: + name: loki-headless + namespace: mesh-observability + labels: + app: loki + release: loki + variant: headless +spec: + clusterIP: None + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: v1 +kind: Service +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + type: ClusterIP + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: apps/v1 +kind: DaemonSet +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki + annotations: + {} +spec: + selector: + matchLabels: + app: promtail + release: loki + updateStrategy: + {} + template: + metadata: + labels: + app: promtail + release: loki + annotations: + checksum/config: bce7daf9d5acc773342c4f42e700668ef8bdc8f34fa1499c766263fa0c1944e0 + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki-promtail + containers: + - name: promtail + image: "grafana/promtail:2.4.1" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/promtail/promtail.yaml" + - "-client.url=http://loki.mesh-observability:3100/loki/api/v1/push" + volumeMounts: + - name: config + mountPath: /etc/promtail + - name: run + mountPath: /run/promtail + - mountPath: /var/lib/docker/containers + name: docker + readOnly: true + - mountPath: /var/log/pods + name: pods + readOnly: true + env: + - name: HOSTNAME + valueFrom: + fieldRef: + fieldPath: spec.nodeName + ports: + - containerPort: 3101 + name: http-metrics + securityContext: + readOnlyRootFilesystem: true + runAsGroup: 0 + runAsUser: 0 + readinessProbe: + failureThreshold: 5 + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 + resources: + {} + nodeSelector: + {} + affinity: + {} + tolerations: + - effect: NoSchedule + key: node-role.kubernetes.io/master + operator: Exists + volumes: + - name: config + configMap: + name: loki-promtail + - name: run + hostPath: + path: /run/promtail + - hostPath: + path: /var/lib/docker/containers + name: docker + - hostPath: + path: /var/log/pods + name: pods +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app: loki + release: loki + serviceName: loki-headless + updateStrategy: + type: RollingUpdate + template: + metadata: + labels: + app: loki + name: loki + release: loki + annotations: + checksum/config: d4c94f4c6a73353362c10d2f844340cec8999b291ca88481ac162fbb5942617d + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + initContainers: + [] + containers: + - name: loki + image: "grafana/loki:2.5.0" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/loki/loki.yaml" + - "-target=all,table-manager" + volumeMounts: + - name: config + mountPath: /etc/loki + - name: storage + mountPath: "/data" + ports: + - name: http-metrics + containerPort: 3100 + protocol: TCP + livenessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + {} + securityContext: + readOnlyRootFilesystem: true + nodeSelector: + {} + affinity: + {} + tolerations: + [] + terminationGracePeriodSeconds: 4800 + volumes: + - name: config + secret: + secretName: loki + - name: storage + emptyDir: {} +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +# Based on https://github.com/jaegertracing/jaeger-kubernetes/blob/master/all-in-one/jaeger-all-in-one-template.yml + +# +# Copyright 2017-2019 The Jaeger 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. +# + +apiVersion: v1 +kind: List +items: + - apiVersion: apps/v1 + kind: Deployment + metadata: + name: jaeger + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + spec: + replicas: 1 + selector: + matchLabels: + app: jaeger + strategy: + type: Recreate + template: + metadata: + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + annotations: + prometheus.io/scrape: "true" + prometheus.io/port: "16686" + spec: + containers: + - env: + - name: COLLECTOR_ZIPKIN_HOST_PORT + value: "9411" + image: jaegertracing/all-in-one:1.34.1 + name: jaeger + ports: + - containerPort: 5775 + protocol: UDP + - containerPort: 6831 + protocol: UDP + - containerPort: 6832 + protocol: UDP + - containerPort: 5778 + protocol: TCP + - containerPort: 16686 + protocol: TCP + - containerPort: 9411 + protocol: TCP + readinessProbe: + httpGet: + path: "/" + port: 14269 + initialDelaySeconds: 5 + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-query + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: query + spec: + selector: + matchLabels: + app: jaeger-query + ports: + - name: query-http + port: 80 + protocol: TCP + targetPort: 16686 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-collector + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: collector + spec: + selector: + matchLabels: + app: jaeger-collector + ports: + - name: jaeger-collector-tchannel + port: 14267 + protocol: TCP + targetPort: 14267 + - name: jaeger-collector-http + port: 14268 + protocol: TCP + targetPort: 14268 + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-agent + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: agent + spec: + selector: + matchLabels: + app: jaeger-agent + ports: + - name: agent-zipkin-thrift + port: 5775 + protocol: UDP + targetPort: 5775 + - name: agent-compact + port: 6831 + protocol: UDP + targetPort: 6831 + - name: agent-binary + port: 6832 + protocol: UDP + targetPort: 6832 + - name: agent-configs + port: 5778 + protocol: TCP + targetPort: 5778 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + - apiVersion: v1 + kind: Service + metadata: + name: zipkin + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: zipkin + spec: + selector: + matchLabels: + app: zipkin + ports: + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one diff --git a/app/kumactl/cmd/install/testdata/install-observability.no-grafana.golden.yaml b/app/kumactl/cmd/install/testdata/install-observability.no-grafana.golden.yaml new file mode 100644 index 000000000000..25e5d3106457 --- /dev/null +++ b/app/kumactl/cmd/install/testdata/install-observability.no-grafana.golden.yaml @@ -0,0 +1,1585 @@ + +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability + labels: + kuma.io/sidecar-injection: enabled + annotations: + kuma.io/mesh: default +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: mesh-observability +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +--- +apiVersion: v1 +kind: ConfigMap +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +data: + alerting_rules.yml: | + {} + alerts: | + {} + prometheus.yml: | + global: + evaluation_interval: 1m + scrape_interval: 10s + scrape_timeout: 10s + rule_files: + - /etc/config/recording_rules.yml + - /etc/config/alerting_rules.yml + - /etc/config/rules + - /etc/config/alerts + scrape_configs: + - job_name: prometheus + static_configs: + - targets: + - localhost:9090 + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-apiservers + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: default;kubernetes;https + source_labels: + - __meta_kubernetes_namespace + - __meta_kubernetes_service_name + - __meta_kubernetes_endpoint_port_name + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-nodes + kubernetes_sd_configs: + - role: node + relabel_configs: + - action: labelmap + regex: __meta_kubernetes_node_label_(.+) + - replacement: kubernetes.default.svc:443 + target_label: __address__ + - regex: (.+) + replacement: /api/v1/nodes/$1/proxy/metrics + source_labels: + - __meta_kubernetes_node_name + target_label: __metrics_path__ + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-nodes-cadvisor + kubernetes_sd_configs: + - role: node + relabel_configs: + - action: labelmap + regex: __meta_kubernetes_node_label_(.+) + - replacement: kubernetes.default.svc:443 + target_label: __address__ + - regex: (.+) + replacement: /api/v1/nodes/$1/proxy/metrics/cadvisor + source_labels: + - __meta_kubernetes_node_name + target_label: __metrics_path__ + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - job_name: kubernetes-service-endpoints + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scrape + - action: replace + regex: (https?) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scheme + target_label: __scheme__ + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_service_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - action: replace + source_labels: + - __meta_kubernetes_pod_node_name + target_label: kubernetes_node + - job_name: kubernetes-service-endpoints-slow + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scrape_slow + - action: replace + regex: (https?) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scheme + target_label: __scheme__ + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_service_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - action: replace + source_labels: + - __meta_kubernetes_pod_node_name + target_label: kubernetes_node + scrape_interval: 5m + scrape_timeout: 30s + - honor_labels: true + job_name: prometheus-pushgateway + kubernetes_sd_configs: + - role: service + relabel_configs: + - action: keep + regex: pushgateway + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_probe + - job_name: kubernetes-services + kubernetes_sd_configs: + - role: service + metrics_path: /probe + params: + module: + - http_2xx + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_probe + - source_labels: + - __address__ + target_label: __param_target + - replacement: blackbox + target_label: __address__ + - source_labels: + - __param_target + target_label: instance + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - job_name: kubernetes-pods + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_scrape + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_pod_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: kubernetes_pod_name + - job_name: kubernetes-pods-slow + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_scrape_slow + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_pod_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: kubernetes_pod_name + scrape_interval: 5m + scrape_timeout: 30s + - job_name: 'kuma-dataplanes' + scrape_interval: "5s" + relabel_configs: + - source_labels: + - k8s_kuma_io_name + regex: "(.*)" + target_label: pod + - source_labels: + - k8s_kuma_io_namespace + regex: "(.*)" + target_label: namespace + - source_labels: + - __meta_kuma_mesh + regex: "(.*)" + target_label: mesh + - source_labels: + - __meta_kuma_dataplane + regex: "(.*)" + target_label: dataplane + - source_labels: + - __meta_kuma_service + regex: "(.*)" + target_label: service + - action: labelmap + regex: __meta_kuma_label_(.+) + kuma_sd_configs: + - server: http://kuma-control-plane.kuma-system:5676 + alerting: + alertmanagers: + - kubernetes_sd_configs: + - role: pod + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + relabel_configs: + - source_labels: [__meta_kubernetes_namespace] + regex: default + action: keep + - source_labels: [__meta_kubernetes_pod_label_app] + regex: prometheus + action: keep + - source_labels: [__meta_kubernetes_pod_label_component] + regex: alertmanager + action: keep + - source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_probe] + regex: .* + action: keep + - source_labels: [__meta_kubernetes_pod_container_port_number] + regex: + action: drop + recording_rules.yml: | + {} + rules: | + {} +--- +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "8Gi" +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics +rules: + - apiGroups: + - "" + resources: + - namespaces + - nodes + - persistentvolumeclaims + - pods + - services + - resourcequotas + - replicationcontrollers + - limitranges + - persistentvolumeclaims + - persistentvolumes + - endpoints + - secrets + - configmaps + verbs: + - list + - watch + - apiGroups: + - extensions + resources: + - daemonsets + - deployments + - ingresses + - replicasets + verbs: + - list + - watch + - apiGroups: + - apps + resources: + - daemonsets + - deployments + - statefulsets + - replicasets + verbs: + - get + - list + - watch + - apiGroups: + - batch + resources: + - cronjobs + - jobs + verbs: + - list + - watch + - apiGroups: + - autoscaling + resources: + - horizontalpodautoscalers + verbs: + - list + - watch + - apiGroups: + - policy + resources: + - poddisruptionbudgets + verbs: + - list + - watch + - apiGroups: + - storage.k8s.io + resources: + - storageclasses + - volumeattachments + verbs: + - list + - watch + - apiGroups: + - certificates.k8s.io + resources: + - certificatesigningrequests + verbs: + - list + - watch + - apiGroups: + - networking.k8s.io + resources: + - networkpolicies + verbs: + - list + - watch + - apiGroups: + - admissionregistration.k8s.io + resources: + - validatingwebhookconfigurations + - mutatingwebhookconfigurations + verbs: + - list + - watch +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server +rules: + - apiGroups: + - "" + resources: + - nodes + - nodes/proxy + - nodes/metrics + - services + - endpoints + - pods + - ingresses + - configmaps + verbs: + - get + - list + - watch + - apiGroups: + - "extensions" + resources: + - ingresses/status + - ingresses + verbs: + - get + - list + - watch + - nonResourceURLs: + - "/metrics" + verbs: + - get +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server +subjects: + - kind: ServiceAccount + name: prometheus-server + namespace: mesh-observability +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: prometheus-server +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics +subjects: + - kind: ServiceAccount + name: prometheus-kube-state-metrics + namespace: mesh-observability +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: prometheus-kube-state-metrics +--- +apiVersion: v1 +kind: Service +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +spec: + ports: + - name: http + port: 80 + protocol: TCP + targetPort: 9090 + selector: + component: "server" + app: prometheus + sessionAffinity: None + type: "ClusterIP" +--- +apiVersion: v1 +kind: Service +metadata: + annotations: + prometheus.io/scrape: "true" + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: mesh-observability +spec: + clusterIP: None + ports: + - name: http + port: 80 + protocol: TCP + targetPort: 8080 + - name: telemetry + port: 81 + protocol: TCP + targetPort: 8081 + selector: + component: "kube-state-metrics" + app: prometheus + type: "ClusterIP" +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: mesh-observability +spec: + selector: + matchLabels: + component: "server" + app: prometheus + replicas: 1 + template: + metadata: + labels: + component: "server" + app: prometheus + annotations: + kuma.io/direct-access-services: "*" + spec: + serviceAccountName: prometheus-server + containers: + - name: prometheus-server-configmap-reload + image: "jimmidyson/configmap-reload:v0.6.1" + imagePullPolicy: "IfNotPresent" + args: + - --volume-dir=/etc/config + - --webhook-url=http://127.0.0.1:9090/-/reload + resources: + {} + volumeMounts: + - name: config-volume + mountPath: /etc/config + readOnly: true + - name: prometheus-server + image: "prom/prometheus:v2.35.0" + imagePullPolicy: "IfNotPresent" + args: + - --storage.tsdb.retention.time=15d + - --config.file=/etc/config/prometheus.yml + - --storage.tsdb.path=/data + - --web.console.libraries=/etc/prometheus/console_libraries + - --web.console.templates=/etc/prometheus/consoles + - --web.enable-lifecycle + ports: + - containerPort: 9090 + resources: + {} + volumeMounts: + - name: config-volume + mountPath: /etc/config + - name: storage-volume + mountPath: /data + subPath: "" + securityContext: + fsGroup: 65534 + runAsGroup: 65534 + runAsUser: 65534 + terminationGracePeriodSeconds: 300 + volumes: + - name: config-volume + configMap: + name: prometheus-server + - name: storage-volume + persistentVolumeClaim: + claimName: prometheus-server +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: mesh-observability +spec: + selector: + matchLabels: + component: "kube-state-metrics" + app: prometheus + replicas: 1 + template: + metadata: + labels: + component: "kube-state-metrics" + app: prometheus + spec: + serviceAccountName: prometheus-kube-state-metrics + containers: + - name: prometheus-kube-state-metrics + image: "quay.io/coreos/kube-state-metrics:v1.9.8" + imagePullPolicy: "IfNotPresent" + ports: + - name: metrics + containerPort: 8080 + - name: telemetry + containerPort: 8081 + resources: + {} + securityContext: + runAsUser: 65534 +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'configMap' + - 'emptyDir' + - 'persistentVolumeClaim' + - 'secret' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'MustRunAsNonRoot' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + fsGroup: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'secret' + - 'configMap' + - 'hostPath' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'RunAsAny' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'RunAsAny' + fsGroup: + rule: 'RunAsAny' + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: loki + release: loki + annotations: + {} + name: loki + namespace: mesh-observability +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: promtail + release: loki + name: loki-promtail + namespace: mesh-observability +--- +apiVersion: v1 +kind: Secret +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +data: + loki.yaml: YXV0aF9lbmFibGVkOiBmYWxzZQpjaHVua19zdG9yZV9jb25maWc6CiAgbWF4X2xvb2tfYmFja19wZXJpb2Q6IDBzCmluZ2VzdGVyOgogIGNodW5rX2Jsb2NrX3NpemU6IDI2MjE0NAogIGNodW5rX2lkbGVfcGVyaW9kOiAzbQogIGNodW5rX3JldGFpbl9wZXJpb2Q6IDFtCiAgbGlmZWN5Y2xlcjoKICAgIHJpbmc6CiAgICAgIGt2c3RvcmU6CiAgICAgICAgc3RvcmU6IGlubWVtb3J5CiAgICAgIHJlcGxpY2F0aW9uX2ZhY3RvcjogMQogIHdhbDoKICAgIGVuYWJsZWQ6IGZhbHNlCmxpbWl0c19jb25maWc6CiAgZW5mb3JjZV9tZXRyaWNfbmFtZTogZmFsc2UKc2NoZW1hX2NvbmZpZzoKICBjb25maWdzOgogIC0gZnJvbTogIjIwMTgtMDQtMTUiCiAgICBpbmRleDoKICAgICAgcGVyaW9kOiAxNjhoCiAgICAgIHByZWZpeDogaW5kZXhfCiAgICBvYmplY3Rfc3RvcmU6IGZpbGVzeXN0ZW0KICAgIHNjaGVtYTogdjkKICAgIHN0b3JlOiBib2x0ZGIKc2VydmVyOgogIGh0dHBfbGlzdGVuX3BvcnQ6IDMxMDAKc3RvcmFnZV9jb25maWc6CiAgYm9sdGRiOgogICAgZGlyZWN0b3J5OiAvZGF0YS9sb2tpL2luZGV4CiAgZmlsZXN5c3RlbToKICAgIGRpcmVjdG9yeTogL2RhdGEvbG9raS9jaHVua3MKdGFibGVfbWFuYWdlcjoKICByZXRlbnRpb25fZGVsZXRlc19lbmFibGVkOiBmYWxzZQogIHJldGVudGlvbl9wZXJpb2Q6IDBzCg== +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +data: + promtail.yaml: | + client: + backoff_config: + max_period: 5s + max_retries: 20 + min_period: 100ms + batchsize: 102400 + batchwait: 1s + external_labels: {} + timeout: 10s + positions: + filename: /run/promtail/positions.yaml + server: + http_listen_port: 3101 + target_config: + sync_period: 10s + scrape_configs: + - job_name: kubernetes-pods-name + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - source_labels: + - __meta_kubernetes_pod_label_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-app + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - action: drop + regex: .+ + source_labels: + - __meta_kubernetes_pod_label_name + - source_labels: + - __meta_kubernetes_pod_label_app + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-direct-controllers + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: drop + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-indirect-controller + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: keep + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - action: replace + regex: '([0-9a-z-.]+)-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-static + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: '' + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - action: replace + source_labels: + - __meta_kubernetes_pod_label_component + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - __meta_kubernetes_pod_container_name + target_label: __path__ +--- +kind: ClusterRole +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + labels: + app: promtail + release: loki + name: loki-promtail-clusterrole + namespace: mesh-observability +rules: + - apiGroups: [""] # "" indicates the core API group + resources: + - nodes + - nodes/proxy + - services + - endpoints + - pods + verbs: ["get", "watch", "list"] +--- +kind: ClusterRoleBinding +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + name: loki-promtail-clusterrolebinding + labels: + app: promtail + release: loki +subjects: + - kind: ServiceAccount + name: loki-promtail + namespace: mesh-observability +roleRef: + kind: ClusterRole + name: loki-promtail-clusterrole + apiGroup: rbac.authorization.k8s.io +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki-promtail] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki +subjects: + - kind: ServiceAccount + name: loki +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki-promtail +subjects: + - kind: ServiceAccount + name: loki-promtail +--- +apiVersion: v1 +kind: Service +metadata: + name: loki-headless + namespace: mesh-observability + labels: + app: loki + release: loki + variant: headless +spec: + clusterIP: None + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: v1 +kind: Service +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + type: ClusterIP + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: apps/v1 +kind: DaemonSet +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki + annotations: + {} +spec: + selector: + matchLabels: + app: promtail + release: loki + updateStrategy: + {} + template: + metadata: + labels: + app: promtail + release: loki + annotations: + checksum/config: bce7daf9d5acc773342c4f42e700668ef8bdc8f34fa1499c766263fa0c1944e0 + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki-promtail + containers: + - name: promtail + image: "grafana/promtail:2.4.1" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/promtail/promtail.yaml" + - "-client.url=http://loki.mesh-observability:3100/loki/api/v1/push" + volumeMounts: + - name: config + mountPath: /etc/promtail + - name: run + mountPath: /run/promtail + - mountPath: /var/lib/docker/containers + name: docker + readOnly: true + - mountPath: /var/log/pods + name: pods + readOnly: true + env: + - name: HOSTNAME + valueFrom: + fieldRef: + fieldPath: spec.nodeName + ports: + - containerPort: 3101 + name: http-metrics + securityContext: + readOnlyRootFilesystem: true + runAsGroup: 0 + runAsUser: 0 + readinessProbe: + failureThreshold: 5 + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 + resources: + {} + nodeSelector: + {} + affinity: + {} + tolerations: + - effect: NoSchedule + key: node-role.kubernetes.io/master + operator: Exists + volumes: + - name: config + configMap: + name: loki-promtail + - name: run + hostPath: + path: /run/promtail + - hostPath: + path: /var/lib/docker/containers + name: docker + - hostPath: + path: /var/log/pods + name: pods +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app: loki + release: loki + serviceName: loki-headless + updateStrategy: + type: RollingUpdate + template: + metadata: + labels: + app: loki + name: loki + release: loki + annotations: + checksum/config: d4c94f4c6a73353362c10d2f844340cec8999b291ca88481ac162fbb5942617d + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + initContainers: + [] + containers: + - name: loki + image: "grafana/loki:2.5.0" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/loki/loki.yaml" + - "-target=all,table-manager" + volumeMounts: + - name: config + mountPath: /etc/loki + - name: storage + mountPath: "/data" + ports: + - name: http-metrics + containerPort: 3100 + protocol: TCP + livenessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + {} + securityContext: + readOnlyRootFilesystem: true + nodeSelector: + {} + affinity: + {} + tolerations: + [] + terminationGracePeriodSeconds: 4800 + volumes: + - name: config + secret: + secretName: loki + - name: storage + emptyDir: {} +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +# Based on https://github.com/jaegertracing/jaeger-kubernetes/blob/master/all-in-one/jaeger-all-in-one-template.yml + +# +# Copyright 2017-2019 The Jaeger 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. +# + +apiVersion: v1 +kind: List +items: + - apiVersion: apps/v1 + kind: Deployment + metadata: + name: jaeger + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + spec: + replicas: 1 + selector: + matchLabels: + app: jaeger + strategy: + type: Recreate + template: + metadata: + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + annotations: + prometheus.io/scrape: "true" + prometheus.io/port: "16686" + spec: + containers: + - env: + - name: COLLECTOR_ZIPKIN_HOST_PORT + value: "9411" + image: jaegertracing/all-in-one:1.34.1 + name: jaeger + ports: + - containerPort: 5775 + protocol: UDP + - containerPort: 6831 + protocol: UDP + - containerPort: 6832 + protocol: UDP + - containerPort: 5778 + protocol: TCP + - containerPort: 16686 + protocol: TCP + - containerPort: 9411 + protocol: TCP + readinessProbe: + httpGet: + path: "/" + port: 14269 + initialDelaySeconds: 5 + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-query + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: query + spec: + selector: + matchLabels: + app: jaeger-query + ports: + - name: query-http + port: 80 + protocol: TCP + targetPort: 16686 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-collector + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: collector + spec: + selector: + matchLabels: + app: jaeger-collector + ports: + - name: jaeger-collector-tchannel + port: 14267 + protocol: TCP + targetPort: 14267 + - name: jaeger-collector-http + port: 14268 + protocol: TCP + targetPort: 14268 + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-agent + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: agent + spec: + selector: + matchLabels: + app: jaeger-agent + ports: + - name: agent-zipkin-thrift + port: 5775 + protocol: UDP + targetPort: 5775 + - name: agent-compact + port: 6831 + protocol: UDP + targetPort: 6831 + - name: agent-binary + port: 6832 + protocol: UDP + targetPort: 6832 + - name: agent-configs + port: 5778 + protocol: TCP + targetPort: 5778 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + - apiVersion: v1 + kind: Service + metadata: + name: zipkin + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: zipkin + spec: + selector: + matchLabels: + app: zipkin + ports: + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one diff --git a/app/kumactl/cmd/install/testdata/install-metrics.defaults.golden.yaml b/app/kumactl/cmd/install/testdata/install-observability.no-jaeger.golden.yaml similarity index 94% rename from app/kumactl/cmd/install/testdata/install-metrics.defaults.golden.yaml rename to app/kumactl/cmd/install/testdata/install-observability.no-jaeger.golden.yaml index 5304a5d385b5..7ce5fb494ca0 100644 --- a/app/kumactl/cmd/install/testdata/install-metrics.defaults.golden.yaml +++ b/app/kumactl/cmd/install/testdata/install-observability.no-jaeger.golden.yaml @@ -3,7 +3,7 @@ apiVersion: v1 kind: Namespace metadata: - name: kuma-metrics + name: mesh-observability labels: kuma.io/sidecar-injection: enabled annotations: @@ -13,7 +13,7 @@ apiVersion: policy/v1beta1 kind: PodSecurityPolicy metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana annotations: @@ -60,39 +60,12 @@ spec: --- apiVersion: v1 kind: ServiceAccount -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ServiceAccount metadata: labels: component: "kube-state-metrics" app: prometheus name: prometheus-kube-state-metrics - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma-metrics ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma-metrics + namespace: mesh-observability --- apiVersion: v1 kind: ServiceAccount @@ -101,7 +74,7 @@ metadata: component: "server" app: prometheus name: prometheus-server - namespace: kuma-metrics + namespace: mesh-observability --- apiVersion: v1 kind: ServiceAccount @@ -109,13 +82,13 @@ metadata: labels: app: grafana name: grafana - namespace: kuma-metrics + namespace: mesh-observability --- apiVersion: v1 kind: ConfigMap metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -137,28 +110,9 @@ data: --- apiVersion: v1 kind: ConfigMap -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -data: - alertmanager.yml: | - global: {} - receivers: - - name: default-receiver - route: - group_interval: 5m - group_wait: 10s - receiver: default-receiver - repeat_interval: 3h ---- -apiVersion: v1 -kind: ConfigMap metadata: name: provisioning-datasource - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -184,7 +138,7 @@ data: # org id. will default to orgId 1 if not specified orgId: 1 # url - url: http://prometheus-server.kuma-metrics + url: http://prometheus-server.mesh-observability # database password, if used password: # database user, if used @@ -226,7 +180,7 @@ data: access: proxy editable: true uid: jaeger - url: http://jaeger-query.kuma-tracing + url: http://jaeger-query.mesh-observability jsonData: tracesToLogs: datasourceUid: loki @@ -236,7 +190,7 @@ data: access: proxy editable: true uid: loki - url: http://loki.kuma-logging:3100 + url: http://loki.mesh-observability:3100 jsonData: derivedFields: - datasourceUid: jaeger @@ -246,33 +200,12 @@ data: --- apiVersion: v1 kind: ConfigMap -metadata: - name: provisioning-dashboards - namespace: kuma-metrics - labels: - app: grafana -data: - dashboards.yaml: | - apiVersion: 1 - - providers: - - name: 'Prometheus' - orgId: 1 - folder: '' - type: file - disableDeletion: false - editable: true - options: - path: /etc/grafana/provisioning/dashboards ---- -apiVersion: v1 -kind: ConfigMap metadata: labels: component: "server" app: prometheus name: prometheus-server - namespace: kuma-metrics + namespace: mesh-observability data: alerting_rules.yml: | {} @@ -580,9 +513,30 @@ data: --- apiVersion: v1 kind: ConfigMap +metadata: + name: provisioning-dashboards + namespace: mesh-observability + labels: + app: grafana +data: + dashboards.yaml: | + apiVersion: 1 + + providers: + - name: 'Prometheus' + orgId: 1 + folder: '' + type: file + disableDeletion: false + editable: true + options: + path: /etc/grafana/provisioning/dashboards +--- +apiVersion: v1 +kind: ConfigMap metadata: name: provisioning-dashboards-0 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -3414,7 +3368,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-1 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -4682,7 +4636,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-2 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -6072,7 +6026,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-3 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -9872,7 +9826,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-4 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -10925,27 +10879,12 @@ data: --- apiVersion: v1 kind: PersistentVolumeClaim -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -spec: - accessModes: - - ReadWriteOnce - resources: - requests: - storage: "2Gi" ---- -apiVersion: v1 -kind: PersistentVolumeClaim metadata: labels: component: "server" app: prometheus name: prometheus-server - namespace: kuma-metrics + namespace: mesh-observability spec: accessModes: - ReadWriteOnce @@ -10963,16 +10902,6 @@ rules: [] --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole metadata: labels: component: "kube-state-metrics" @@ -11074,16 +11003,6 @@ rules: --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole metadata: labels: component: "server" @@ -11128,7 +11047,7 @@ metadata: subjects: - kind: ServiceAccount name: grafana - namespace: kuma-metrics + namespace: mesh-observability roleRef: kind: ClusterRole name: grafana-clusterrole @@ -11136,22 +11055,6 @@ roleRef: --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -subjects: - - kind: ServiceAccount - name: prometheus-alertmanager - namespace: kuma-metrics -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-alertmanager ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding metadata: labels: component: "kube-state-metrics" @@ -11160,7 +11063,7 @@ metadata: subjects: - kind: ServiceAccount name: prometheus-kube-state-metrics - namespace: kuma-metrics + namespace: mesh-observability roleRef: apiGroup: rbac.authorization.k8s.io kind: ClusterRole @@ -11168,22 +11071,6 @@ roleRef: --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -subjects: - - kind: ServiceAccount - name: prometheus-pushgateway - namespace: kuma-metrics -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-pushgateway ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding metadata: labels: component: "server" @@ -11192,7 +11079,7 @@ metadata: subjects: - kind: ServiceAccount name: prometheus-server - namespace: kuma-metrics + namespace: mesh-observability roleRef: apiGroup: rbac.authorization.k8s.io kind: ClusterRole @@ -11202,7 +11089,7 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana rules: @@ -11225,13 +11112,13 @@ roleRef: subjects: - kind: ServiceAccount name: grafana - namespace: kuma-metrics + namespace: mesh-observability --- apiVersion: v1 kind: Service metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana spec: @@ -11246,26 +11133,6 @@ spec: --- apiVersion: v1 kind: Service -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -spec: - ports: - - name: http - port: 80 - protocol: TCP - targetPort: 9093 - selector: - component: alertmanager - app: prometheus - sessionAffinity: None - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service metadata: annotations: prometheus.io/scrape: "true" @@ -11273,7 +11140,7 @@ metadata: component: "kube-state-metrics" app: prometheus name: prometheus-kube-state-metrics - namespace: kuma-metrics + namespace: mesh-observability spec: clusterIP: None ports: @@ -11292,55 +11159,12 @@ spec: --- apiVersion: v1 kind: Service -metadata: - annotations: - prometheus.io/scrape: "true" - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma-metrics -spec: - clusterIP: None - ports: - - name: metrics - port: 9100 - protocol: TCP - targetPort: 9100 - selector: - component: "node-exporter" - app: prometheus - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service -metadata: - annotations: - prometheus.io/probe: pushgateway - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma-metrics -spec: - ports: - - name: http - port: 9091 - protocol: TCP - targetPort: 9091 - selector: - component: "pushgateway" - app: prometheus - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service metadata: labels: component: "server" app: prometheus name: prometheus-server - namespace: kuma-metrics + namespace: mesh-observability spec: ports: - name: http @@ -11354,63 +11178,10 @@ spec: type: "ClusterIP" --- apiVersion: apps/v1 -kind: DaemonSet -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "node-exporter" - app: prometheus - updateStrategy: - type: RollingUpdate - template: - metadata: - labels: - component: "node-exporter" - app: prometheus - kuma.io/sidecar-injection: "disabled" # disabled for now, injecting DP crashes K8S cluster - spec: - serviceAccountName: prometheus-node-exporter - containers: - - name: prometheus-node-exporter - image: "prom/node-exporter:v1.3.1" - imagePullPolicy: "IfNotPresent" - args: - - --path.procfs=/host/proc - - --path.sysfs=/host/sys - ports: - - name: metrics - containerPort: 9100 - hostPort: 9100 - resources: - {} - volumeMounts: - - name: proc - mountPath: /host/proc - readOnly: true - - name: sys - mountPath: /host/sys - readOnly: true - hostNetwork: true - hostPID: true - volumes: - - name: proc - hostPath: - path: /proc - - name: sys - hostPath: - path: /sys ---- -apiVersion: apps/v1 kind: Deployment metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana spec: @@ -11443,7 +11214,7 @@ spec: mountPath: /var/lib/grafana/plugins containers: - name: grafana - image: "grafana/grafana:8.3.3" + image: "grafana/grafana:8.5.2" imagePullPolicy: IfNotPresent volumeMounts: - name: config @@ -11514,77 +11285,6 @@ spec: - name: plugins-volume emptyDir: {} --- -# Source: prometheus/templates/alertmanager-deployment.yaml -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "alertmanager" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "alertmanager" - app: prometheus - spec: - serviceAccountName: prometheus-alertmanager - containers: - - name: prometheus-alertmanager - image: "prom/alertmanager:v0.23.0" - imagePullPolicy: "IfNotPresent" - env: - - name: POD_IP - valueFrom: - fieldRef: - apiVersion: v1 - fieldPath: status.podIP - args: - - --config.file=/etc/config/alertmanager.yml - - --storage.path=/data - - --cluster.advertise-address=$(POD_IP):6783 - - --web.external-url=http://localhost:9093 - ports: - - containerPort: 9093 - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - - name: storage-volume - mountPath: "/data" - subPath: "" - - name: prometheus-alertmanager-configmap-reload - image: "jimmidyson/configmap-reload:v0.6.1" - imagePullPolicy: "IfNotPresent" - args: - - --volume-dir=/etc/config - - --webhook-url=http://127.0.0.1:9093/-/reload - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - readOnly: true - securityContext: - fsGroup: 65534 - runAsGroup: 65534 - runAsUser: 65534 - volumes: - - name: config-volume - configMap: - name: prometheus-alertmanager - - name: storage-volume - persistentVolumeClaim: - claimName: prometheus-alertmanager ---- apiVersion: apps/v1 kind: Deployment metadata: @@ -11592,7 +11292,7 @@ metadata: component: "kube-state-metrics" app: prometheus name: prometheus-kube-state-metrics - namespace: kuma-metrics + namespace: mesh-observability spec: selector: matchLabels: @@ -11624,65 +11324,32 @@ apiVersion: apps/v1 kind: Deployment metadata: labels: - component: "pushgateway" + component: "server" app: prometheus - name: prometheus-pushgateway - namespace: kuma-metrics + name: prometheus-server + namespace: mesh-observability spec: selector: matchLabels: - component: "pushgateway" + component: "server" app: prometheus replicas: 1 template: metadata: labels: - component: "pushgateway" + component: "server" app: prometheus + annotations: + kuma.io/direct-access-services: "*" spec: - serviceAccountName: prometheus-pushgateway + serviceAccountName: prometheus-server containers: - - name: prometheus-pushgateway - image: "prom/pushgateway:v1.4.2" + - name: prometheus-server-configmap-reload + image: "jimmidyson/configmap-reload:v0.6.1" imagePullPolicy: "IfNotPresent" args: - ports: - - containerPort: 9091 - resources: - {} - securityContext: - runAsUser: 65534 ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "server" - app: prometheus - name: prometheus-server - namespace: kuma-metrics -spec: - selector: - matchLabels: - component: "server" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "server" - app: prometheus - annotations: - kuma.io/direct-access-services: "*" - spec: - serviceAccountName: prometheus-server - containers: - - name: prometheus-server-configmap-reload - image: "jimmidyson/configmap-reload:v0.6.1" - imagePullPolicy: "IfNotPresent" - args: - - --volume-dir=/etc/config - - --webhook-url=http://127.0.0.1:9090/-/reload + - --volume-dir=/etc/config + - --webhook-url=http://127.0.0.1:9090/-/reload resources: {} volumeMounts: @@ -11690,7 +11357,7 @@ spec: mountPath: /etc/config readOnly: true - name: prometheus-server - image: "prom/prometheus:v2.32.1" + image: "prom/prometheus:v2.35.0" imagePullPolicy: "IfNotPresent" args: - --storage.tsdb.retention.time=15d @@ -11721,3 +11388,734 @@ spec: - name: storage-volume persistentVolumeClaim: claimName: prometheus-server +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'configMap' + - 'emptyDir' + - 'persistentVolumeClaim' + - 'secret' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'MustRunAsNonRoot' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + fsGroup: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'secret' + - 'configMap' + - 'hostPath' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'RunAsAny' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'RunAsAny' + fsGroup: + rule: 'RunAsAny' + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: loki + release: loki + annotations: + {} + name: loki + namespace: mesh-observability +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: promtail + release: loki + name: loki-promtail + namespace: mesh-observability +--- +apiVersion: v1 +kind: Secret +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +data: + loki.yaml: YXV0aF9lbmFibGVkOiBmYWxzZQpjaHVua19zdG9yZV9jb25maWc6CiAgbWF4X2xvb2tfYmFja19wZXJpb2Q6IDBzCmluZ2VzdGVyOgogIGNodW5rX2Jsb2NrX3NpemU6IDI2MjE0NAogIGNodW5rX2lkbGVfcGVyaW9kOiAzbQogIGNodW5rX3JldGFpbl9wZXJpb2Q6IDFtCiAgbGlmZWN5Y2xlcjoKICAgIHJpbmc6CiAgICAgIGt2c3RvcmU6CiAgICAgICAgc3RvcmU6IGlubWVtb3J5CiAgICAgIHJlcGxpY2F0aW9uX2ZhY3RvcjogMQogIHdhbDoKICAgIGVuYWJsZWQ6IGZhbHNlCmxpbWl0c19jb25maWc6CiAgZW5mb3JjZV9tZXRyaWNfbmFtZTogZmFsc2UKc2NoZW1hX2NvbmZpZzoKICBjb25maWdzOgogIC0gZnJvbTogIjIwMTgtMDQtMTUiCiAgICBpbmRleDoKICAgICAgcGVyaW9kOiAxNjhoCiAgICAgIHByZWZpeDogaW5kZXhfCiAgICBvYmplY3Rfc3RvcmU6IGZpbGVzeXN0ZW0KICAgIHNjaGVtYTogdjkKICAgIHN0b3JlOiBib2x0ZGIKc2VydmVyOgogIGh0dHBfbGlzdGVuX3BvcnQ6IDMxMDAKc3RvcmFnZV9jb25maWc6CiAgYm9sdGRiOgogICAgZGlyZWN0b3J5OiAvZGF0YS9sb2tpL2luZGV4CiAgZmlsZXN5c3RlbToKICAgIGRpcmVjdG9yeTogL2RhdGEvbG9raS9jaHVua3MKdGFibGVfbWFuYWdlcjoKICByZXRlbnRpb25fZGVsZXRlc19lbmFibGVkOiBmYWxzZQogIHJldGVudGlvbl9wZXJpb2Q6IDBzCg== +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +data: + promtail.yaml: | + client: + backoff_config: + max_period: 5s + max_retries: 20 + min_period: 100ms + batchsize: 102400 + batchwait: 1s + external_labels: {} + timeout: 10s + positions: + filename: /run/promtail/positions.yaml + server: + http_listen_port: 3101 + target_config: + sync_period: 10s + scrape_configs: + - job_name: kubernetes-pods-name + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - source_labels: + - __meta_kubernetes_pod_label_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-app + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - action: drop + regex: .+ + source_labels: + - __meta_kubernetes_pod_label_name + - source_labels: + - __meta_kubernetes_pod_label_app + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-direct-controllers + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: drop + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-indirect-controller + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: keep + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - action: replace + regex: '([0-9a-z-.]+)-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-static + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: '' + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - action: replace + source_labels: + - __meta_kubernetes_pod_label_component + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - __meta_kubernetes_pod_container_name + target_label: __path__ +--- +kind: ClusterRole +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + labels: + app: promtail + release: loki + name: loki-promtail-clusterrole + namespace: mesh-observability +rules: + - apiGroups: [""] # "" indicates the core API group + resources: + - nodes + - nodes/proxy + - services + - endpoints + - pods + verbs: ["get", "watch", "list"] +--- +kind: ClusterRoleBinding +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + name: loki-promtail-clusterrolebinding + labels: + app: promtail + release: loki +subjects: + - kind: ServiceAccount + name: loki-promtail + namespace: mesh-observability +roleRef: + kind: ClusterRole + name: loki-promtail-clusterrole + apiGroup: rbac.authorization.k8s.io +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki-promtail] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki +subjects: + - kind: ServiceAccount + name: loki +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki-promtail +subjects: + - kind: ServiceAccount + name: loki-promtail +--- +apiVersion: v1 +kind: Service +metadata: + name: loki-headless + namespace: mesh-observability + labels: + app: loki + release: loki + variant: headless +spec: + clusterIP: None + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: v1 +kind: Service +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + type: ClusterIP + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: apps/v1 +kind: DaemonSet +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki + annotations: + {} +spec: + selector: + matchLabels: + app: promtail + release: loki + updateStrategy: + {} + template: + metadata: + labels: + app: promtail + release: loki + annotations: + checksum/config: bce7daf9d5acc773342c4f42e700668ef8bdc8f34fa1499c766263fa0c1944e0 + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki-promtail + containers: + - name: promtail + image: "grafana/promtail:2.4.1" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/promtail/promtail.yaml" + - "-client.url=http://loki.mesh-observability:3100/loki/api/v1/push" + volumeMounts: + - name: config + mountPath: /etc/promtail + - name: run + mountPath: /run/promtail + - mountPath: /var/lib/docker/containers + name: docker + readOnly: true + - mountPath: /var/log/pods + name: pods + readOnly: true + env: + - name: HOSTNAME + valueFrom: + fieldRef: + fieldPath: spec.nodeName + ports: + - containerPort: 3101 + name: http-metrics + securityContext: + readOnlyRootFilesystem: true + runAsGroup: 0 + runAsUser: 0 + readinessProbe: + failureThreshold: 5 + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 + resources: + {} + nodeSelector: + {} + affinity: + {} + tolerations: + - effect: NoSchedule + key: node-role.kubernetes.io/master + operator: Exists + volumes: + - name: config + configMap: + name: loki-promtail + - name: run + hostPath: + path: /run/promtail + - hostPath: + path: /var/lib/docker/containers + name: docker + - hostPath: + path: /var/log/pods + name: pods +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app: loki + release: loki + serviceName: loki-headless + updateStrategy: + type: RollingUpdate + template: + metadata: + labels: + app: loki + name: loki + release: loki + annotations: + checksum/config: d4c94f4c6a73353362c10d2f844340cec8999b291ca88481ac162fbb5942617d + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + initContainers: + [] + containers: + - name: loki + image: "grafana/loki:2.5.0" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/loki/loki.yaml" + - "-target=all,table-manager" + volumeMounts: + - name: config + mountPath: /etc/loki + - name: storage + mountPath: "/data" + ports: + - name: http-metrics + containerPort: 3100 + protocol: TCP + livenessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + {} + securityContext: + readOnlyRootFilesystem: true + nodeSelector: + {} + affinity: + {} + tolerations: + [] + terminationGracePeriodSeconds: 4800 + volumes: + - name: config + secret: + secretName: loki + - name: storage + emptyDir: {} +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability diff --git a/app/kumactl/cmd/install/testdata/install-metrics.overrides.golden.yaml b/app/kumactl/cmd/install/testdata/install-observability.no-loki.golden.yaml similarity index 97% rename from app/kumactl/cmd/install/testdata/install-metrics.overrides.golden.yaml rename to app/kumactl/cmd/install/testdata/install-observability.no-loki.golden.yaml index 05df2a0e16ec..a0949ab693ac 100644 --- a/app/kumactl/cmd/install/testdata/install-metrics.overrides.golden.yaml +++ b/app/kumactl/cmd/install/testdata/install-observability.no-loki.golden.yaml @@ -3,17 +3,17 @@ apiVersion: v1 kind: Namespace metadata: - name: kuma + name: mesh-observability labels: kuma.io/sidecar-injection: enabled annotations: - kuma.io/mesh: mesh-1 + kuma.io/mesh: default --- apiVersion: policy/v1beta1 kind: PodSecurityPolicy metadata: name: grafana - namespace: kuma + namespace: mesh-observability labels: app: grafana annotations: @@ -60,39 +60,12 @@ spec: --- apiVersion: v1 kind: ServiceAccount -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma ---- -apiVersion: v1 -kind: ServiceAccount metadata: labels: component: "kube-state-metrics" app: prometheus name: prometheus-kube-state-metrics - namespace: kuma ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma + namespace: mesh-observability --- apiVersion: v1 kind: ServiceAccount @@ -101,7 +74,7 @@ metadata: component: "server" app: prometheus name: prometheus-server - namespace: kuma + namespace: mesh-observability --- apiVersion: v1 kind: ServiceAccount @@ -109,13 +82,13 @@ metadata: labels: app: grafana name: grafana - namespace: kuma + namespace: mesh-observability --- apiVersion: v1 kind: ConfigMap metadata: name: grafana - namespace: kuma + namespace: mesh-observability labels: app: grafana data: @@ -137,28 +110,9 @@ data: --- apiVersion: v1 kind: ConfigMap -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma -data: - alertmanager.yml: | - global: {} - receivers: - - name: default-receiver - route: - group_interval: 5m - group_wait: 10s - receiver: default-receiver - repeat_interval: 3h ---- -apiVersion: v1 -kind: ConfigMap metadata: name: provisioning-datasource - namespace: kuma + namespace: mesh-observability labels: app: grafana data: @@ -184,7 +138,7 @@ data: # org id. will default to orgId 1 if not specified orgId: 1 # url - url: http://prometheus-server.kuma + url: http://prometheus-server.mesh-observability # database password, if used password: # database user, if used @@ -226,7 +180,7 @@ data: access: proxy editable: true uid: jaeger - url: http://jaeger-query.kuma-tracing + url: http://jaeger-query.mesh-observability jsonData: tracesToLogs: datasourceUid: loki @@ -236,7 +190,7 @@ data: access: proxy editable: true uid: loki - url: http://loki.kuma-logging:3100 + url: http://loki.mesh-observability:3100 jsonData: derivedFields: - datasourceUid: jaeger @@ -246,33 +200,12 @@ data: --- apiVersion: v1 kind: ConfigMap -metadata: - name: provisioning-dashboards - namespace: kuma - labels: - app: grafana -data: - dashboards.yaml: | - apiVersion: 1 - - providers: - - name: 'Prometheus' - orgId: 1 - folder: '' - type: file - disableDeletion: false - editable: true - options: - path: /etc/grafana/provisioning/dashboards ---- -apiVersion: v1 -kind: ConfigMap metadata: labels: component: "server" app: prometheus name: prometheus-server - namespace: kuma + namespace: mesh-observability data: alerting_rules.yml: | {} @@ -549,7 +482,7 @@ data: - action: labelmap regex: __meta_kuma_label_(.+) kuma_sd_configs: - - server: http://kuma.local:5681 + - server: http://kuma-control-plane.kuma-system:5676 alerting: alertmanagers: - kubernetes_sd_configs: @@ -580,9 +513,30 @@ data: --- apiVersion: v1 kind: ConfigMap +metadata: + name: provisioning-dashboards + namespace: mesh-observability + labels: + app: grafana +data: + dashboards.yaml: | + apiVersion: 1 + + providers: + - name: 'Prometheus' + orgId: 1 + folder: '' + type: file + disableDeletion: false + editable: true + options: + path: /etc/grafana/provisioning/dashboards +--- +apiVersion: v1 +kind: ConfigMap metadata: name: provisioning-dashboards-0 - namespace: kuma + namespace: mesh-observability labels: app: grafana data: @@ -3414,7 +3368,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-1 - namespace: kuma + namespace: mesh-observability labels: app: grafana data: @@ -4682,7 +4636,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-2 - namespace: kuma + namespace: mesh-observability labels: app: grafana data: @@ -6072,7 +6026,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-3 - namespace: kuma + namespace: mesh-observability labels: app: grafana data: @@ -9872,7 +9826,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-4 - namespace: kuma + namespace: mesh-observability labels: app: grafana data: @@ -10925,27 +10879,12 @@ data: --- apiVersion: v1 kind: PersistentVolumeClaim -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma -spec: - accessModes: - - ReadWriteOnce - resources: - requests: - storage: "2Gi" ---- -apiVersion: v1 -kind: PersistentVolumeClaim metadata: labels: component: "server" app: prometheus name: prometheus-server - namespace: kuma + namespace: mesh-observability spec: accessModes: - ReadWriteOnce @@ -10963,16 +10902,6 @@ rules: [] --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole metadata: labels: component: "kube-state-metrics" @@ -11074,16 +11003,6 @@ rules: --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole metadata: labels: component: "server" @@ -11128,7 +11047,7 @@ metadata: subjects: - kind: ServiceAccount name: grafana - namespace: kuma + namespace: mesh-observability roleRef: kind: ClusterRole name: grafana-clusterrole @@ -11136,22 +11055,6 @@ roleRef: --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -subjects: - - kind: ServiceAccount - name: prometheus-alertmanager - namespace: kuma -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-alertmanager ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding metadata: labels: component: "kube-state-metrics" @@ -11160,7 +11063,7 @@ metadata: subjects: - kind: ServiceAccount name: prometheus-kube-state-metrics - namespace: kuma + namespace: mesh-observability roleRef: apiGroup: rbac.authorization.k8s.io kind: ClusterRole @@ -11168,22 +11071,6 @@ roleRef: --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -subjects: - - kind: ServiceAccount - name: prometheus-pushgateway - namespace: kuma -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-pushgateway ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding metadata: labels: component: "server" @@ -11192,7 +11079,7 @@ metadata: subjects: - kind: ServiceAccount name: prometheus-server - namespace: kuma + namespace: mesh-observability roleRef: apiGroup: rbac.authorization.k8s.io kind: ClusterRole @@ -11202,7 +11089,7 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: grafana - namespace: kuma + namespace: mesh-observability labels: app: grafana rules: @@ -11225,13 +11112,13 @@ roleRef: subjects: - kind: ServiceAccount name: grafana - namespace: kuma + namespace: mesh-observability --- apiVersion: v1 kind: Service metadata: name: grafana - namespace: kuma + namespace: mesh-observability labels: app: grafana spec: @@ -11246,26 +11133,6 @@ spec: --- apiVersion: v1 kind: Service -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma -spec: - ports: - - name: http - port: 80 - protocol: TCP - targetPort: 9093 - selector: - component: alertmanager - app: prometheus - sessionAffinity: None - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service metadata: annotations: prometheus.io/scrape: "true" @@ -11273,7 +11140,7 @@ metadata: component: "kube-state-metrics" app: prometheus name: prometheus-kube-state-metrics - namespace: kuma + namespace: mesh-observability spec: clusterIP: None ports: @@ -11292,55 +11159,12 @@ spec: --- apiVersion: v1 kind: Service -metadata: - annotations: - prometheus.io/scrape: "true" - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma -spec: - clusterIP: None - ports: - - name: metrics - port: 9100 - protocol: TCP - targetPort: 9100 - selector: - component: "node-exporter" - app: prometheus - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service -metadata: - annotations: - prometheus.io/probe: pushgateway - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma -spec: - ports: - - name: http - port: 9091 - protocol: TCP - targetPort: 9091 - selector: - component: "pushgateway" - app: prometheus - type: "ClusterIP" ---- -apiVersion: v1 -kind: Service metadata: labels: component: "server" app: prometheus name: prometheus-server - namespace: kuma + namespace: mesh-observability spec: ports: - name: http @@ -11354,63 +11178,10 @@ spec: type: "ClusterIP" --- apiVersion: apps/v1 -kind: DaemonSet -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: kuma -spec: - selector: - matchLabels: - component: "node-exporter" - app: prometheus - updateStrategy: - type: RollingUpdate - template: - metadata: - labels: - component: "node-exporter" - app: prometheus - kuma.io/sidecar-injection: "disabled" # disabled for now, injecting DP crashes K8S cluster - spec: - serviceAccountName: prometheus-node-exporter - containers: - - name: prometheus-node-exporter - image: "prom/node-exporter:v1.3.1" - imagePullPolicy: "IfNotPresent" - args: - - --path.procfs=/host/proc - - --path.sysfs=/host/sys - ports: - - name: metrics - containerPort: 9100 - hostPort: 9100 - resources: - {} - volumeMounts: - - name: proc - mountPath: /host/proc - readOnly: true - - name: sys - mountPath: /host/sys - readOnly: true - hostNetwork: true - hostPID: true - volumes: - - name: proc - hostPath: - path: /proc - - name: sys - hostPath: - path: /sys ---- -apiVersion: apps/v1 kind: Deployment metadata: name: grafana - namespace: kuma + namespace: mesh-observability labels: app: grafana spec: @@ -11443,7 +11214,7 @@ spec: mountPath: /var/lib/grafana/plugins containers: - name: grafana - image: "grafana/grafana:8.3.3" + image: "grafana/grafana:8.5.2" imagePullPolicy: IfNotPresent volumeMounts: - name: config @@ -11514,77 +11285,6 @@ spec: - name: plugins-volume emptyDir: {} --- -# Source: prometheus/templates/alertmanager-deployment.yaml -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: kuma -spec: - selector: - matchLabels: - component: "alertmanager" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "alertmanager" - app: prometheus - spec: - serviceAccountName: prometheus-alertmanager - containers: - - name: prometheus-alertmanager - image: "prom/alertmanager:v0.23.0" - imagePullPolicy: "IfNotPresent" - env: - - name: POD_IP - valueFrom: - fieldRef: - apiVersion: v1 - fieldPath: status.podIP - args: - - --config.file=/etc/config/alertmanager.yml - - --storage.path=/data - - --cluster.advertise-address=$(POD_IP):6783 - - --web.external-url=http://localhost:9093 - ports: - - containerPort: 9093 - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - - name: storage-volume - mountPath: "/data" - subPath: "" - - name: prometheus-alertmanager-configmap-reload - image: "jimmidyson/configmap-reload:v0.6.1" - imagePullPolicy: "IfNotPresent" - args: - - --volume-dir=/etc/config - - --webhook-url=http://127.0.0.1:9093/-/reload - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - readOnly: true - securityContext: - fsGroup: 65534 - runAsGroup: 65534 - runAsUser: 65534 - volumes: - - name: config-volume - configMap: - name: prometheus-alertmanager - - name: storage-volume - persistentVolumeClaim: - claimName: prometheus-alertmanager ---- apiVersion: apps/v1 kind: Deployment metadata: @@ -11592,7 +11292,7 @@ metadata: component: "kube-state-metrics" app: prometheus name: prometheus-kube-state-metrics - namespace: kuma + namespace: mesh-observability spec: selector: matchLabels: @@ -11622,45 +11322,12 @@ spec: --- apiVersion: apps/v1 kind: Deployment -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: kuma -spec: - selector: - matchLabels: - component: "pushgateway" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "pushgateway" - app: prometheus - spec: - serviceAccountName: prometheus-pushgateway - containers: - - name: prometheus-pushgateway - image: "prom/pushgateway:v1.4.2" - imagePullPolicy: "IfNotPresent" - args: - ports: - - containerPort: 9091 - resources: - {} - securityContext: - runAsUser: 65534 ---- -apiVersion: apps/v1 -kind: Deployment metadata: labels: component: "server" app: prometheus name: prometheus-server - namespace: kuma + namespace: mesh-observability spec: selector: matchLabels: @@ -11690,7 +11357,7 @@ spec: mountPath: /etc/config readOnly: true - name: prometheus-server - image: "prom/prometheus:v2.32.1" + image: "prom/prometheus:v2.35.0" imagePullPolicy: "IfNotPresent" args: - --storage.tsdb.retention.time=15d @@ -11721,3 +11388,191 @@ spec: - name: storage-volume persistentVolumeClaim: claimName: prometheus-server +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +# Based on https://github.com/jaegertracing/jaeger-kubernetes/blob/master/all-in-one/jaeger-all-in-one-template.yml + +# +# Copyright 2017-2019 The Jaeger 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. +# + +apiVersion: v1 +kind: List +items: + - apiVersion: apps/v1 + kind: Deployment + metadata: + name: jaeger + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + spec: + replicas: 1 + selector: + matchLabels: + app: jaeger + strategy: + type: Recreate + template: + metadata: + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + annotations: + prometheus.io/scrape: "true" + prometheus.io/port: "16686" + spec: + containers: + - env: + - name: COLLECTOR_ZIPKIN_HOST_PORT + value: "9411" + image: jaegertracing/all-in-one:1.34.1 + name: jaeger + ports: + - containerPort: 5775 + protocol: UDP + - containerPort: 6831 + protocol: UDP + - containerPort: 6832 + protocol: UDP + - containerPort: 5778 + protocol: TCP + - containerPort: 16686 + protocol: TCP + - containerPort: 9411 + protocol: TCP + readinessProbe: + httpGet: + path: "/" + port: 14269 + initialDelaySeconds: 5 + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-query + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: query + spec: + selector: + matchLabels: + app: jaeger-query + ports: + - name: query-http + port: 80 + protocol: TCP + targetPort: 16686 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-collector + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: collector + spec: + selector: + matchLabels: + app: jaeger-collector + ports: + - name: jaeger-collector-tchannel + port: 14267 + protocol: TCP + targetPort: 14267 + - name: jaeger-collector-http + port: 14268 + protocol: TCP + targetPort: 14268 + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-agent + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: agent + spec: + selector: + matchLabels: + app: jaeger-agent + ports: + - name: agent-zipkin-thrift + port: 5775 + protocol: UDP + targetPort: 5775 + - name: agent-compact + port: 6831 + protocol: UDP + targetPort: 6831 + - name: agent-binary + port: 6832 + protocol: UDP + targetPort: 6832 + - name: agent-configs + port: 5778 + protocol: TCP + targetPort: 5778 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + - apiVersion: v1 + kind: Service + metadata: + name: zipkin + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: zipkin + spec: + selector: + matchLabels: + app: zipkin + ports: + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one diff --git a/app/kumactl/cmd/install/testdata/install-metrics.no-prometheus.golden.yaml b/app/kumactl/cmd/install/testdata/install-observability.no-prometheus.golden.yaml similarity index 92% rename from app/kumactl/cmd/install/testdata/install-metrics.no-prometheus.golden.yaml rename to app/kumactl/cmd/install/testdata/install-observability.no-prometheus.golden.yaml index 3c9c1817f90b..230e27430982 100644 --- a/app/kumactl/cmd/install/testdata/install-metrics.no-prometheus.golden.yaml +++ b/app/kumactl/cmd/install/testdata/install-observability.no-prometheus.golden.yaml @@ -3,7 +3,7 @@ apiVersion: v1 kind: Namespace metadata: - name: kuma-metrics + name: mesh-observability labels: kuma.io/sidecar-injection: enabled annotations: @@ -13,7 +13,7 @@ apiVersion: policy/v1beta1 kind: PodSecurityPolicy metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana annotations: @@ -64,13 +64,13 @@ metadata: labels: app: grafana name: grafana - namespace: kuma-metrics + namespace: mesh-observability --- apiVersion: v1 kind: ConfigMap metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -94,7 +94,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-datasource - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -120,7 +120,7 @@ data: # org id. will default to orgId 1 if not specified orgId: 1 # url - url: http://prometheus-server.kuma-metrics + url: http://prometheus-server.mesh-observability # database password, if used password: # database user, if used @@ -162,7 +162,7 @@ data: access: proxy editable: true uid: jaeger - url: http://jaeger-query.kuma-tracing + url: http://jaeger-query.mesh-observability jsonData: tracesToLogs: datasourceUid: loki @@ -172,7 +172,7 @@ data: access: proxy editable: true uid: loki - url: http://loki.kuma-logging:3100 + url: http://loki.mesh-observability:3100 jsonData: derivedFields: - datasourceUid: jaeger @@ -184,7 +184,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -205,7 +205,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-0 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -3037,7 +3037,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-1 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -4305,7 +4305,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-2 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -5695,7 +5695,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-3 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -9495,7 +9495,7 @@ apiVersion: v1 kind: ConfigMap metadata: name: provisioning-dashboards-4 - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana data: @@ -10563,7 +10563,7 @@ metadata: subjects: - kind: ServiceAccount name: grafana - namespace: kuma-metrics + namespace: mesh-observability roleRef: kind: ClusterRole name: grafana-clusterrole @@ -10573,7 +10573,7 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana rules: @@ -10596,13 +10596,13 @@ roleRef: subjects: - kind: ServiceAccount name: grafana - namespace: kuma-metrics + namespace: mesh-observability --- apiVersion: v1 kind: Service metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana spec: @@ -10619,7 +10619,7 @@ apiVersion: apps/v1 kind: Deployment metadata: name: grafana - namespace: kuma-metrics + namespace: mesh-observability labels: app: grafana spec: @@ -10652,7 +10652,7 @@ spec: mountPath: /var/lib/grafana/plugins containers: - name: grafana - image: "grafana/grafana:8.3.3" + image: "grafana/grafana:8.5.2" imagePullPolicy: IfNotPresent volumeMounts: - name: config @@ -10722,3 +10722,912 @@ spec: emptyDir: {} - name: plugins-volume emptyDir: {} +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'configMap' + - 'emptyDir' + - 'persistentVolumeClaim' + - 'secret' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'MustRunAsNonRoot' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + fsGroup: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'secret' + - 'configMap' + - 'hostPath' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'RunAsAny' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'RunAsAny' + fsGroup: + rule: 'RunAsAny' + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: loki + release: loki + annotations: + {} + name: loki + namespace: mesh-observability +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: promtail + release: loki + name: loki-promtail + namespace: mesh-observability +--- +apiVersion: v1 +kind: Secret +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +data: + loki.yaml: YXV0aF9lbmFibGVkOiBmYWxzZQpjaHVua19zdG9yZV9jb25maWc6CiAgbWF4X2xvb2tfYmFja19wZXJpb2Q6IDBzCmluZ2VzdGVyOgogIGNodW5rX2Jsb2NrX3NpemU6IDI2MjE0NAogIGNodW5rX2lkbGVfcGVyaW9kOiAzbQogIGNodW5rX3JldGFpbl9wZXJpb2Q6IDFtCiAgbGlmZWN5Y2xlcjoKICAgIHJpbmc6CiAgICAgIGt2c3RvcmU6CiAgICAgICAgc3RvcmU6IGlubWVtb3J5CiAgICAgIHJlcGxpY2F0aW9uX2ZhY3RvcjogMQogIHdhbDoKICAgIGVuYWJsZWQ6IGZhbHNlCmxpbWl0c19jb25maWc6CiAgZW5mb3JjZV9tZXRyaWNfbmFtZTogZmFsc2UKc2NoZW1hX2NvbmZpZzoKICBjb25maWdzOgogIC0gZnJvbTogIjIwMTgtMDQtMTUiCiAgICBpbmRleDoKICAgICAgcGVyaW9kOiAxNjhoCiAgICAgIHByZWZpeDogaW5kZXhfCiAgICBvYmplY3Rfc3RvcmU6IGZpbGVzeXN0ZW0KICAgIHNjaGVtYTogdjkKICAgIHN0b3JlOiBib2x0ZGIKc2VydmVyOgogIGh0dHBfbGlzdGVuX3BvcnQ6IDMxMDAKc3RvcmFnZV9jb25maWc6CiAgYm9sdGRiOgogICAgZGlyZWN0b3J5OiAvZGF0YS9sb2tpL2luZGV4CiAgZmlsZXN5c3RlbToKICAgIGRpcmVjdG9yeTogL2RhdGEvbG9raS9jaHVua3MKdGFibGVfbWFuYWdlcjoKICByZXRlbnRpb25fZGVsZXRlc19lbmFibGVkOiBmYWxzZQogIHJldGVudGlvbl9wZXJpb2Q6IDBzCg== +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +data: + promtail.yaml: | + client: + backoff_config: + max_period: 5s + max_retries: 20 + min_period: 100ms + batchsize: 102400 + batchwait: 1s + external_labels: {} + timeout: 10s + positions: + filename: /run/promtail/positions.yaml + server: + http_listen_port: 3101 + target_config: + sync_period: 10s + scrape_configs: + - job_name: kubernetes-pods-name + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - source_labels: + - __meta_kubernetes_pod_label_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-app + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - action: drop + regex: .+ + source_labels: + - __meta_kubernetes_pod_label_name + - source_labels: + - __meta_kubernetes_pod_label_app + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-direct-controllers + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: drop + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-indirect-controller + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: keep + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - action: replace + regex: '([0-9a-z-.]+)-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-static + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: '' + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - action: replace + source_labels: + - __meta_kubernetes_pod_label_component + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - __meta_kubernetes_pod_container_name + target_label: __path__ +--- +kind: ClusterRole +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + labels: + app: promtail + release: loki + name: loki-promtail-clusterrole + namespace: mesh-observability +rules: + - apiGroups: [""] # "" indicates the core API group + resources: + - nodes + - nodes/proxy + - services + - endpoints + - pods + verbs: ["get", "watch", "list"] +--- +kind: ClusterRoleBinding +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + name: loki-promtail-clusterrolebinding + labels: + app: promtail + release: loki +subjects: + - kind: ServiceAccount + name: loki-promtail + namespace: mesh-observability +roleRef: + kind: ClusterRole + name: loki-promtail-clusterrole + apiGroup: rbac.authorization.k8s.io +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki-promtail] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki +subjects: + - kind: ServiceAccount + name: loki +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki-promtail +subjects: + - kind: ServiceAccount + name: loki-promtail +--- +apiVersion: v1 +kind: Service +metadata: + name: loki-headless + namespace: mesh-observability + labels: + app: loki + release: loki + variant: headless +spec: + clusterIP: None + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: v1 +kind: Service +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + type: ClusterIP + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: apps/v1 +kind: DaemonSet +metadata: + name: loki-promtail + namespace: mesh-observability + labels: + app: promtail + release: loki + annotations: + {} +spec: + selector: + matchLabels: + app: promtail + release: loki + updateStrategy: + {} + template: + metadata: + labels: + app: promtail + release: loki + annotations: + checksum/config: bce7daf9d5acc773342c4f42e700668ef8bdc8f34fa1499c766263fa0c1944e0 + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki-promtail + containers: + - name: promtail + image: "grafana/promtail:2.4.1" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/promtail/promtail.yaml" + - "-client.url=http://loki.mesh-observability:3100/loki/api/v1/push" + volumeMounts: + - name: config + mountPath: /etc/promtail + - name: run + mountPath: /run/promtail + - mountPath: /var/lib/docker/containers + name: docker + readOnly: true + - mountPath: /var/log/pods + name: pods + readOnly: true + env: + - name: HOSTNAME + valueFrom: + fieldRef: + fieldPath: spec.nodeName + ports: + - containerPort: 3101 + name: http-metrics + securityContext: + readOnlyRootFilesystem: true + runAsGroup: 0 + runAsUser: 0 + readinessProbe: + failureThreshold: 5 + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 + resources: + {} + nodeSelector: + {} + affinity: + {} + tolerations: + - effect: NoSchedule + key: node-role.kubernetes.io/master + operator: Exists + volumes: + - name: config + configMap: + name: loki-promtail + - name: run + hostPath: + path: /run/promtail + - hostPath: + path: /var/lib/docker/containers + name: docker + - hostPath: + path: /var/log/pods + name: pods +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: loki + namespace: mesh-observability + labels: + app: loki + release: loki + annotations: + {} +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app: loki + release: loki + serviceName: loki-headless + updateStrategy: + type: RollingUpdate + template: + metadata: + labels: + app: loki + name: loki + release: loki + annotations: + checksum/config: d4c94f4c6a73353362c10d2f844340cec8999b291ca88481ac162fbb5942617d + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + initContainers: + [] + containers: + - name: loki + image: "grafana/loki:2.5.0" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/loki/loki.yaml" + - "-target=all,table-manager" + volumeMounts: + - name: config + mountPath: /etc/loki + - name: storage + mountPath: "/data" + ports: + - name: http-metrics + containerPort: 3100 + protocol: TCP + livenessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + {} + securityContext: + readOnlyRootFilesystem: true + nodeSelector: + {} + affinity: + {} + tolerations: + [] + terminationGracePeriodSeconds: 4800 + volumes: + - name: config + secret: + secretName: loki + - name: storage + emptyDir: {} +--- +apiVersion: v1 +kind: Namespace +metadata: + name: mesh-observability +--- +# Based on https://github.com/jaegertracing/jaeger-kubernetes/blob/master/all-in-one/jaeger-all-in-one-template.yml + +# +# Copyright 2017-2019 The Jaeger 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. +# + +apiVersion: v1 +kind: List +items: + - apiVersion: apps/v1 + kind: Deployment + metadata: + name: jaeger + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + spec: + replicas: 1 + selector: + matchLabels: + app: jaeger + strategy: + type: Recreate + template: + metadata: + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + annotations: + prometheus.io/scrape: "true" + prometheus.io/port: "16686" + spec: + containers: + - env: + - name: COLLECTOR_ZIPKIN_HOST_PORT + value: "9411" + image: jaegertracing/all-in-one:1.34.1 + name: jaeger + ports: + - containerPort: 5775 + protocol: UDP + - containerPort: 6831 + protocol: UDP + - containerPort: 6832 + protocol: UDP + - containerPort: 5778 + protocol: TCP + - containerPort: 16686 + protocol: TCP + - containerPort: 9411 + protocol: TCP + readinessProbe: + httpGet: + path: "/" + port: 14269 + initialDelaySeconds: 5 + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-query + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: query + spec: + selector: + matchLabels: + app: jaeger-query + ports: + - name: query-http + port: 80 + protocol: TCP + targetPort: 16686 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-collector + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: collector + spec: + selector: + matchLabels: + app: jaeger-collector + ports: + - name: jaeger-collector-tchannel + port: 14267 + protocol: TCP + targetPort: 14267 + - name: jaeger-collector-http + port: 14268 + protocol: TCP + targetPort: 14268 + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-agent + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: agent + spec: + selector: + matchLabels: + app: jaeger-agent + ports: + - name: agent-zipkin-thrift + port: 5775 + protocol: UDP + targetPort: 5775 + - name: agent-compact + port: 6831 + protocol: UDP + targetPort: 6831 + - name: agent-binary + port: 6832 + protocol: UDP + targetPort: 6832 + - name: agent-configs + port: 5778 + protocol: TCP + targetPort: 5778 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + - apiVersion: v1 + kind: Service + metadata: + name: zipkin + namespace: mesh-observability + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: zipkin + spec: + selector: + matchLabels: + app: zipkin + ports: + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one diff --git a/app/kumactl/cmd/install/testdata/install-observability.overrides.golden.yaml b/app/kumactl/cmd/install/testdata/install-observability.overrides.golden.yaml new file mode 100644 index 000000000000..12ff7693bcd3 --- /dev/null +++ b/app/kumactl/cmd/install/testdata/install-observability.overrides.golden.yaml @@ -0,0 +1,12299 @@ + +--- +apiVersion: v1 +kind: Namespace +metadata: + name: kuma + labels: + kuma.io/sidecar-injection: enabled + annotations: + kuma.io/mesh: mesh-1 +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: grafana + namespace: kuma + labels: + app: grafana + annotations: + seccomp.security.alpha.kubernetes.io/allowedProfileNames: 'docker/default' + seccomp.security.alpha.kubernetes.io/defaultProfileName: 'docker/default' + apparmor.security.beta.kubernetes.io/allowedProfileNames: 'runtime/default' + apparmor.security.beta.kubernetes.io/defaultProfileName: 'runtime/default' +spec: + privileged: false + allowPrivilegeEscalation: false + requiredDropCapabilities: + # Default set from Docker, without DAC_OVERRIDE or CHOWN + - FOWNER + - FSETID + - KILL + - SETGID + - SETUID + - SETPCAP + - NET_BIND_SERVICE + - NET_RAW + - SYS_CHROOT + - MKNOD + - AUDIT_WRITE + - SETFCAP + volumes: + - 'configMap' + - 'emptyDir' + - 'projected' + - 'secret' + - 'downwardAPI' + - 'persistentVolumeClaim' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'RunAsAny' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'RunAsAny' + fsGroup: + rule: 'RunAsAny' + readOnlyRootFilesystem: false +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: kuma +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: kuma +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: grafana + name: grafana + namespace: kuma +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: grafana + namespace: kuma + labels: + app: grafana +data: + grafana.ini: | + [analytics] + check_for_updates = true + [grafana_net] + url = https://grafana.net + [log] + mode = console + [paths] + data = /var/lib/grafana/data + logs = /var/log/grafana + plugins = /var/lib/grafana/plugins + provisioning = /etc/grafana/provisioning + [plugins] + # Required until we have grafana sign our plugin. + allow_loading_unsigned_plugins = "kumahq-kuma-datasource" +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-datasource + namespace: kuma + labels: + app: grafana +data: + datasource.yaml: | + # config file version + apiVersion: 1 + + # list of datasources that should be deleted from the database + deleteDatasources: + - name: Prometheus + orgId: 1 + + # list of datasources to insert/update depending + # whats available in the database + datasources: + # name of the datasource. Required + - name: Prometheus + uid: prometheus + # datasource type. Required + type: prometheus + # access mode. direct or proxy. Required + access: proxy + # org id. will default to orgId 1 if not specified + orgId: 1 + # url + url: http://prometheus-server.mesh-observability + # database password, if used + password: + # database user, if used + user: + # database name, if used + database: + # enable/disable basic auth + basicAuth: false + # basic auth username, if used + basicAuthUser: + # basic auth password, if used + basicAuthPassword: + # enable/disable with credentials headers + withCredentials: + # mark as default datasource. Max one per org + isDefault: true + # fields that will be converted to json and stored in json_data + jsonData: + graphiteVersion: "1.1" + tlsAuth: false + tlsAuthWithCACert: false + # json object of data that will be encrypted. + secureJsonData: + tlsCACert: "..." + tlsClientCert: "..." + tlsClientKey: "..." + version: 1 + # allow users to edit datasources from the UI. + editable: true + - name: Kuma + uid: kuma + editable: true + type: kumahq-kuma-datasource + url: http://kuma-control-plane.kuma-system:5681 + jsonData: + prometheusDataSourceId: "1" + - name: Jaeger + type: jaeger + access: proxy + editable: true + uid: jaeger + url: http://jaeger-query.mesh-observability + jsonData: + tracesToLogs: + datasourceUid: loki + tags: ["node_id"] + - name: Loki + type: loki + access: proxy + editable: true + uid: loki + url: http://loki.mesh-observability:3100 + jsonData: + derivedFields: + - datasourceUid: jaeger + matcherRegex: '"([0-9a-f]{16})"' + name: "traceId" + url: '$${__value.raw}' +--- +apiVersion: v1 +kind: ConfigMap +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: kuma +data: + alerting_rules.yml: | + {} + alerts: | + {} + prometheus.yml: | + global: + evaluation_interval: 1m + scrape_interval: 10s + scrape_timeout: 10s + rule_files: + - /etc/config/recording_rules.yml + - /etc/config/alerting_rules.yml + - /etc/config/rules + - /etc/config/alerts + scrape_configs: + - job_name: prometheus + static_configs: + - targets: + - localhost:9090 + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-apiservers + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: default;kubernetes;https + source_labels: + - __meta_kubernetes_namespace + - __meta_kubernetes_service_name + - __meta_kubernetes_endpoint_port_name + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-nodes + kubernetes_sd_configs: + - role: node + relabel_configs: + - action: labelmap + regex: __meta_kubernetes_node_label_(.+) + - replacement: kubernetes.default.svc:443 + target_label: __address__ + - regex: (.+) + replacement: /api/v1/nodes/$1/proxy/metrics + source_labels: + - __meta_kubernetes_node_name + target_label: __metrics_path__ + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + job_name: kubernetes-nodes-cadvisor + kubernetes_sd_configs: + - role: node + relabel_configs: + - action: labelmap + regex: __meta_kubernetes_node_label_(.+) + - replacement: kubernetes.default.svc:443 + target_label: __address__ + - regex: (.+) + replacement: /api/v1/nodes/$1/proxy/metrics/cadvisor + source_labels: + - __meta_kubernetes_node_name + target_label: __metrics_path__ + scheme: https + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + insecure_skip_verify: true + - job_name: kubernetes-service-endpoints + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scrape + - action: replace + regex: (https?) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scheme + target_label: __scheme__ + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_service_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - action: replace + source_labels: + - __meta_kubernetes_pod_node_name + target_label: kubernetes_node + - job_name: kubernetes-service-endpoints-slow + kubernetes_sd_configs: + - role: endpoints + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scrape_slow + - action: replace + regex: (https?) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_scheme + target_label: __scheme__ + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_service_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - action: replace + source_labels: + - __meta_kubernetes_pod_node_name + target_label: kubernetes_node + scrape_interval: 5m + scrape_timeout: 30s + - honor_labels: true + job_name: prometheus-pushgateway + kubernetes_sd_configs: + - role: service + relabel_configs: + - action: keep + regex: pushgateway + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_probe + - job_name: kubernetes-services + kubernetes_sd_configs: + - role: service + metrics_path: /probe + params: + module: + - http_2xx + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_service_annotation_prometheus_io_probe + - source_labels: + - __address__ + target_label: __param_target + - replacement: blackbox + target_label: __address__ + - source_labels: + - __param_target + target_label: instance + - action: labelmap + regex: __meta_kubernetes_service_label_(.+) + - source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - source_labels: + - __meta_kubernetes_service_name + target_label: kubernetes_name + - job_name: kubernetes-pods + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_scrape + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_pod_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: kubernetes_pod_name + - job_name: kubernetes-pods-slow + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: keep + regex: true + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_scrape_slow + - action: replace + regex: (.+) + source_labels: + - __meta_kubernetes_pod_annotation_prometheus_io_path + target_label: __metrics_path__ + - action: replace + regex: ([^:]+)(?::\d+)?;(\d+) + replacement: $1:$2 + source_labels: + - __address__ + - __meta_kubernetes_pod_annotation_prometheus_io_port + target_label: __address__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: kubernetes_namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: kubernetes_pod_name + scrape_interval: 5m + scrape_timeout: 30s + - job_name: 'kuma-dataplanes' + scrape_interval: "5s" + relabel_configs: + - source_labels: + - k8s_kuma_io_name + regex: "(.*)" + target_label: pod + - source_labels: + - k8s_kuma_io_namespace + regex: "(.*)" + target_label: namespace + - source_labels: + - __meta_kuma_mesh + regex: "(.*)" + target_label: mesh + - source_labels: + - __meta_kuma_dataplane + regex: "(.*)" + target_label: dataplane + - source_labels: + - __meta_kuma_service + regex: "(.*)" + target_label: service + - action: labelmap + regex: __meta_kuma_label_(.+) + kuma_sd_configs: + - server: http://kuma.local:5681 + alerting: + alertmanagers: + - kubernetes_sd_configs: + - role: pod + tls_config: + ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt + bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token + relabel_configs: + - source_labels: [__meta_kubernetes_namespace] + regex: default + action: keep + - source_labels: [__meta_kubernetes_pod_label_app] + regex: prometheus + action: keep + - source_labels: [__meta_kubernetes_pod_label_component] + regex: alertmanager + action: keep + - source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_probe] + regex: .* + action: keep + - source_labels: [__meta_kubernetes_pod_container_port_number] + regex: + action: drop + recording_rules.yml: | + {} + rules: | + {} +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards + namespace: kuma + labels: + app: grafana +data: + dashboards.yaml: | + apiVersion: 1 + + providers: + - name: 'Prometheus' + orgId: 1 + folder: '' + type: file + disableDeletion: false + editable: true + options: + path: /etc/grafana/provisioning/dashboards +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-0 + namespace: kuma + labels: + app: grafana +data: + kuma-dataplane.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "description": "Statistics of a single Dataplane in Kuma Service Mesh", + "editable": true, + "gnetId": 11775, + "graphTooltip": 0, + "id": 3, + "iteration": 1619601583109, + "links": [], + "panels": [ + { + "collapsed": false, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 22, + "panels": [], + "title": "Dataplane", + "type": "row" + }, + { + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": {}, + "displayName": "", + "mappings": [ + { + "from": "", + "id": 1, + "operator": "", + "text": "LIVE", + "to": "", + "type": 1, + "value": "1" + }, + { + "from": "", + "id": 2, + "operator": "", + "text": "OFF", + "to": "", + "type": 1, + "value": "0" + } + ], + "max": 1, + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 1 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 5, + "x": 0, + "y": 1 + }, + "id": 16, + "interval": "", + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": false, + "text": {} + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(envoy_server_live{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"} OR on() vector(0))", + "interval": "", + "intervalFactor": 1, + "legendFormat": "", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Status", + "type": "gauge" + }, + { + "cacheTimeout": null, + "colorBackground": false, + "colorPrefix": false, + "colorValue": false, + "colors": [ + "#299c46", + "rgba(237, 129, 40, 0.89)", + "#d44a3a" + ], + "datasource": "Prometheus", + "decimals": 2, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "format": "s", + "gauge": { + "maxValue": 100, + "minValue": 0, + "show": false, + "thresholdLabels": false, + "thresholdMarkers": true + }, + "gridPos": { + "h": 7, + "w": 4, + "x": 5, + "y": 1 + }, + "id": 18, + "interval": null, + "links": [], + "mappingType": 1, + "mappingTypes": [ + { + "name": "value to text", + "value": 1 + }, + { + "name": "range to text", + "value": 2 + } + ], + "maxDataPoints": 100, + "nullPointMode": "connected", + "nullText": null, + "postfix": "", + "postfixFontSize": "50%", + "prefix": "", + "prefixFontSize": "50%", + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "sparkline": { + "fillColor": "rgba(31, 118, 189, 0.18)", + "full": false, + "lineColor": "rgb(31, 120, 193)", + "show": false, + "ymax": null, + "ymin": null + }, + "tableColumn": "", + "targets": [ + { + "expr": "envoy_server_uptime{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "refId": "A" + } + ], + "thresholds": "", + "timeFrom": null, + "timeShift": null, + "title": "Uptime", + "type": "singlestat", + "valueFontSize": "80%", + "valueMaps": [ + { + "op": "=", + "text": "N/A", + "value": "null" + } + ], + "valueName": "max" + }, + { + "cacheTimeout": null, + "colorBackground": false, + "colorValue": false, + "colors": [ + "#299c46", + "rgba(237, 129, 40, 0.89)", + "#d44a3a" + ], + "datasource": "Prometheus", + "decimals": 2, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "format": "bytes", + "gauge": { + "maxValue": 100, + "minValue": 0, + "show": false, + "thresholdLabels": false, + "thresholdMarkers": true + }, + "gridPos": { + "h": 7, + "w": 4, + "x": 9, + "y": 1 + }, + "id": 25, + "interval": null, + "links": [], + "mappingType": 1, + "mappingTypes": [ + { + "name": "value to text", + "value": 1 + }, + { + "name": "range to text", + "value": 2 + } + ], + "maxDataPoints": 100, + "nullPointMode": "connected", + "nullText": null, + "postfix": "", + "postfixFontSize": "50%", + "prefix": "", + "prefixFontSize": "50%", + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "sparkline": { + "fillColor": "rgba(31, 118, 189, 0.18)", + "full": false, + "lineColor": "rgb(31, 120, 193)", + "show": false, + "ymax": null, + "ymin": null + }, + "tableColumn": "", + "targets": [ + { + "expr": "envoy_server_memory_heap_size{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "refId": "A" + } + ], + "thresholds": "", + "timeFrom": null, + "timeShift": null, + "title": "Heap size", + "type": "singlestat", + "valueFontSize": "80%", + "valueMaps": [ + { + "op": "=", + "text": "N/A", + "value": "null" + } + ], + "valueName": "avg" + }, + { + "cacheTimeout": null, + "colorBackground": false, + "colorValue": false, + "colors": [ + "#299c46", + "rgba(237, 129, 40, 0.89)", + "#d44a3a" + ], + "datasource": "Prometheus", + "decimals": 2, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "format": "bytes", + "gauge": { + "maxValue": 100, + "minValue": 0, + "show": false, + "thresholdLabels": false, + "thresholdMarkers": true + }, + "gridPos": { + "h": 7, + "w": 4, + "x": 13, + "y": 1 + }, + "id": 26, + "interval": null, + "links": [], + "mappingType": 1, + "mappingTypes": [ + { + "name": "value to text", + "value": 1 + }, + { + "name": "range to text", + "value": 2 + } + ], + "maxDataPoints": 100, + "nullPointMode": "connected", + "nullText": null, + "postfix": "", + "postfixFontSize": "50%", + "prefix": "", + "prefixFontSize": "50%", + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "sparkline": { + "fillColor": "rgba(31, 118, 189, 0.18)", + "full": false, + "lineColor": "rgb(31, 120, 193)", + "show": false, + "ymax": null, + "ymin": null + }, + "tableColumn": "", + "targets": [ + { + "expr": "envoy_server_memory_allocated{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "refId": "A" + } + ], + "thresholds": "", + "timeFrom": null, + "timeShift": null, + "title": "Memory allocated", + "type": "singlestat", + "valueFontSize": "80%", + "valueMaps": [ + { + "op": "=", + "text": "N/A", + "value": "null" + } + ], + "valueName": "avg" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Note that if Control Plane does not sent FIN segment, Dataplanes can still think that connection is up waiting for new update even that Control Plane is down.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 7, + "x": 17, + "y": 1 + }, + "hiddenSeries": false, + "id": 20, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_control_plane_connected_state{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "legendFormat": "Connected", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection to the Control Plane", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 8 + }, + "id": 10, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 2 + }, + "hiddenSeries": false, + "id": 6, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_upstream_cx_active{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Connections to this Dataplane", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 2 + }, + "hiddenSeries": false, + "id": 4, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_connect_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection time (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 2 + }, + "hiddenSeries": false, + "id": 32, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_length_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection length (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 10 + }, + "hiddenSeries": false, + "id": 31, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_tx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes received from requests", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 10 + }, + "hiddenSeries": false, + "id": 13, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_rx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name=~\"localhost.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes sent in responses", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": "", + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if TrafficPermission policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 10 + }, + "hiddenSeries": false, + "id": 28, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_rbac_allowed{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Allowed - {{listener}}", + "refId": "A" + }, + { + "expr": "irate(envoy_rbac_shadow_allowed{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Shadow allowed - {{listener}}", + "refId": "D" + }, + { + "expr": "irate(envoy_rbac_denied{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Denied - {{listener}}", + "refId": "B" + }, + { + "expr": "irate(envoy_rbac_shadow_denied{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "Shadow denied - {{listener}}", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic permissions", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 18 + }, + "hiddenSeries": false, + "id": 30, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": true, + "values": true + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "hide": true, + "legendFormat": "connection destroyed by the client - {{envoy_cluster_name}}", + "refId": "A" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_connect_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "connection timeout - {{envoy_cluster_name}}", + "refId": "B" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "hide": true, + "legendFormat": "connection destroyed by local Envoy - {{envoy_cluster_name}}", + "refId": "C" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_failure_eject{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "pending failure ejection - {{envoy_cluster_name}}", + "refId": "D" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "pending overflow - {{envoy_cluster_name}}", + "refId": "E" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "request timeout - {{envoy_cluster_name}}", + "refId": "F" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_rx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "response reset by the client - {{envoy_cluster_name}}", + "refId": "G" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_tx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost.*\"}[1m])", + "legendFormat": "request reset by local Envoy - {{envoy_cluster_name}}", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Incoming traffic", + "type": "row" + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 9 + }, + "id": 12, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 10 + }, + "hiddenSeries": false, + "id": 8, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_upstream_cx_active{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}", + "interval": "", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Connections to other Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:203", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:204", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 10 + }, + "hiddenSeries": false, + "id": 33, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_connect_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection time (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 10 + }, + "hiddenSeries": false, + "id": 34, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_length_ms_bucket{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection length (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 18 + }, + "hiddenSeries": false, + "id": 14, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_rx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes received from other Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "bytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 18 + }, + "hiddenSeries": false, + "id": 3, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_tx_bytes_total{dataplane=\"$dataplane\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes sent to other Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "bytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "columns": [], + "datasource": "Prometheus", + "description": "Data is only available if TrafficPermission policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fontSize": "100%", + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 18 + }, + "id": 24, + "pageSize": null, + "showHeader": true, + "sort": { + "col": 0, + "desc": true + }, + "styles": [ + { + "alias": "Time", + "align": "auto", + "dateFormat": "YYYY-MM-DD HH:mm:ss", + "pattern": "Time", + "type": "date" + }, + { + "alias": "", + "align": "auto", + "colorMode": null, + "colors": [ + "rgba(245, 54, 54, 0.9)", + "rgba(237, 129, 40, 0.89)", + "rgba(50, 172, 45, 0.97)" + ], + "decimals": 2, + "pattern": "/.*/", + "thresholds": [ + "" + ], + "type": "number", + "unit": "short" + } + ], + "targets": [ + { + "expr": "envoy_cluster_ssl_handshake{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"} > 0", + "format": "time_series", + "interval": "", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Secured destinations by mTLS", + "transform": "timeseries_aggregations", + "type": "table-old" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 26 + }, + "hiddenSeries": false, + "id": 29, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "hide": true, + "legendFormat": "destroyed by remote Envoy - {{envoy_cluster_name}}", + "refId": "A" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_connect_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "connection timeout - {{envoy_cluster_name}}", + "refId": "B" + }, + { + "expr": "irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "hide": true, + "legendFormat": "destroyed by local Envoy - {{envoy_cluster_name}}", + "refId": "C" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_failure_eject{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "pending failure ejection - {{envoy_cluster_name}}", + "refId": "D" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_pending_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "pending overflow - {{envoy_cluster_name}}", + "refId": "E" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_timeout{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "request timeout - {{envoy_cluster_name}}", + "refId": "F" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_rx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "request reset by other Envoy - {{envoy_cluster_name}}", + "refId": "G" + }, + { + "expr": "irate(envoy_cluster_upstream_rq_tx_reset{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}[1m])", + "legendFormat": "response reset by local Envoy - {{envoy_cluster_name}}", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Outgoing traffic", + "type": "row" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 10 + }, + "id": 49, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 11 + }, + "hiddenSeries": false, + "id": 51, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p99", + "refId": "B" + }, + { + "expr": "sum(histogram_quantile(0.95, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p95", + "refId": "A" + }, + { + "expr": "sum(histogram_quantile(0.50, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p50", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 11 + }, + "hiddenSeries": false, + "id": 53, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\",dataplane=\"$dataplane\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Incoming", + "refId": "B" + }, + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",dataplane=\"$dataplane\",envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\", envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Outgoing", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 11 + }, + "hiddenSeries": false, + "id": 55, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",dataplane=\"$dataplane\", envoy_cluster_name=~\"localhost_.*\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Incoming {{envoy_response_code_class}}xx", + "refId": "A" + }, + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{kuma_io_zone=~\"$zone\",mesh=\"$mesh\",dataplane=\"$dataplane\", envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\", envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Outgoing {{envoy_response_code_class}}xx", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Status codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 20 + }, + "id": 36, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 4 + }, + "hiddenSeries": false, + "id": 38, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_health_check_healthy{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks - healthy service instances", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:353", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:354", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 4 + }, + "hiddenSeries": false, + "id": 39, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "envoy_cluster_membership_total{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"} - envoy_cluster_health_check_healthy{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}", + "legendFormat": "{{envoy_cluster_name}}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks - failing service instances", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:384", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:385", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Health Checks", + "type": "row" + }, + { + "collapsed": true, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 21 + }, + "id": 45, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "description": "Total times that the cluster’s connection circuit breaker overflowed", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 12 + }, + "hiddenSeries": false, + "id": 43, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "interval": "", + "legendFormat": "Connection overflow", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Pending request overflow", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_retry_overflow{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Retry overflow", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Thresholds Overflow", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:72", + "format": "ops", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:73", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied. Note that passive health checks are executed on healthy instances marked by active health checks.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 12 + }, + "hiddenSeries": false, + "id": 47, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "1 - sum(envoy_cluster_outlier_detection_ejections_active{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}) / sum(envoy_cluster_membership_total{dataplane=\"$dataplane\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "interval": "", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Outlier detection", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:312", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "$$hashKey": "object:313", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Circuit Breakers", + "type": "row" + } + ], + "schemaVersion": 27, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "Prometheus-mesh-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "kuma-demo-backend-v0-56db47c579-pjztb.kuma-demo", + "value": "kuma-demo-backend-v0-56db47c579-pjztb.kuma-demo" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, dataplane)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Dataplane", + "multi": false, + "name": "dataplane", + "options": [], + "query": { + "query": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, dataplane)", + "refId": "Prometheus-dataplane-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma Dataplane", + "uid": "-SZYLFyWz", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-1 + namespace: kuma + labels: + app: grafana +data: + kuma-mesh.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "description": "Statistics of the single Mesh in Kuma Service Mesh", + "editable": true, + "gnetId": 11774, + "graphTooltip": 0, + "id": 4, + "iteration": 1617606288684, + "links": [], + "panels": [ + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 30, + "panels": [], + "title": "Service Map", + "type": "row" + }, + { + "datasource": "Kuma", + "gridPos": { + "h": 14, + "w": 24, + "x": 0, + "y": 1 + }, + "id": 32, + "interval": "1m", + "targets": [ + { + "hide": false, + "mesh": "$mesh", + "queryType": "mesh-graph", + "refId": "A" + } + ], + "title": "Service Map", + "type": "nodeGraph" + }, + { + "collapsed": false, + "datasource": null, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 15 + }, + "id": 23, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 16 + }, + "hiddenSeries": false, + "id": 25, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",envoy_cluster_name=~\"localhost_.*\"}[1m]))) by (kuma_io_service)", + "hide": false, + "interval": "", + "legendFormat": "{{ kuma_io_service }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 16 + }, + "hiddenSeries": false, + "id": 26, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",envoy_cluster_name=~\"localhost_.*\"}[1m])) by (kuma_io_service)", + "hide": false, + "interval": "", + "legendFormat": "{{ kuma_io_service }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:366", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "$$hashKey": "object:367", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 16 + }, + "hiddenSeries": false, + "id": 28, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",envoy_cluster_name=~\"localhost_.*\", envoy_response_code_class=~\"4|5\"}[1m])) by (kuma_io_service,envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "{{ kuma_io_service}} {{ envoy_response_code_class }}xx", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Error Status Codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 25 + }, + "id": 16, + "panels": [], + "title": "Health Checks", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 24, + "x": 0, + "y": 26 + }, + "hiddenSeries": false, + "id": 9, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "((sum(rate(envoy_cluster_health_check_success{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m])) / sum(rate(envoy_cluster_health_check_attempt{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))))", + "legendFormat": "Success rate", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": null, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 33 + }, + "id": 19, + "panels": [], + "title": "Circuit Breakers", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "description": "Total times that the cluster’s connection circuit breaker overflowed", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 34 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "interval": "", + "legendFormat": "Connection overflow", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Pending request overflow", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_retry_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Retry overflow", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Thresholds Overflow", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:72", + "format": "ops", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:73", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied. Note that passive health checks are executed on healthy instances marked by active health checks.", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 34 + }, + "hiddenSeries": false, + "id": 17, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "1 - sum(envoy_cluster_outlier_detection_ejections_active{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}) / sum(envoy_cluster_membership_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "interval": "", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Outlier detection", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 42 + }, + "id": 12, + "panels": [], + "title": "Data Plane Proxies", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 12, + "x": 0, + "y": 43 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:224", + "alias": "Off", + "color": "#F2495C" + }, + { + "$$hashKey": "object:225", + "alias": "Live", + "color": "#73BF69" + } + ], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "count(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}) - sum(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "hide": false, + "legendFormat": "Off", + "refId": "B" + }, + { + "expr": "sum(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "hide": false, + "legendFormat": "Live", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Dataplanes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:238", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:239", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Note that if Control Plane does not sent FIN segment, Dataplanes can still think that connection is up waiting for new update even that Control Plane is down.", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 12, + "x": 12, + "y": 43 + }, + "hiddenSeries": false, + "id": 3, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:293", + "alias": "Disconnected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:294", + "alias": "Connected", + "color": "#73BF69" + } + ], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "count(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}) - sum(envoy_control_plane_connected_state{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "legendFormat": "Disconnected", + "refId": "B" + }, + { + "expr": "sum(envoy_control_plane_connected_state{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"})", + "legendFormat": "Connected", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Dataplanes connected to the Control Plane", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:307", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:308", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 50 + }, + "hiddenSeries": false, + "id": 5, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_tx_bytes_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Sent", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_rx_bytes_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Received", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Bytes flowing through Envoy", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 50 + }, + "hiddenSeries": false, + "id": 7, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": false, + "hideZero": false, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.1.2", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by the client", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_connect_timeout{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Connection timeout", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by local Envoy", + "refId": "C" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_failure_eject{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Pending failure ejection", + "refId": "D" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Pending overflow", + "refId": "E" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_timeout{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Request timeout", + "refId": "F" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_rx_reset{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Response reset", + "refId": "G" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_tx_reset{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}[1m]))", + "legendFormat": "Request reset", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "refresh": "5s", + "schemaVersion": 30, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "Prometheus-mesh-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma Mesh", + "uid": "GW0DqjsWz", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-2 + namespace: kuma + labels: + app: grafana +data: + kuma-service-to-service.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "description": "Statistics of the traffic between services in Kuma Service Mesh", + "editable": true, + "gnetId": 11776, + "graphTooltip": 0, + "id": 4, + "iteration": 1617905663030, + "links": [], + "panels": [ + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 10, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 1 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_tx_bytes_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Bytes sent", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_rx_bytes_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Bytes received", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic from source service perspective", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "decbytes", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 1 + }, + "hiddenSeries": false, + "id": 14, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": false, + "hideZero": false, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_remote_with_active_rq{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by the client", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_connect_timeout{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Connection timeout", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_cx_destroy_local_with_active_rq{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": true, + "legendFormat": "Connection destroyed by local Envoy", + "refId": "C" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_failure_eject{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Pending failure ejection", + "refId": "D" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Pending overflow", + "refId": "E" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_timeout{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Request timeout", + "refId": "F" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_rx_reset{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Response reset", + "refId": "G" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_tx_reset{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "legendFormat": "Request reset", + "refId": "H" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection/Requests errors from source service perspective", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 9 + }, + "hiddenSeries": false, + "id": 4, + "interval": "", + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(envoy_cluster_upstream_cx_active{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "legendFormat": "Connections", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Connections between services", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 9 + }, + "hiddenSeries": false, + "id": 6, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_connect_ms_bucket{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])))", + "legendFormat": "Time", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection time (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 9 + }, + "hiddenSeries": false, + "id": 8, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 4, + "points": true, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, irate(envoy_cluster_upstream_cx_length_ms_bucket{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m])))", + "legendFormat": "Time", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Connection length (P99)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "ms", + "label": "", + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Traffic", + "type": "row" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 1 + }, + "id": 25, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "color": {}, + "custom": {}, + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 2 + }, + "hiddenSeries": false, + "id": 27, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null as zero", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_service=\"$source_service\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=\"$destination_cluster\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p99", + "refId": "A" + }, + { + "expr": "max(histogram_quantile(0.95, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_service=\"$source_service\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=\"$destination_cluster\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p95", + "refId": "C" + }, + { + "expr": "max(histogram_quantile(0.50, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_service=\"$source_service\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=\"$destination_cluster\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p50", + "refId": "D" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:631", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:632", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 2 + }, + "hiddenSeries": false, + "id": 29, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_service=\"$source_service\", envoy_cluster_name=\"$destination_cluster\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Requests", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:429", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:430", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 2 + }, + "hiddenSeries": false, + "id": 31, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_service=\"$source_service\", envoy_cluster_name=\"$destination_cluster\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "{{envoy_response_code_class}}xx", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Status codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": true, + "datasource": "Prometheus", + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 11 + }, + "id": 18, + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if HealthCheck policy is applied.", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 24, + "x": 0, + "y": 12 + }, + "hiddenSeries": false, + "id": 12, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(envoy_cluster_health_check_healthy{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}) / sum(envoy_cluster_membership_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Active Health Checks", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:347", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "$$hashKey": "object:348", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "title": "Health Checks", + "type": "row" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 12 + }, + "id": 23, + "panels": [], + "title": "Circuit Breakers", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "description": "Total times that the cluster’s connection circuit breaker overflowed", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 13 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(irate(envoy_cluster_upstream_cx_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "interval": "", + "legendFormat": "Connection overflow", + "refId": "A" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_pending_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Pending request overflow", + "refId": "B" + }, + { + "expr": "sum(irate(envoy_cluster_upstream_rq_retry_overflow{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Retry overflow", + "refId": "C" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Thresholds Overflow", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:72", + "format": "ops", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:73", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Prometheus", + "description": "Data is only available if CircuitBreaker policy is applied", + "fieldConfig": { + "defaults": { + "custom": {}, + "links": [] + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 13 + }, + "hiddenSeries": false, + "id": 19, + "legend": { + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "1 - sum(envoy_cluster_outlier_detection_ejections_active{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"}) / sum(envoy_cluster_membership_total{kuma_io_service=\"$source_service\",envoy_cluster_name=\"$destination_cluster\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\"})", + "interval": "", + "legendFormat": "Healthy destinations", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Outlier detection", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:402", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": "1", + "min": "0", + "show": true + }, + { + "$$hashKey": "object:403", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "refresh": "5s", + "schemaVersion": 27, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "Prometheus-mesh-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "backend_kuma-demo_svc_3001", + "value": "backend_kuma-demo_svc_3001" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_service)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Source service", + "multi": false, + "name": "source_service", + "options": [], + "query": { + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_service)", + "refId": "Prometheus-source_service-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "frontend_kuma-demo_svc_8080", + "value": "frontend_kuma-demo_svc_8080" + }, + "datasource": "Prometheus", + "definition": "label_values(envoy_cluster_upstream_cx_active{kuma_io_service=\"$source_service\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}, envoy_cluster_name)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Destination service", + "multi": false, + "name": "destination_cluster", + "options": [], + "query": { + "query": "label_values(envoy_cluster_upstream_cx_active{kuma_io_service=\"$source_service\",envoy_cluster_name!~\"(localhost.*)|ads_cluster|kuma_envoy_admin|access_log_sink\"}, envoy_cluster_name)", + "refId": "Prometheus-destination_cluster-Variable-Query" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-1h", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma Service to Service", + "uid": "QdCgOqyWz", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-3 + namespace: kuma + labels: + app: grafana +data: + kuma-cp.json: | + { + "__inputs": [ + { + "name": "DS_PROMETHEUS", + "label": "Prometheus", + "description": "", + "type": "datasource", + "pluginId": "prometheus", + "pluginName": "Prometheus" + } + ], + "__elements": [], + "__requires": [ + { + "type": "grafana", + "id": "grafana", + "name": "Grafana", + "version": "8.3.3" + }, + { + "type": "panel", + "id": "graph", + "name": "Graph (old)", + "version": "" + }, + { + "type": "datasource", + "id": "prometheus", + "name": "Prometheus", + "version": "1.0.0" + }, + { + "type": "panel", + "id": "stat", + "name": "Stat", + "version": "" + }, + { + "type": "panel", + "id": "table", + "name": "Table", + "version": "" + } + ], + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": null, + "iteration": 1645785455248, + "links": [], + "liveNow": false, + "panels": [ + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 44, + "panels": [], + "title": "Overview", + "type": "row" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [ + { + "options": { + "from": 1, + "result": { + "color": "green", + "index": 0, + "text": "LIVE" + }, + "to": 9999 + }, + "type": "range" + }, + { + "options": { + "from": 0, + "result": { + "color": "red", + "index": 1, + "text": "UNAVAILABLE" + }, + "to": 0.999 + }, + "type": "range" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 1 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 6, + "x": 0, + "y": 1 + }, + "id": 39, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "auto" + }, + "pluginVersion": "8.3.3", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(cp_info{instance=~\"$instance\"} OR on() vector(0))", + "instant": false, + "interval": "", + "intervalFactor": 1, + "legendFormat": "", + "refId": "A" + } + ], + "title": "Condition", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "displayMode": "auto" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 6, + "y": 1 + }, + "id": 41, + "maxDataPoints": 1, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true + }, + "pluginVersion": "8.3.3", + "targets": [ + { + "expr": "cp_info{instance=~\"$instance\"}", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Control Plane information", + "transformations": [ + { + "id": "labelsToFields", + "options": {} + }, + { + "id": "merge", + "options": {} + }, + { + "id": "organize", + "options": { + "excludeByName": { + "Time": true, + "Value": true, + "build_date": true, + "cluster_id": true, + "git_commit": true, + "git_tag": true, + "job": true, + "kubernetes_name": true, + "kubernetes_namespace": true, + "kubernetes_node": true, + "product": true + }, + "indexByName": {}, + "renameByName": { + "instance": "Instance", + "instance_id": "Instance ID", + "mode": "Mode", + "version": "Version" + } + } + }, + { + "id": "merge", + "options": {} + } + ], + "type": "table" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Only one instance should be a leader at a given point of time in every zone", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 18, + "y": 1 + }, + "hiddenSeries": false, + "id": 68, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (zone, instance) (leader)", + "interval": "", + "legendFormat": "{{ zone }} - {{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Leader", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:3281", + "format": "short", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:3282", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 9 + }, + "id": 16, + "panels": [], + "title": "Aggregated Discovery Service (XDS): CP-DP communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 4, + "x": 0, + "y": 10 + }, + "hiddenSeries": false, + "id": 20, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "xds_streams_active{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "XDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:258", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:259", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of ADS messages exchanged between Control Plane and Dataplane over XDS", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 4, + "y": 10 + }, + "hiddenSeries": false, + "id": 18, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:630", + "alias": "Configuration sent", + "color": "#5794F2" + }, + { + "$$hashKey": "object:631", + "alias": "Configuration accepted", + "color": "#73BF69" + }, + { + "$$hashKey": "object:632", + "alias": "Configuration rejected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:633", + "alias": "RPC Errors", + "color": "#C4162A" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(xds_responses_sent{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Configuration sent", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(xds_requests_received{confirmation=\"ACK\",instance=~\"$instance\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Configuration accepted", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(xds_requests_received{confirmation=\"NACK\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Configuration rejected", + "refId": "C" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(grpc_server_handled_total{grpc_service=\"envoy.service.discovery.v3.AggregatedDiscoveryService\",grpc_code!=\"OK\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "RPC Errors", + "refId": "D" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(grpc_server_started_total{grpc_service=\"envoy.service.discovery.v3.AggregatedDiscoveryService\",instance=~\"$instance\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Rate", + "refId": "E" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "XDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:458", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:459", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of Envoy XDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected dataplanes * KUMA_XDS_SERVER_DATAPLANE_CONFIGURATION_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 9, + "y": 10 + }, + "hiddenSeries": false, + "id": 28, + "legend": { + "avg": false, + "current": false, + "hideZero": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:1365", + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(xds_generation_count{instance=~\"$instance\"}[1m])) - sum(rate(xds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "expr": "sum(rate(xds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "XDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:456", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:457", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "How much it took to generate Envoy configuration for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 14, + "y": 10 + }, + "hiddenSeries": false, + "id": 24, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "xds_generation{quantile=\"0.99\",instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of XDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to deliver Envoy configuration and receive ACK/NACK for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 19, + "y": 10 + }, + "hiddenSeries": false, + "id": 82, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "xds_delivery{quantile=\"0.99\",instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of XDS config delivery (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Cache protects ClusterLoadAssignments resources by sharing them between many goroutines which reconcile Dataplanes.\n\nhit - request was retrieved from the cache.\n\nhit-wait - request was retrieved from the cache after waiting for a concurrent request to fetch it from the database.\n\nmiss - request was fetched from the database\n\nRefer to https://kuma.io/docs/latest/documentation/fine-tuning/#snapshot-generation", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 13, + "x": 0, + "y": 18 + }, + "hiddenSeries": false, + "id": 70, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": true, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(cla_cache{result=\"hit\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit", + "refId": "A" + }, + { + "expr": "sum(rate(cla_cache{result=\"hit-wait\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit Wait", + "refId": "C" + }, + { + "expr": "sum(rate(cla_cache{result=\"miss\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Miss", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Endpoints cache performance", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:645", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:646", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Mesh Cache protects hashes calculated periodically for each Mesh in order to avoid the excessive generation of xDS resources.\n\nhit - request was retrieved from the cache.\n\nhit-wait - request was retrieved from the cache after waiting for a concurrent request to fetch it from the database.\n\nmiss - request was fetched from the database\n\nRefer to https://kuma.io/docs/latest/documentation/fine-tuning/#snapshot-generation", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 11, + "x": 13, + "y": 18 + }, + "hiddenSeries": false, + "id": 71, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": true, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(mesh_cache{result=\"hit\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit", + "refId": "A" + }, + { + "expr": "sum(rate(mesh_cache{result=\"hit-wait\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit Wait", + "refId": "C" + }, + { + "expr": "sum(rate(mesh_cache{result=\"miss\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Miss", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Mesh resources hash cache performance", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:645", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:646", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 26 + }, + "id": 73, + "panels": [], + "title": "Health Discovery Service (HDS): CP-DP communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 0, + "y": 27 + }, + "hiddenSeries": false, + "id": 75, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(hds_responses_sent{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "endpoint health responses", + "refId": "A" + }, + { + "expr": "sum(rate(hds_requests_received{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "health check requests", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "HDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:310", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:311", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 6, + "y": 27 + }, + "hiddenSeries": false, + "id": 77, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "hds_streams_active{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "HDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:797", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:798", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of Envoy HDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected dataplanes * KUMA_DP_SERVER_HDS_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 12, + "y": 27 + }, + "hiddenSeries": false, + "id": 79, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:1727", + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(hds_generation_count{instance=~\"$instance\"}[1m])) - sum(rate(hds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(hds_generation_errors{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "HDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1493", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:1494", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to generate Envoy configuration for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 18, + "y": 27 + }, + "hiddenSeries": false, + "id": 81, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "hds_generation{quantile=\"0.99\",instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of HDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1825", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1826", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 35 + }, + "id": 5, + "panels": [], + "title": "API Server - Management of the Control Plane", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 16, + "x": 0, + "y": 36 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, sum by (handler, le) (rate(api_server_http_request_duration_seconds_bucket{instance=~\"$instance\"}[1m])))", + "interval": "", + "legendFormat": "{{handler}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of API Server Requests (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:853", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:854", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 36 + }, + "hiddenSeries": false, + "id": 9, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:695", + "alias": "/2.*/", + "color": "#73BF69" + }, + { + "$$hashKey": "object:696", + "alias": "/4.*/", + "color": "#FADE2A" + }, + { + "$$hashKey": "object:697", + "alias": "/5.*/", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (code) (rate(api_server_http_request_duration_seconds_count{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "{{code}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Response Codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:796", + "format": "cps", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:797", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 44 + }, + "id": 54, + "panels": [], + "title": "Dataplane Server: CP-DP communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "XDS and SDS requests are not taken into account because they are long-running requests", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 16, + "x": 0, + "y": 45 + }, + "hiddenSeries": false, + "id": 55, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, sum by (handler, le) (rate(dp_server_http_request_duration_seconds_bucket{instance=~\"$instance\"}[1m])))", + "interval": "", + "legendFormat": "{{handler}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of Dataplane Server Requests (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:853", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:854", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "XDS and SDS requests are not taken into account because they are long-running requests", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 7, + "w": 8, + "x": 16, + "y": 45 + }, + "hiddenSeries": false, + "id": 56, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:695", + "alias": "/2.*/", + "color": "#73BF69" + }, + { + "$$hashKey": "object:696", + "alias": "/4.*/", + "color": "#FADE2A" + }, + { + "$$hashKey": "object:697", + "alias": "/5.*/", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (code) (rate(dp_server_http_response_size_bytes_count{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "{{code}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Response Codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:796", + "format": "cps", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:797", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 52 + }, + "id": 26, + "panels": [], + "title": "Kuma Discovery Service (KDS) - Mutltizone communication", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "This metric presents if policies are properly propagated from Global to Zones. All instances of global and zones in the system should have the same number of policies. This metric have additional latency of 1 minute (it is not computed on the fly when scraping is done)", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 53 + }, + "hiddenSeries": false, + "id": 61, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum by (zone, instance) (resources_count{instance=~\"$instance\",resource_type!~\"Dataplane|DataplaneInsight|Zone|ZoneInsight|ZoneIngress|ZoneIngressInsight|ZoneEgress|ZoneEgressInsight\"})", + "interval": "", + "legendFormat": "{{ zone }} - {{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Policies count (sync check)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "This metric presents if Dataplanes are properly propagated from Zones to Global. Keep in mind that Dataplanes from all zones != Dataplanes from global. All zones receive additional one dataplane of Ingress from other Zones. This metric have additional latency of 1 minute (it is not computed on the fly when scraping is done)", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 53 + }, + "hiddenSeries": false, + "id": 66, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (zone, instance) (resources_count{instance=~\"$instance\",resource_type=\"Dataplane\"})", + "interval": "", + "legendFormat": "{{ zone }} - {{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Dataplane count", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of zone CP connected to Global.", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 4, + "x": 0, + "y": 61 + }, + "hiddenSeries": false, + "id": 58, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "kds_streams_active{instance=~\"$instance\",zone=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - KDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of KDS messages exchanged between Global Control Plane and Zone Control Plane over KDS. Global sends to Zone policies and Ingress Dataplanes", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 4, + "y": 61 + }, + "hiddenSeries": false, + "id": 57, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:194", + "alias": "Configuration sent", + "color": "#5794F2" + }, + { + "$$hashKey": "object:195", + "alias": "Configuration accepted", + "color": "#73BF69" + }, + { + "$$hashKey": "object:196", + "alias": "Configuration rejected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:197", + "alias": "RPC Errors", + "color": "#C4162A" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_responses_sent{instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration sent", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"ACK\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Configuration accepted", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"NACK\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration rejected", + "refId": "C" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_handled_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",grpc_code!=\"OK\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "RPC Errors", + "refId": "D" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_started_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",instance=~\"$instance\",zone=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Rate", + "refId": "E" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - KDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1007", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:1008", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of KDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected control planes * KUMA_MULTIZONE_GLOBAL_KDS_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 9, + "y": 61 + }, + "hiddenSeries": false, + "id": 59, + "legend": { + "avg": false, + "current": false, + "hideZero": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(kds_generation_count{instance=~\"$instance\",zone=\"Global\"}[1m])) - sum(rate(kds_generation_errors{instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "expr": "sum(rate(kds_generation_errors{instance=~\"$instance\",zone=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - KDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:850", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:851", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to generate KDS configuration for a single zone control plane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 14, + "y": 61 + }, + "hiddenSeries": false, + "id": 60, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_generation{quantile=\"0.99\",instance=~\"$instance\",zone=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - Latency of KDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:988", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:989", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to deliver Envoy configuration and receive ACK/NACK for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 19, + "y": 61 + }, + "hiddenSeries": false, + "id": 83, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_delivery{quantile=\"0.99\",instance=~\"$instance\",zone=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - Latency of KDS config delivery (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of global CP connected to Zone.", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 4, + "x": 0, + "y": 69 + }, + "hiddenSeries": false, + "id": 63, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "kds_streams_active{instance=~\"$instance\",zone!=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - KDS active connections", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:534", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:535", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "Number of KDS messages exchanged between Global Control Plane and Zone Control Plane over KDS. Zone sends to Global its Dataplanes and DataplaneInsights", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 4, + "y": 69 + }, + "hiddenSeries": false, + "id": 62, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "$$hashKey": "object:194", + "alias": "Configuration sent", + "color": "#5794F2" + }, + { + "$$hashKey": "object:195", + "alias": "Configuration accepted", + "color": "#73BF69" + }, + { + "$$hashKey": "object:196", + "alias": "Configuration rejected", + "color": "#F2495C" + }, + { + "$$hashKey": "object:197", + "alias": "RPC Errors", + "color": "#C4162A" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_responses_sent{instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration sent", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"ACK\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Configuration accepted", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "sum(rate(kds_requests_received{confirmation=\"NACK\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Configuration rejected", + "refId": "C" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_handled_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",grpc_code!=\"OK\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "RPC Errors", + "refId": "D" + }, + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "expr": "sum(rate(grpc_server_started_total{grpc_service=\"kuma.mesh.v1alpha1.MultiplexService\",instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "hide": true, + "interval": "", + "legendFormat": "Rate", + "refId": "E" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - KDS message exchange", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1007", + "format": "ops", + "logBase": 1, + "show": true + }, + { + "$$hashKey": "object:1008", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Number of KDS config generations per second. Config is sent only when it's different than previously generated. The value should be the number of connected control planes * KUMA_MULTIZONE_ZONE_KDS_REFRESH_INTERVAL", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 9, + "y": 69 + }, + "hiddenSeries": false, + "id": 64, + "legend": { + "avg": false, + "current": false, + "hideZero": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [ + { + "alias": "Errors", + "color": "#F2495C" + } + ], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(kds_generation_count{instance=~\"$instance\",zone!=\"Global\"}[1m])) - sum(rate(kds_generation_errors{instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Success", + "refId": "A" + }, + { + "expr": "sum(rate(kds_generation_errors{instance=~\"$instance\",zone!=\"Global\"}[1m]))", + "interval": "", + "legendFormat": "Errors", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - KDS config generations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:850", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:851", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to generate KDS configuration for a global control plane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 14, + "y": 69 + }, + "hiddenSeries": false, + "id": 65, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_generation{quantile=\"0.99\",instance=~\"$instance\",zone!=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Zone - Latency of KDS config generation (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:988", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:989", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "description": "How much it took to deliver Envoy configuration and receive ACK/NACK for a single dataplane", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 5, + "x": 19, + "y": 69 + }, + "hiddenSeries": false, + "id": 84, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "exemplar": true, + "expr": "kds_delivery{quantile=\"0.99\",instance=~\"$instance\",zone!=\"Global\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Global - Latency of KDS config delivery (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:309", + "format": "ms", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:310", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 77 + }, + "id": 11, + "panels": [], + "title": "Store", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Latency of underlying storage (API Server on K8S, Postgres on Universal etc.)", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 7, + "x": 0, + "y": 78 + }, + "hiddenSeries": false, + "id": 12, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "histogram_quantile(0.99, sum by (operation, le) (rate(store_bucket{instance=~\"$instance\"}[1m])))", + "interval": "", + "legendFormat": "{{operation}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of Store operations (99th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:545", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:546", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Cache protects underlying storage by sharing responses between many goroutines accessing the storage.\n\nhit - request was retrieved from the cache.\n\nhit-wait - request was retrieved from the cache after waiting for a concurrent request to fetch it from the database.\n\nmiss - request was fetched from the database\n\nRefer to https://kuma.io/docs/latest/documentation/fine-tuning/#snapshot-generation", + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 5, + "x": 7, + "y": 78 + }, + "hiddenSeries": false, + "id": 14, + "legend": { + "alignAsTable": false, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": true, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(store_cache{result=\"hit\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit", + "refId": "A" + }, + { + "expr": "sum(rate(store_cache{result=\"hit-wait\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Hit Wait", + "refId": "C" + }, + { + "expr": "sum(rate(store_cache{result=\"miss\",instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "Miss", + "refId": "B" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Store cache performance", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:645", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:646", + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "description": "Real requests executed on the underlying storage (Postgres/Kubernetes API Server)", + "fill": 0, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 12, + "x": 12, + "y": 78 + }, + "hiddenSeries": false, + "id": 13, + "legend": { + "alignAsTable": true, + "avg": false, + "current": false, + "hideEmpty": true, + "hideZero": true, + "max": false, + "min": false, + "rightSide": true, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 2, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": true, + "steppedLine": false, + "targets": [ + { + "expr": "sum by (operation, resource_type) (rate(store_count{instance=~\"$instance\"}[1m]))", + "interval": "", + "legendFormat": "{{operation}} - {{resource_type}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Store operations", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "decimals": 2, + "format": "ops", + "logBase": 1, + "min": "0", + "show": true + }, + { + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "collapsed": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 87 + }, + "id": 35, + "panels": [], + "title": "Go Runtime", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 0, + "y": 88 + }, + "hiddenSeries": false, + "id": 30, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_goroutines{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Goroutines", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1463", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1464", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 6, + "y": 88 + }, + "hiddenSeries": false, + "id": 31, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_threads{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Threads", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1544", + "format": "short", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1545", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 12, + "y": 88 + }, + "hiddenSeries": false, + "id": 33, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_memstats_alloc_bytes{instance=~\"$instance\"}", + "interval": "", + "legendFormat": "{{ instance }}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Memory allocated", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1693", + "format": "bytes", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1694", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 6, + "x": 18, + "y": 88 + }, + "hiddenSeries": false, + "id": 32, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "8.3.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "go_gc_duration_seconds{instance=~\"$instance\", quantile=\"0.75\"}", + "interval": "", + "legendFormat": "{{ instance}}", + "refId": "A" + } + ], + "thresholds": [], + "timeRegions": [], + "title": "Latency of GC time (75th percentile)", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "mode": "time", + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:1774", + "format": "s", + "logBase": 1, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:1775", + "format": "short", + "logBase": 1, + "show": true + } + ], + "yaxis": { + "align": false + } + } + ], + "refresh": "5s", + "schemaVersion": 34, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": {}, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "definition": "label_values(cp_info, zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": false, + "name": "zone", + "options": [], + "query": { + "query": "label_values(cp_info, zone)", + "refId": "Prometheus-zone-Variable-Query" + }, + "refresh": 2, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "current": {}, + "datasource": { + "type": "prometheus", + "uid": "Prometheus" + }, + "definition": "label_values(cp_info{zone=~\"$zone\"}, instance)", + "hide": 0, + "includeAll": true, + "label": "Instance", + "multi": false, + "name": "instance", + "options": [], + "query": { + "query": "label_values(cp_info{zone=~\"$zone\"}, instance)", + "refId": "Prometheus-instance-Variable-Query" + }, + "refresh": 2, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Kuma CP", + "uid": "z6C1v-NGk", + "version": 1 + } +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: provisioning-dashboards-4 + namespace: kuma + labels: + app: grafana +data: + kuma-service.json: | + { + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "editable": true, + "gnetId": null, + "graphTooltip": 0, + "id": 1, + "iteration": 1619601383600, + "links": [], + "panels": [ + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "fixedColor": "green", + "mode": "fixed" + }, + "custom": {}, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 0 + }, + "id": 12, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "auto" + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "count(envoy_server_live{kuma_io_services=~\".*$service.*\"})", + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Dataplanes", + "transformations": [], + "type": "stat" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": null, + "filterable": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 0 + }, + "id": 23, + "options": { + "showHeader": false + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Dataplanes", + "transformations": [ + { + "id": "labelsToFields", + "options": {} + }, + { + "id": "organize", + "options": { + "excludeByName": { + "Time": true, + "Value": true, + "app": true, + "apps": true, + "env": true, + "envs": true, + "instance": true, + "job": true, + "k8s_kuma_io_name": true, + "k8s_kuma_io_namespace": true, + "kuma_io_protocol": true, + "kuma_io_protocols": true, + "kuma_io_service": true, + "kuma_io_services": true, + "mesh": true, + "namespace": true, + "pod": true, + "pod_template_hash": true, + "pod_template_hashs": true, + "version": true, + "versions": true + }, + "indexByName": {}, + "renameByName": { + "dataplane": "Dataplanes", + "env": "" + } + } + }, + { + "id": "merge", + "options": {} + } + ], + "type": "table" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": {}, + "displayName": "Incoming", + "mappings": [], + "noValue": "0", + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "reqps" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 8, + "x": 16, + "y": 0 + }, + "id": 15, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "value_and_name" + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\",envoy_cluster_name=~\"localhost_.*\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "C" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "", + "type": "stat" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": {}, + "displayName": "Outgoing", + "mappings": [], + "noValue": "0", + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "reqps" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 8, + "x": 16, + "y": 4 + }, + "id": 22, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "value_and_name" + }, + "pluginVersion": "7.4.3", + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\",envoy_cluster_name!~\"localhost_.*\",envoy_cluster_name!=\"kuma_envoy_admin\",envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "C" + } + ], + "timeFrom": null, + "timeShift": null, + "title": "", + "type": "stat" + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 8 + }, + "id": 14, + "panels": [], + "title": "HTTP", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "color": {}, + "custom": {}, + "thresholds": { + "mode": "absolute", + "steps": [] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 0, + "y": 9 + }, + "hiddenSeries": false, + "id": 4, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(histogram_quantile(0.99, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_services=~\".*$service.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p99", + "refId": "A" + }, + { + "expr": "max(histogram_quantile(0.95, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_services=~\".*$service.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p95", + "refId": "C" + }, + { + "expr": "max(histogram_quantile(0.50, rate(envoy_cluster_upstream_rq_time_bucket{kuma_io_services=~\".*$service.*\",kuma_io_zone=~\"$zone\",mesh=\"$mesh\",envoy_cluster_name=~\"localhost_.*\"}[1m])))", + "hide": false, + "interval": "", + "legendFormat": "p50", + "refId": "D" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Latency", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:631", + "format": "ms", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:632", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 8, + "y": 9 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name=~\"localhost_.*\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Incoming", + "refId": "C" + }, + { + "expr": "sum(rate(envoy_cluster_upstream_rq_total{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\",envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m]))", + "hide": false, + "interval": "", + "legendFormat": "Outgoing", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Traffic", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:429", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:430", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 9, + "w": 8, + "x": 16, + "y": 9 + }, + "hiddenSeries": false, + "id": 10, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name=~\"localhost_.*\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Incoming {{envoy_response_code_class}}xx", + "refId": "A" + }, + { + "expr": "sum(rate(envoy_cluster_external_upstream_rq_xx{mesh=\"$mesh\",kuma_io_zone=~\"$zone\",kuma_io_services=~\".*$service.*\", envoy_cluster_name!~\"localhost_.*\", envoy_cluster_name!=\"kuma_envoy_admin\", envoy_cluster_name!=\"kuma_metrics_hijacker\"}[1m])) by (envoy_response_code_class)", + "hide": false, + "interval": "", + "legendFormat": "Outgoing {{envoy_response_code_class}}xx", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Status codes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:242", + "format": "reqps", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:243", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "collapsed": false, + "datasource": null, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 18 + }, + "id": 17, + "panels": [], + "title": "Kubernetes", + "type": "row" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 19 + }, + "hiddenSeries": false, + "id": 8, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(sum(rate(container_cpu_usage_seconds_total[1m])) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane) /\nmax(sum(kube_pod_container_resource_limits_cpu_cores) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "hide": false, + "interval": "", + "legendFormat": "{{ dataplane }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "CPU", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:854", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:855", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 19 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(sum(container_memory_working_set_bytes{image!=\"\"}) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "hide": false, + "interval": "", + "legendFormat": "{{ dataplane }}", + "refId": "B" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Memory Utilization", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:44", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:45", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 19 + }, + "hiddenSeries": false, + "id": 7, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.4.3", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "expr": "max(sum(container_memory_working_set_bytes) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane) / max(sum(kube_pod_container_resource_limits_memory_bytes) by (namespace, pod) * on (namespace, pod) group_right(kuma_io_service) envoy_server_live{kuma_io_services=~\".*$service.*\"}) by (dataplane)", + "hide": false, + "interval": "", + "legendFormat": "{{ dataplane }}", + "refId": "A" + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Memory Saturation", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "$$hashKey": "object:854", + "format": "percentunit", + "label": null, + "logBase": 1, + "max": null, + "min": "0", + "show": true + }, + { + "$$hashKey": "object:855", + "format": "short", + "label": null, + "logBase": 1, + "max": null, + "min": null, + "show": true + } + ], + "yaxis": { + "align": false, + "alignLevel": null + } + } + ], + "refresh": "5s", + "schemaVersion": 27, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "datasource": null, + "definition": "label_values(envoy_server_live, mesh)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Mesh", + "multi": false, + "name": "mesh", + "options": [], + "query": { + "query": "label_values(envoy_server_live, mesh)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allFormat": "wildcard", + "allValue": null, + "current": {}, + "datasource": "Prometheus", + "definition": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "hide": 0, + "includeAll": true, + "label": "Zone", + "multi": true, + "name": "zone", + "options": [], + "query": "label_values(envoy_server_live{mesh=\"$mesh\"}, kuma_io_zone)", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + }, + { + "allValue": null, + "current": { + "selected": true, + "text": "backend_kuma-demo_svc_3001", + "value": "backend_kuma-demo_svc_3001" + }, + "datasource": null, + "definition": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, kuma_io_service)", + "description": null, + "error": null, + "hide": 0, + "includeAll": false, + "label": "Service", + "multi": false, + "name": "service", + "options": [], + "query": { + "query": "label_values(envoy_server_live{mesh=\"$mesh\",kuma_io_zone=~\"$zone\"}, kuma_io_service)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "tagValuesQuery": "", + "tags": [], + "tagsQuery": "", + "type": "query", + "useTags": false + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Kuma Service", + "uid": "FkJ7AxwMz", + "version": 1 + } +--- +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: kuma +spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: "8Gi" +--- +kind: ClusterRole +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + labels: + app: grafana + name: grafana-clusterrole +rules: [] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics +rules: + - apiGroups: + - "" + resources: + - namespaces + - nodes + - persistentvolumeclaims + - pods + - services + - resourcequotas + - replicationcontrollers + - limitranges + - persistentvolumeclaims + - persistentvolumes + - endpoints + - secrets + - configmaps + verbs: + - list + - watch + - apiGroups: + - extensions + resources: + - daemonsets + - deployments + - ingresses + - replicasets + verbs: + - list + - watch + - apiGroups: + - apps + resources: + - daemonsets + - deployments + - statefulsets + - replicasets + verbs: + - get + - list + - watch + - apiGroups: + - batch + resources: + - cronjobs + - jobs + verbs: + - list + - watch + - apiGroups: + - autoscaling + resources: + - horizontalpodautoscalers + verbs: + - list + - watch + - apiGroups: + - policy + resources: + - poddisruptionbudgets + verbs: + - list + - watch + - apiGroups: + - storage.k8s.io + resources: + - storageclasses + - volumeattachments + verbs: + - list + - watch + - apiGroups: + - certificates.k8s.io + resources: + - certificatesigningrequests + verbs: + - list + - watch + - apiGroups: + - networking.k8s.io + resources: + - networkpolicies + verbs: + - list + - watch + - apiGroups: + - admissionregistration.k8s.io + resources: + - validatingwebhookconfigurations + - mutatingwebhookconfigurations + verbs: + - list + - watch +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server +rules: + - apiGroups: + - "" + resources: + - nodes + - nodes/proxy + - nodes/metrics + - services + - endpoints + - pods + - ingresses + - configmaps + verbs: + - get + - list + - watch + - apiGroups: + - "extensions" + resources: + - ingresses/status + - ingresses + verbs: + - get + - list + - watch + - nonResourceURLs: + - "/metrics" + verbs: + - get +--- +kind: ClusterRoleBinding +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + name: grafana-clusterrolebinding + labels: + app: grafana +subjects: + - kind: ServiceAccount + name: grafana + namespace: kuma +roleRef: + kind: ClusterRole + name: grafana-clusterrole + apiGroup: rbac.authorization.k8s.io +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics +subjects: + - kind: ServiceAccount + name: prometheus-kube-state-metrics + namespace: kuma +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: prometheus-kube-state-metrics +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server +subjects: + - kind: ServiceAccount + name: prometheus-server + namespace: kuma +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: prometheus-server +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: grafana + namespace: kuma + labels: + app: grafana +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [grafana] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: grafana + namespace: default + labels: + app: grafana +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: grafana +subjects: + - kind: ServiceAccount + name: grafana + namespace: kuma +--- +apiVersion: v1 +kind: Service +metadata: + name: grafana + namespace: kuma + labels: + app: grafana +spec: + type: ClusterIP + ports: + - name: service + port: 80 + protocol: TCP + targetPort: 3000 + selector: + app: grafana +--- +apiVersion: v1 +kind: Service +metadata: + annotations: + prometheus.io/scrape: "true" + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: kuma +spec: + clusterIP: None + ports: + - name: http + port: 80 + protocol: TCP + targetPort: 8080 + - name: telemetry + port: 81 + protocol: TCP + targetPort: 8081 + selector: + component: "kube-state-metrics" + app: prometheus + type: "ClusterIP" +--- +apiVersion: v1 +kind: Service +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: kuma +spec: + ports: + - name: http + port: 80 + protocol: TCP + targetPort: 9090 + selector: + component: "server" + app: prometheus + sessionAffinity: None + type: "ClusterIP" +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: grafana + namespace: kuma + labels: + app: grafana +spec: + replicas: 1 + selector: + matchLabels: + app: grafana + strategy: + type: RollingUpdate + template: + metadata: + labels: + app: grafana + annotations: + checksum/config: 4fbce6ca7985bb33289922e68acc9af246f301cf9650f061fbcd0155925665df + checksum/dashboards-json-config: 01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b + checksum/sc-dashboard-provider-config: 01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b + checksum/secret: 281444758252a4bdd272546732dfb8e2be87be71b795d2aadc3726e3524f63e3 + spec: + serviceAccountName: grafana + securityContext: + fsGroup: 472 + runAsUser: 472 + initContainers: + - name: init-plugins + image: alpine + command: [ '/bin/sh', '-c', 'wget -O /tmp/kuma.zip https://github.com/kumahq/kuma-grafana-datasource/releases/download/v0.1.0/kumahq-kuma-datasource-0.1.0.zip && unzip /tmp/kuma.zip -d /var/lib/grafana/plugins/ && rm /tmp/kuma.zip'] + volumeMounts: + - name: plugins-volume + mountPath: /var/lib/grafana/plugins + containers: + - name: grafana + image: "grafana/grafana:8.5.2" + imagePullPolicy: IfNotPresent + volumeMounts: + - name: config + mountPath: "/etc/grafana/grafana.ini" + subPath: grafana.ini + readOnly: true + - name: storage + mountPath: "/var/lib/grafana" + - name: provisioning-datasource + mountPath: /etc/grafana/provisioning/datasources + readOnly: true + - name: provisioning-dashboards + mountPath: /etc/grafana/provisioning/dashboards + readOnly: true + - name: plugins-volume + mountPath: /var/lib/grafana/plugins + readOnly: true + ports: + - name: service + containerPort: 80 + protocol: TCP + - name: grafana + containerPort: 3000 + protocol: TCP + livenessProbe: + failureThreshold: 10 + httpGet: + path: /api/health + port: 3000 + initialDelaySeconds: 60 + timeoutSeconds: 30 + readinessProbe: + httpGet: + path: /api/health + port: 3000 + resources: + {} + volumes: + - name: config + configMap: + name: grafana + - name: provisioning-datasource + configMap: + name: provisioning-datasource + - name: provisioning-dashboards + projected: + sources: + - configMap: + name: provisioning-dashboards + + - configMap: + name: provisioning-dashboards-0 + + - configMap: + name: provisioning-dashboards-1 + + - configMap: + name: provisioning-dashboards-2 + + - configMap: + name: provisioning-dashboards-3 + + - configMap: + name: provisioning-dashboards-4 + + - name: storage + emptyDir: {} + - name: plugins-volume + emptyDir: {} +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + labels: + component: "kube-state-metrics" + app: prometheus + name: prometheus-kube-state-metrics + namespace: kuma +spec: + selector: + matchLabels: + component: "kube-state-metrics" + app: prometheus + replicas: 1 + template: + metadata: + labels: + component: "kube-state-metrics" + app: prometheus + spec: + serviceAccountName: prometheus-kube-state-metrics + containers: + - name: prometheus-kube-state-metrics + image: "quay.io/coreos/kube-state-metrics:v1.9.8" + imagePullPolicy: "IfNotPresent" + ports: + - name: metrics + containerPort: 8080 + - name: telemetry + containerPort: 8081 + resources: + {} + securityContext: + runAsUser: 65534 +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + labels: + component: "server" + app: prometheus + name: prometheus-server + namespace: kuma +spec: + selector: + matchLabels: + component: "server" + app: prometheus + replicas: 1 + template: + metadata: + labels: + component: "server" + app: prometheus + annotations: + kuma.io/direct-access-services: "*" + spec: + serviceAccountName: prometheus-server + containers: + - name: prometheus-server-configmap-reload + image: "jimmidyson/configmap-reload:v0.6.1" + imagePullPolicy: "IfNotPresent" + args: + - --volume-dir=/etc/config + - --webhook-url=http://127.0.0.1:9090/-/reload + resources: + {} + volumeMounts: + - name: config-volume + mountPath: /etc/config + readOnly: true + - name: prometheus-server + image: "prom/prometheus:v2.35.0" + imagePullPolicy: "IfNotPresent" + args: + - --storage.tsdb.retention.time=15d + - --config.file=/etc/config/prometheus.yml + - --storage.tsdb.path=/data + - --web.console.libraries=/etc/prometheus/console_libraries + - --web.console.templates=/etc/prometheus/consoles + - --web.enable-lifecycle + ports: + - containerPort: 9090 + resources: + {} + volumeMounts: + - name: config-volume + mountPath: /etc/config + - name: storage-volume + mountPath: /data + subPath: "" + securityContext: + fsGroup: 65534 + runAsGroup: 65534 + runAsUser: 65534 + terminationGracePeriodSeconds: 300 + volumes: + - name: config-volume + configMap: + name: prometheus-server + - name: storage-volume + persistentVolumeClaim: + claimName: prometheus-server +--- +apiVersion: v1 +kind: Namespace +metadata: + name: kuma +--- +apiVersion: v1 +kind: Namespace +metadata: + name: kuma +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki + namespace: kuma + labels: + app: loki + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'configMap' + - 'emptyDir' + - 'persistentVolumeClaim' + - 'secret' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'MustRunAsNonRoot' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + fsGroup: + rule: 'MustRunAs' + ranges: + - min: 1 + max: 65535 + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: policy/v1beta1 +kind: PodSecurityPolicy +metadata: + name: loki-promtail + namespace: kuma + labels: + app: promtail + release: loki +spec: + privileged: false + allowPrivilegeEscalation: false + volumes: + - 'secret' + - 'configMap' + - 'hostPath' + hostNetwork: false + hostIPC: false + hostPID: false + runAsUser: + rule: 'RunAsAny' + seLinux: + rule: 'RunAsAny' + supplementalGroups: + rule: 'RunAsAny' + fsGroup: + rule: 'RunAsAny' + readOnlyRootFilesystem: true + requiredDropCapabilities: + - ALL +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: loki + release: loki + annotations: + {} + name: loki + namespace: kuma +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + labels: + app: promtail + release: loki + name: loki-promtail + namespace: kuma +--- +apiVersion: v1 +kind: Secret +metadata: + name: loki + namespace: kuma + labels: + app: loki + release: loki +data: + loki.yaml: YXV0aF9lbmFibGVkOiBmYWxzZQpjaHVua19zdG9yZV9jb25maWc6CiAgbWF4X2xvb2tfYmFja19wZXJpb2Q6IDBzCmluZ2VzdGVyOgogIGNodW5rX2Jsb2NrX3NpemU6IDI2MjE0NAogIGNodW5rX2lkbGVfcGVyaW9kOiAzbQogIGNodW5rX3JldGFpbl9wZXJpb2Q6IDFtCiAgbGlmZWN5Y2xlcjoKICAgIHJpbmc6CiAgICAgIGt2c3RvcmU6CiAgICAgICAgc3RvcmU6IGlubWVtb3J5CiAgICAgIHJlcGxpY2F0aW9uX2ZhY3RvcjogMQogIHdhbDoKICAgIGVuYWJsZWQ6IGZhbHNlCmxpbWl0c19jb25maWc6CiAgZW5mb3JjZV9tZXRyaWNfbmFtZTogZmFsc2UKc2NoZW1hX2NvbmZpZzoKICBjb25maWdzOgogIC0gZnJvbTogIjIwMTgtMDQtMTUiCiAgICBpbmRleDoKICAgICAgcGVyaW9kOiAxNjhoCiAgICAgIHByZWZpeDogaW5kZXhfCiAgICBvYmplY3Rfc3RvcmU6IGZpbGVzeXN0ZW0KICAgIHNjaGVtYTogdjkKICAgIHN0b3JlOiBib2x0ZGIKc2VydmVyOgogIGh0dHBfbGlzdGVuX3BvcnQ6IDMxMDAKc3RvcmFnZV9jb25maWc6CiAgYm9sdGRiOgogICAgZGlyZWN0b3J5OiAvZGF0YS9sb2tpL2luZGV4CiAgZmlsZXN5c3RlbToKICAgIGRpcmVjdG9yeTogL2RhdGEvbG9raS9jaHVua3MKdGFibGVfbWFuYWdlcjoKICByZXRlbnRpb25fZGVsZXRlc19lbmFibGVkOiBmYWxzZQogIHJldGVudGlvbl9wZXJpb2Q6IDBzCg== +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: loki-promtail + namespace: kuma + labels: + app: promtail + release: loki +data: + promtail.yaml: | + client: + backoff_config: + max_period: 5s + max_retries: 20 + min_period: 100ms + batchsize: 102400 + batchwait: 1s + external_labels: {} + timeout: 10s + positions: + filename: /run/promtail/positions.yaml + server: + http_listen_port: 3101 + target_config: + sync_period: 10s + scrape_configs: + - job_name: kubernetes-pods-name + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - source_labels: + - __meta_kubernetes_pod_label_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-app + pipeline_stages: + - docker: {} + - match: + selector: '{container="kuma-sidecar"}' + stages: + - regex: + expression: '([\S]*) stdout ([\S]*) \[(?P[\S]*)\] (?P[\S]*)' + - labels: + mesh: mesh + - timestamp: + format: RFC3339Nano + source: timestamp + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: replace + separator: '.' + replacement: "$1" + source_labels: + - __meta_kubernetes_pod_annotation_kuma_io_mesh + - __meta_kubernetes_pod_name + - __meta_kubernetes_namespace + target_label: node_id + - action: drop + regex: .+ + source_labels: + - __meta_kubernetes_pod_label_name + - source_labels: + - __meta_kubernetes_pod_label_app + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-direct-controllers + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: drop + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-indirect-controller + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: .+ + separator: '' + source_labels: + - __meta_kubernetes_pod_label_name + - __meta_kubernetes_pod_label_app + - action: keep + regex: '[0-9a-z-.]+-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + - action: replace + regex: '([0-9a-z-.]+)-[0-9a-f]{8,10}' + source_labels: + - __meta_kubernetes_pod_controller_name + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_uid + - __meta_kubernetes_pod_container_name + target_label: __path__ + - job_name: kubernetes-pods-static + pipeline_stages: + - docker: {} + kubernetes_sd_configs: + - role: pod + relabel_configs: + - action: drop + regex: '' + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - action: replace + source_labels: + - __meta_kubernetes_pod_label_component + target_label: __service__ + - source_labels: + - __meta_kubernetes_pod_node_name + target_label: __host__ + - action: drop + regex: '' + source_labels: + - __service__ + - action: labelmap + regex: __meta_kubernetes_pod_label_(.+) + - action: replace + replacement: $1 + separator: / + source_labels: + - __meta_kubernetes_namespace + - __service__ + target_label: job + - action: replace + source_labels: + - __meta_kubernetes_namespace + target_label: namespace + - action: replace + source_labels: + - __meta_kubernetes_pod_name + target_label: pod + - action: replace + source_labels: + - __meta_kubernetes_pod_container_name + target_label: container + - replacement: /var/log/pods/*$1/*.log + separator: / + source_labels: + - __meta_kubernetes_pod_annotation_kubernetes_io_config_mirror + - __meta_kubernetes_pod_container_name + target_label: __path__ +--- +kind: ClusterRole +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + labels: + app: promtail + release: loki + name: loki-promtail-clusterrole + namespace: kuma +rules: + - apiGroups: [""] # "" indicates the core API group + resources: + - nodes + - nodes/proxy + - services + - endpoints + - pods + verbs: ["get", "watch", "list"] +--- +kind: ClusterRoleBinding +apiVersion: rbac.authorization.k8s.io/v1 +metadata: + name: loki-promtail-clusterrolebinding + labels: + app: promtail + release: loki +subjects: + - kind: ServiceAccount + name: loki-promtail + namespace: kuma +roleRef: + kind: ClusterRole + name: loki-promtail-clusterrole + apiGroup: rbac.authorization.k8s.io +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki-promtail + namespace: kuma + labels: + app: promtail + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki-promtail] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: loki + namespace: kuma + labels: + app: loki + release: loki +rules: + - apiGroups: ['extensions'] + resources: ['podsecuritypolicies'] + verbs: ['use'] + resourceNames: [loki] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki + namespace: kuma + labels: + app: loki + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki +subjects: + - kind: ServiceAccount + name: loki +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: loki-promtail + namespace: kuma + labels: + app: promtail + release: loki +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: loki-promtail +subjects: + - kind: ServiceAccount + name: loki-promtail +--- +apiVersion: v1 +kind: Service +metadata: + name: loki-headless + namespace: kuma + labels: + app: loki + release: loki + variant: headless +spec: + clusterIP: None + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: v1 +kind: Service +metadata: + name: loki + namespace: kuma + labels: + app: loki + release: loki + annotations: + {} +spec: + type: ClusterIP + ports: + - port: 3100 + protocol: TCP + name: http-metrics + targetPort: http-metrics + selector: + app: loki + release: loki +--- +apiVersion: apps/v1 +kind: DaemonSet +metadata: + name: loki-promtail + namespace: kuma + labels: + app: promtail + release: loki + annotations: + {} +spec: + selector: + matchLabels: + app: promtail + release: loki + updateStrategy: + {} + template: + metadata: + labels: + app: promtail + release: loki + annotations: + checksum/config: bce7daf9d5acc773342c4f42e700668ef8bdc8f34fa1499c766263fa0c1944e0 + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki-promtail + containers: + - name: promtail + image: "grafana/promtail:2.4.1" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/promtail/promtail.yaml" + - "-client.url=http://loki.kuma:3100/loki/api/v1/push" + volumeMounts: + - name: config + mountPath: /etc/promtail + - name: run + mountPath: /run/promtail + - mountPath: /var/lib/docker/containers + name: docker + readOnly: true + - mountPath: /var/log/pods + name: pods + readOnly: true + env: + - name: HOSTNAME + valueFrom: + fieldRef: + fieldPath: spec.nodeName + ports: + - containerPort: 3101 + name: http-metrics + securityContext: + readOnlyRootFilesystem: true + runAsGroup: 0 + runAsUser: 0 + readinessProbe: + failureThreshold: 5 + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 + resources: + {} + nodeSelector: + {} + affinity: + {} + tolerations: + - effect: NoSchedule + key: node-role.kubernetes.io/master + operator: Exists + volumes: + - name: config + configMap: + name: loki-promtail + - name: run + hostPath: + path: /run/promtail + - hostPath: + path: /var/lib/docker/containers + name: docker + - hostPath: + path: /var/log/pods + name: pods +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: loki + namespace: kuma + labels: + app: loki + release: loki + annotations: + {} +spec: + podManagementPolicy: OrderedReady + replicas: 1 + selector: + matchLabels: + app: loki + release: loki + serviceName: loki-headless + updateStrategy: + type: RollingUpdate + template: + metadata: + labels: + app: loki + name: loki + release: loki + annotations: + checksum/config: d4c94f4c6a73353362c10d2f844340cec8999b291ca88481ac162fbb5942617d + prometheus.io/port: http-metrics + prometheus.io/scrape: "true" + spec: + serviceAccountName: loki + securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + initContainers: + [] + containers: + - name: loki + image: "grafana/loki:2.5.0" + imagePullPolicy: IfNotPresent + args: + - "-config.file=/etc/loki/loki.yaml" + - "-target=all,table-manager" + volumeMounts: + - name: config + mountPath: /etc/loki + - name: storage + mountPath: "/data" + ports: + - name: http-metrics + containerPort: 3100 + protocol: TCP + livenessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + readinessProbe: + httpGet: + path: /ready + port: http-metrics + initialDelaySeconds: 45 + resources: + {} + securityContext: + readOnlyRootFilesystem: true + nodeSelector: + {} + affinity: + {} + tolerations: + [] + terminationGracePeriodSeconds: 4800 + volumes: + - name: config + secret: + secretName: loki + - name: storage + emptyDir: {} +--- +apiVersion: v1 +kind: Namespace +metadata: + name: kuma +--- +# Based on https://github.com/jaegertracing/jaeger-kubernetes/blob/master/all-in-one/jaeger-all-in-one-template.yml + +# +# Copyright 2017-2019 The Jaeger 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. +# + +apiVersion: v1 +kind: List +items: + - apiVersion: apps/v1 + kind: Deployment + metadata: + name: jaeger + namespace: kuma + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + spec: + replicas: 1 + selector: + matchLabels: + app: jaeger + strategy: + type: Recreate + template: + metadata: + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + annotations: + prometheus.io/scrape: "true" + prometheus.io/port: "16686" + spec: + containers: + - env: + - name: COLLECTOR_ZIPKIN_HOST_PORT + value: "9411" + image: jaegertracing/all-in-one:1.34.1 + name: jaeger + ports: + - containerPort: 5775 + protocol: UDP + - containerPort: 6831 + protocol: UDP + - containerPort: 6832 + protocol: UDP + - containerPort: 5778 + protocol: TCP + - containerPort: 16686 + protocol: TCP + - containerPort: 9411 + protocol: TCP + readinessProbe: + httpGet: + path: "/" + port: 14269 + initialDelaySeconds: 5 + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-query + namespace: kuma + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: query + spec: + selector: + matchLabels: + app: jaeger-query + ports: + - name: query-http + port: 80 + protocol: TCP + targetPort: 16686 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-collector + namespace: kuma + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: collector + spec: + selector: + matchLabels: + app: jaeger-collector + ports: + - name: jaeger-collector-tchannel + port: 14267 + protocol: TCP + targetPort: 14267 + - name: jaeger-collector-http + port: 14268 + protocol: TCP + targetPort: 14268 + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + type: ClusterIP + - apiVersion: v1 + kind: Service + metadata: + name: jaeger-agent + namespace: kuma + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: agent + spec: + selector: + matchLabels: + app: jaeger-agent + ports: + - name: agent-zipkin-thrift + port: 5775 + protocol: UDP + targetPort: 5775 + - name: agent-compact + port: 6831 + protocol: UDP + targetPort: 6831 + - name: agent-binary + port: 6832 + protocol: UDP + targetPort: 6832 + - name: agent-configs + port: 5778 + protocol: TCP + targetPort: 5778 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one + - apiVersion: v1 + kind: Service + metadata: + name: zipkin + namespace: kuma + labels: + app: jaeger + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: zipkin + spec: + selector: + matchLabels: + app: zipkin + ports: + - name: jaeger-collector-zipkin + port: 9411 + protocol: TCP + targetPort: 9411 + clusterIP: None + selector: + app.kubernetes.io/name: jaeger + app.kubernetes.io/component: all-in-one diff --git a/app/kumactl/cmd/install/testdata/install-tracing.defaults.golden.yaml b/app/kumactl/cmd/install/testdata/install-tracing.defaults.golden.yaml deleted file mode 100644 index 38bc5f5723d2..000000000000 --- a/app/kumactl/cmd/install/testdata/install-tracing.defaults.golden.yaml +++ /dev/null @@ -1,184 +0,0 @@ - ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kuma-tracing ---- -# Based on https://github.com/jaegertracing/jaeger-kubernetes/blob/master/all-in-one/jaeger-all-in-one-template.yml - -# -# Copyright 2017-2019 The Jaeger 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. -# - -apiVersion: v1 -kind: List -items: - - apiVersion: apps/v1 - kind: Deployment - metadata: - name: jaeger - namespace: kuma-tracing - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - spec: - replicas: 1 - selector: - matchLabels: - app: jaeger - strategy: - type: Recreate - template: - metadata: - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - annotations: - prometheus.io/scrape: "true" - prometheus.io/port: "16686" - spec: - containers: - - env: - - name: COLLECTOR_ZIPKIN_HOST_PORT - value: "9411" - image: jaegertracing/all-in-one:1.24 - name: jaeger - ports: - - containerPort: 5775 - protocol: UDP - - containerPort: 6831 - protocol: UDP - - containerPort: 6832 - protocol: UDP - - containerPort: 5778 - protocol: TCP - - containerPort: 16686 - protocol: TCP - - containerPort: 9411 - protocol: TCP - readinessProbe: - httpGet: - path: "/" - port: 14269 - initialDelaySeconds: 5 - - apiVersion: v1 - kind: Service - metadata: - name: jaeger-query - namespace: kuma-tracing - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: query - spec: - selector: - matchLabels: - app: jaeger-query - ports: - - name: query-http - port: 80 - protocol: TCP - targetPort: 16686 - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - type: ClusterIP - - apiVersion: v1 - kind: Service - metadata: - name: jaeger-collector - namespace: kuma-tracing - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: collector - spec: - selector: - matchLabels: - app: jaeger-collector - ports: - - name: jaeger-collector-tchannel - port: 14267 - protocol: TCP - targetPort: 14267 - - name: jaeger-collector-http - port: 14268 - protocol: TCP - targetPort: 14268 - - name: jaeger-collector-zipkin - port: 9411 - protocol: TCP - targetPort: 9411 - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - type: ClusterIP - - apiVersion: v1 - kind: Service - metadata: - name: jaeger-agent - namespace: kuma-tracing - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: agent - spec: - selector: - matchLabels: - app: jaeger-agent - ports: - - name: agent-zipkin-thrift - port: 5775 - protocol: UDP - targetPort: 5775 - - name: agent-compact - port: 6831 - protocol: UDP - targetPort: 6831 - - name: agent-binary - port: 6832 - protocol: UDP - targetPort: 6832 - - name: agent-configs - port: 5778 - protocol: TCP - targetPort: 5778 - clusterIP: None - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - - apiVersion: v1 - kind: Service - metadata: - name: zipkin - namespace: kuma-tracing - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: zipkin - spec: - selector: - matchLabels: - app: zipkin - ports: - - name: jaeger-collector-zipkin - port: 9411 - protocol: TCP - targetPort: 9411 - clusterIP: None - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one diff --git a/app/kumactl/cmd/install/testdata/install-tracing.overrides.golden.yaml b/app/kumactl/cmd/install/testdata/install-tracing.overrides.golden.yaml deleted file mode 100644 index 74df938b9d9f..000000000000 --- a/app/kumactl/cmd/install/testdata/install-tracing.overrides.golden.yaml +++ /dev/null @@ -1,184 +0,0 @@ - ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kuma ---- -# Based on https://github.com/jaegertracing/jaeger-kubernetes/blob/master/all-in-one/jaeger-all-in-one-template.yml - -# -# Copyright 2017-2019 The Jaeger 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. -# - -apiVersion: v1 -kind: List -items: - - apiVersion: apps/v1 - kind: Deployment - metadata: - name: jaeger - namespace: kuma - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - spec: - replicas: 1 - selector: - matchLabels: - app: jaeger - strategy: - type: Recreate - template: - metadata: - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - annotations: - prometheus.io/scrape: "true" - prometheus.io/port: "16686" - spec: - containers: - - env: - - name: COLLECTOR_ZIPKIN_HOST_PORT - value: "9411" - image: jaegertracing/all-in-one:1.24 - name: jaeger - ports: - - containerPort: 5775 - protocol: UDP - - containerPort: 6831 - protocol: UDP - - containerPort: 6832 - protocol: UDP - - containerPort: 5778 - protocol: TCP - - containerPort: 16686 - protocol: TCP - - containerPort: 9411 - protocol: TCP - readinessProbe: - httpGet: - path: "/" - port: 14269 - initialDelaySeconds: 5 - - apiVersion: v1 - kind: Service - metadata: - name: jaeger-query - namespace: kuma - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: query - spec: - selector: - matchLabels: - app: jaeger-query - ports: - - name: query-http - port: 80 - protocol: TCP - targetPort: 16686 - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - type: ClusterIP - - apiVersion: v1 - kind: Service - metadata: - name: jaeger-collector - namespace: kuma - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: collector - spec: - selector: - matchLabels: - app: jaeger-collector - ports: - - name: jaeger-collector-tchannel - port: 14267 - protocol: TCP - targetPort: 14267 - - name: jaeger-collector-http - port: 14268 - protocol: TCP - targetPort: 14268 - - name: jaeger-collector-zipkin - port: 9411 - protocol: TCP - targetPort: 9411 - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - type: ClusterIP - - apiVersion: v1 - kind: Service - metadata: - name: jaeger-agent - namespace: kuma - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: agent - spec: - selector: - matchLabels: - app: jaeger-agent - ports: - - name: agent-zipkin-thrift - port: 5775 - protocol: UDP - targetPort: 5775 - - name: agent-compact - port: 6831 - protocol: UDP - targetPort: 6831 - - name: agent-binary - port: 6832 - protocol: UDP - targetPort: 6832 - - name: agent-configs - port: 5778 - protocol: TCP - targetPort: 5778 - clusterIP: None - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one - - apiVersion: v1 - kind: Service - metadata: - name: zipkin - namespace: kuma - labels: - app: jaeger - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: zipkin - spec: - selector: - matchLabels: - app: zipkin - ports: - - name: jaeger-collector-zipkin - port: 9411 - protocol: TCP - targetPort: 9411 - clusterIP: None - selector: - app.kubernetes.io/name: jaeger - app.kubernetes.io/component: all-in-one diff --git a/app/kumactl/data/install/k8s/logging/loki/loki.yaml b/app/kumactl/data/install/k8s/logging/loki/loki.yaml index 6131524bcb4e..35dcb8599055 100644 --- a/app/kumactl/data/install/k8s/logging/loki/loki.yaml +++ b/app/kumactl/data/install/k8s/logging/loki/loki.yaml @@ -677,7 +677,7 @@ spec: [] containers: - name: loki - image: "grafana/loki:2.4.1" + image: "grafana/loki:2.5.0" imagePullPolicy: IfNotPresent args: - "-config.file=/etc/loki/loki.yaml" diff --git a/app/kumactl/data/install/k8s/metrics/grafana/grafana.yaml b/app/kumactl/data/install/k8s/metrics/grafana/grafana.yaml index 0a3a938272d1..f4c07a437d25 100644 --- a/app/kumactl/data/install/k8s/metrics/grafana/grafana.yaml +++ b/app/kumactl/data/install/k8s/metrics/grafana/grafana.yaml @@ -102,7 +102,7 @@ data: # org id. will default to orgId 1 if not specified orgId: 1 # url - url: http://prometheus-server.{{ .Namespace }} + url: {{.PrometheusAddress}} # database password, if used password: # database user, if used @@ -311,7 +311,7 @@ spec: mountPath: /var/lib/grafana/plugins containers: - name: grafana - image: "grafana/grafana:8.3.3" + image: "grafana/grafana:8.5.2" imagePullPolicy: IfNotPresent volumeMounts: - name: config diff --git a/app/kumactl/data/install/k8s/metrics/prometheus/alertmanager.yaml b/app/kumactl/data/install/k8s/metrics/prometheus/alertmanager.yaml deleted file mode 100644 index 7bdf2a3a7fc9..000000000000 --- a/app/kumactl/data/install/k8s/metrics/prometheus/alertmanager.yaml +++ /dev/null @@ -1,160 +0,0 @@ ---- -apiVersion: v1 -kind: ConfigMap -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: {{ .Namespace }} -data: - alertmanager.yml: | - global: {} - receivers: - - name: default-receiver - route: - group_interval: 5m - group_wait: 10s - receiver: default-receiver - repeat_interval: 3h ---- -apiVersion: v1 -kind: PersistentVolumeClaim -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: {{ .Namespace }} -spec: - accessModes: - - ReadWriteOnce - resources: - requests: - storage: "2Gi" ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: {{ .Namespace }} ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager -subjects: - - kind: ServiceAccount - name: prometheus-alertmanager - namespace: {{ .Namespace }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-alertmanager ---- -apiVersion: v1 -kind: Service -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: {{ .Namespace }} -spec: - ports: - - name: http - port: 80 - protocol: TCP - targetPort: 9093 - selector: - component: alertmanager - app: prometheus - sessionAffinity: None - type: "ClusterIP" ---- -# Source: prometheus/templates/alertmanager-deployment.yaml -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "alertmanager" - app: prometheus - name: prometheus-alertmanager - namespace: {{ .Namespace }} -spec: - selector: - matchLabels: - component: "alertmanager" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "alertmanager" - app: prometheus - spec: - serviceAccountName: prometheus-alertmanager - containers: - - name: prometheus-alertmanager - image: "prom/alertmanager:v0.23.0" - imagePullPolicy: "IfNotPresent" - env: - - name: POD_IP - valueFrom: - fieldRef: - apiVersion: v1 - fieldPath: status.podIP - args: - - --config.file=/etc/config/alertmanager.yml - - --storage.path=/data - - --cluster.advertise-address=$(POD_IP):6783 - - --web.external-url=http://localhost:9093 - ports: - - containerPort: 9093 - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - - name: storage-volume - mountPath: "/data" - subPath: "" - - name: prometheus-alertmanager-configmap-reload - image: "jimmidyson/configmap-reload:v0.6.1" - imagePullPolicy: "IfNotPresent" - args: - - --volume-dir=/etc/config - - --webhook-url=http://127.0.0.1:9093/-/reload - resources: - {} - volumeMounts: - - name: config-volume - mountPath: /etc/config - readOnly: true - securityContext: - fsGroup: 65534 - runAsGroup: 65534 - runAsUser: 65534 - volumes: - - name: config-volume - configMap: - name: prometheus-alertmanager - - name: storage-volume - persistentVolumeClaim: - claimName: prometheus-alertmanager diff --git a/app/kumactl/data/install/k8s/metrics/prometheus/node-exporter.yaml b/app/kumactl/data/install/k8s/metrics/prometheus/node-exporter.yaml deleted file mode 100644 index 650fd9eaeab7..000000000000 --- a/app/kumactl/data/install/k8s/metrics/prometheus/node-exporter.yaml +++ /dev/null @@ -1,84 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: {{ .Namespace }} ---- -apiVersion: v1 -kind: Service -metadata: - annotations: - prometheus.io/scrape: "true" - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: {{ .Namespace }} -spec: - clusterIP: None - ports: - - name: metrics - port: 9100 - protocol: TCP - targetPort: 9100 - selector: - component: "node-exporter" - app: prometheus - type: "ClusterIP" ---- -apiVersion: apps/v1 -kind: DaemonSet -metadata: - labels: - component: "node-exporter" - app: prometheus - name: prometheus-node-exporter - namespace: {{ .Namespace }} -spec: - selector: - matchLabels: - component: "node-exporter" - app: prometheus - updateStrategy: - type: RollingUpdate - template: - metadata: - labels: - component: "node-exporter" - app: prometheus - kuma.io/sidecar-injection: "disabled" # disabled for now, injecting DP crashes K8S cluster - spec: - serviceAccountName: prometheus-node-exporter - containers: - - name: prometheus-node-exporter - image: "prom/node-exporter:v1.3.1" - imagePullPolicy: "IfNotPresent" - args: - - --path.procfs=/host/proc - - --path.sysfs=/host/sys - ports: - - name: metrics - containerPort: 9100 - hostPort: 9100 - resources: - {} - volumeMounts: - - name: proc - mountPath: /host/proc - readOnly: true - - name: sys - mountPath: /host/sys - readOnly: true - hostNetwork: true - hostPID: true - volumes: - - name: proc - hostPath: - path: /proc - - name: sys - hostPath: - path: /sys diff --git a/app/kumactl/data/install/k8s/metrics/prometheus/pushgateway.yaml b/app/kumactl/data/install/k8s/metrics/prometheus/pushgateway.yaml deleted file mode 100644 index 68b5b41ba51d..000000000000 --- a/app/kumactl/data/install/k8s/metrics/prometheus/pushgateway.yaml +++ /dev/null @@ -1,89 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: {{ .Namespace }} ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -rules: - [] ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway -subjects: - - kind: ServiceAccount - name: prometheus-pushgateway - namespace: {{ .Namespace }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: prometheus-pushgateway ---- -apiVersion: v1 -kind: Service -metadata: - annotations: - prometheus.io/probe: pushgateway - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: {{ .Namespace }} -spec: - ports: - - name: http - port: 9091 - protocol: TCP - targetPort: 9091 - selector: - component: "pushgateway" - app: prometheus - type: "ClusterIP" ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - component: "pushgateway" - app: prometheus - name: prometheus-pushgateway - namespace: {{ .Namespace }} -spec: - selector: - matchLabels: - component: "pushgateway" - app: prometheus - replicas: 1 - template: - metadata: - labels: - component: "pushgateway" - app: prometheus - spec: - serviceAccountName: prometheus-pushgateway - containers: - - name: prometheus-pushgateway - image: "prom/pushgateway:v1.4.2" - imagePullPolicy: "IfNotPresent" - args: - ports: - - containerPort: 9091 - resources: - {} - securityContext: - runAsUser: 65534 diff --git a/app/kumactl/data/install/k8s/metrics/prometheus/server.yaml b/app/kumactl/data/install/k8s/metrics/prometheus/server.yaml index 746643701a2a..2c28541660b1 100644 --- a/app/kumactl/data/install/k8s/metrics/prometheus/server.yaml +++ b/app/kumactl/data/install/k8s/metrics/prometheus/server.yaml @@ -446,7 +446,7 @@ spec: mountPath: /etc/config readOnly: true - name: prometheus-server - image: "prom/prometheus:v2.32.1" + image: "prom/prometheus:v2.35.0" imagePullPolicy: "IfNotPresent" args: - --storage.tsdb.retention.time=15d diff --git a/app/kumactl/data/install/k8s/tracing/jaeger/all-in-one-template.yaml b/app/kumactl/data/install/k8s/tracing/jaeger/all-in-one-template.yaml index 7f0989c8c474..07bb55eabd77 100644 --- a/app/kumactl/data/install/k8s/tracing/jaeger/all-in-one-template.yaml +++ b/app/kumactl/data/install/k8s/tracing/jaeger/all-in-one-template.yaml @@ -47,7 +47,7 @@ items: - env: - name: COLLECTOR_ZIPKIN_HOST_PORT value: "9411" - image: jaegertracing/all-in-one:1.24 + image: jaegertracing/all-in-one:1.34.1 name: jaeger ports: - containerPort: 5775 diff --git a/app/kumactl/pkg/cmd/root_context.go b/app/kumactl/pkg/cmd/root_context.go index 2fc14d311600..3cd8f49b87e5 100644 --- a/app/kumactl/pkg/cmd/root_context.go +++ b/app/kumactl/pkg/cmd/root_context.go @@ -79,13 +79,11 @@ type RootContext struct { GenerateContext generate_context.GenerateContext InspectContext inspect_context.InspectContext InstallCpContext install_context.InstallCpContext - InstallMetricsContext install_context.InstallMetricsContext + InstallObservabilityContext install_context.InstallObservabilityContext InstallCRDContext install_context.InstallCrdsContext InstallDemoContext install_context.InstallDemoContext InstallGatewayKongContext install_context.InstallGatewayKongContext InstallGatewayKongEnterpriseContext install_context.InstallGatewayKongEnterpriseContext - InstallTracingContext install_context.InstallTracingContext - InstallLoggingContext install_context.InstallLoggingContext } func DefaultRootContext() *RootContext { @@ -116,12 +114,10 @@ func DefaultRootContext() *RootContext { }, InstallCpContext: install_context.DefaultInstallCpContext(), InstallCRDContext: install_context.DefaultInstallCrdsContext(), - InstallMetricsContext: install_context.DefaultInstallMetricsContext(), + InstallObservabilityContext: install_context.DefaultInstallObservabilityContext(), InstallDemoContext: install_context.DefaultInstallDemoContext(), InstallGatewayKongContext: install_context.DefaultInstallGatewayKongContext(), InstallGatewayKongEnterpriseContext: install_context.DefaultInstallGatewayKongEnterpriseContext(), - InstallTracingContext: install_context.DefaultInstallTracingContext(), - InstallLoggingContext: install_context.DefaultInstallLoggingContext(), GenerateContext: generate_context.DefaultGenerateContext(), } } diff --git a/docs/generated/cmd/kumactl/kumactl_install.md b/docs/generated/cmd/kumactl/kumactl_install.md index 85abc9685933..ed7ead66c50f 100644 --- a/docs/generated/cmd/kumactl/kumactl_install.md +++ b/docs/generated/cmd/kumactl/kumactl_install.md @@ -30,6 +30,7 @@ Install various Kuma components. * [kumactl install gateway](kumactl_install_gateway.md) - Install ingress gateway on Kubernetes * [kumactl install logging](kumactl_install_logging.md) - Install Logging backend in Kubernetes cluster (Loki) * [kumactl install metrics](kumactl_install_metrics.md) - Install Metrics backend in Kubernetes cluster (Prometheus + Grafana) +* [kumactl install observability](kumactl_install_observability.md) - Install Observability (Metrics, Logging, Tracing) backend in Kubernetes cluster (Prometheus + Grafana + Loki + Jaeger + Zipkin) * [kumactl install tracing](kumactl_install_tracing.md) - Install Tracing backend in Kubernetes cluster (Jaeger) * [kumactl install transparent-proxy](kumactl_install_transparent-proxy.md) - Install Transparent Proxy pre-requisites on the host diff --git a/docs/generated/cmd/kumactl/kumactl_install_logging.md b/docs/generated/cmd/kumactl/kumactl_install_logging.md index e6bca4070025..9b8034dfd959 100644 --- a/docs/generated/cmd/kumactl/kumactl_install_logging.md +++ b/docs/generated/cmd/kumactl/kumactl_install_logging.md @@ -13,8 +13,7 @@ kumactl install logging [flags] ### Options ``` - -h, --help help for logging - --namespace string namespace to install logging to (default "kuma-logging") + -h, --help help for logging ``` ### Options inherited from parent commands diff --git a/docs/generated/cmd/kumactl/kumactl_install_metrics.md b/docs/generated/cmd/kumactl/kumactl_install_metrics.md index 66b328ed7f2e..53da1e62a4e8 100644 --- a/docs/generated/cmd/kumactl/kumactl_install_metrics.md +++ b/docs/generated/cmd/kumactl/kumactl_install_metrics.md @@ -13,14 +13,7 @@ kumactl install metrics [flags] ### Options ``` - -h, --help help for metrics - --jaeger-address string the address of jaeger to query (default "http://jaeger-query.kuma-tracing") - --kuma-cp-address string the address of Kuma CP (default "http://kuma-control-plane.kuma-system:5676") - --loki-address string the address of the loki to query (default "http://loki.kuma-logging:3100") - -m, --mesh string mesh to use (default "default") - --namespace string namespace to install metrics to (default "kuma-metrics") - --without-grafana disable Grafana resources generation - --without-prometheus disable Prometheus resources generation + -h, --help help for metrics ``` ### Options inherited from parent commands diff --git a/docs/generated/cmd/kumactl/kumactl_install_observability.md b/docs/generated/cmd/kumactl/kumactl_install_observability.md new file mode 100644 index 000000000000..c29177fbeb3d --- /dev/null +++ b/docs/generated/cmd/kumactl/kumactl_install_observability.md @@ -0,0 +1,38 @@ +## kumactl install observability + +Install Observability (Metrics, Logging, Tracing) backend in Kubernetes cluster (Prometheus + Grafana + Loki + Jaeger + Zipkin) + +### Synopsis + +Install Observability (Metrics, Logging, Tracing) backend in Kubernetes cluster (Prometheus + Grafana + Loki + Jaeger + Zipkin) in its own namespace. + +``` +kumactl install observability [flags] +``` + +### Options + +``` + --components strings list of components (default [grafana,prometheus,loki,jaeger]) + -h, --help help for observability + --jaeger-address string the address of jaeger to query (default "http://jaeger-query.mesh-observability") + --kuma-cp-address string the address of Kuma CP (default "http://kuma-control-plane.kuma-system:5676") + --loki-address string the address of the loki to query (default "http://loki.mesh-observability:3100") + -m, --mesh string mesh to use (default "default") + --namespace string namespace to install observability to (default "mesh-observability") + --prometheus-address string the address of the prometheus server (default "http://prometheus-server.mesh-observability") +``` + +### Options inherited from parent commands + +``` + --api-timeout duration the timeout for api calls. It includes connection time, any redirects, and reading the response body. A timeout of zero means no timeout (default 1m0s) + --config-file string path to the configuration file to use + --log-level string log level: one of off|info|debug (default "off") + --no-config if set no config file and config directory will be created +``` + +### SEE ALSO + +* [kumactl install](kumactl_install.md) - Install various Kuma components. + diff --git a/docs/generated/cmd/kumactl/kumactl_install_tracing.md b/docs/generated/cmd/kumactl/kumactl_install_tracing.md index 8d7a21240360..2cebb53c064f 100644 --- a/docs/generated/cmd/kumactl/kumactl_install_tracing.md +++ b/docs/generated/cmd/kumactl/kumactl_install_tracing.md @@ -13,8 +13,7 @@ kumactl install tracing [flags] ### Options ``` - -h, --help help for tracing - --namespace string namespace to install tracing to (default "kuma-tracing") + -h, --help help for tracing ``` ### Options inherited from parent commands diff --git a/mk/kind.mk b/mk/kind.mk index 3f7819b9c51b..3be258be4b7a 100644 --- a/mk/kind.mk +++ b/mk/kind.mk @@ -124,10 +124,10 @@ kind/deploy/kuma/global: kind/deploy/kuma kind/deploy/kuma/local: KUMA_MODE=local kind/deploy/kuma/local: kind/deploy/kuma -.PHONY: kind/deploy/metrics -kind/deploy/metrics: build/kumactl - @KUBECONFIG=$(KIND_KUBECONFIG) ${BUILD_ARTIFACTS_DIR}/kumactl/kumactl install metrics | KUBECONFIG=$(KIND_KUBECONFIG) kubectl apply -f - - @KUBECONFIG=$(KIND_KUBECONFIG) kubectl wait --timeout=60s --for=condition=Ready -n kuma-metrics pods -l app=prometheus +.PHONY: kind/deploy/observability +kind/deploy/observability: build/kumactl + @KUBECONFIG=$(KIND_KUBECONFIG) ${BUILD_ARTIFACTS_DIR}/kumactl/kumactl install observability | KUBECONFIG=$(KIND_KUBECONFIG) kubectl apply -f - + @KUBECONFIG=$(KIND_KUBECONFIG) kubectl wait --timeout=60s --for=condition=Ready -n kuma-observability pods -l app=prometheus .PHONY: kind/deploy/metrics-server kind/deploy/metrics-server: diff --git a/test/framework/config.go b/test/framework/config.go index 4b6e162b4786..a7cf9d6649fe 100644 --- a/test/framework/config.go +++ b/test/framework/config.go @@ -30,7 +30,7 @@ type E2eConfig struct { KumaZoneUniversalEnvVars map[string]string `yaml:"universalZoneEnvVars,omitempty"` KumaK8sCtlFlags map[string]string `yaml:"k8sCtlFlags,omitempty"` KumaZoneK8sCtlFlags map[string]string `yaml:"k8sZoneCtlFlags,omitempty"` - DefaultTracingNamespace string `yaml:"tracingNamespace,omitempty"` + DefaultObservabilityNamespace string `yaml:"observabilityNamespace,omitempty"` DefaultGatewayNamespace string `yaml:"gatewayNamespace,omitempty"` KumaCPImageRepo string `yaml:"cpImageRepo,omitempty" envconfig:"KUMA_CP_IMAGE_REPOSITORY"` KumaDPImageRepo string `yaml:"dpImageRepo,omitempty" envconfig:"KUMA_DP_IMAGE_REPOSITORY"` @@ -149,7 +149,7 @@ var defaultConf = E2eConfig{ KumaNamespace: "kuma-system", KumaServiceName: "kuma-control-plane", KumaGlobalZoneSyncServiceName: "kuma-global-zone-sync", - DefaultTracingNamespace: "kuma-tracing", + DefaultObservabilityNamespace: "mesh-observability", DefaultGatewayNamespace: "kuma-gateway", CNIApp: "kuma-cni", CNINamespace: "kube-system", diff --git a/test/framework/deployments/tracing/kubernetes.go b/test/framework/deployments/tracing/kubernetes.go index 740f7079c0ce..fa3f42d3e9cd 100644 --- a/test/framework/deployments/tracing/kubernetes.go +++ b/test/framework/deployments/tracing/kubernetes.go @@ -17,7 +17,7 @@ type k8SDeployment struct { var _ Deployment = &k8SDeployment{} func (t *k8SDeployment) ZipkinCollectorURL() string { - return fmt.Sprintf("http://jaeger-collector.%s:9411/api/v2/spans", framework.Config.DefaultTracingNamespace) + return fmt.Sprintf("http://jaeger-collector.%s:9411/api/v2/spans", framework.Config.DefaultObservabilityNamespace) } func (t *k8SDeployment) TracedServices() ([]string, error) { @@ -30,7 +30,7 @@ func (t *k8SDeployment) Name() string { func (t *k8SDeployment) Deploy(cluster framework.Cluster) error { kumactl := framework.NewKumactlOptions(cluster.GetTesting(), cluster.GetKuma().GetName(), true) - yaml, err := kumactl.KumactlInstallTracing() + yaml, err := kumactl.KumactlInstallObservability() if err != nil { return err } @@ -42,7 +42,7 @@ func (t *k8SDeployment) Deploy(cluster framework.Cluster) error { } k8s.WaitUntilNumPodsCreated(cluster.GetTesting(), - cluster.GetKubectlOptions(framework.Config.DefaultTracingNamespace), + cluster.GetKubectlOptions(framework.Config.DefaultObservabilityNamespace), metav1.ListOptions{ LabelSelector: "app=jaeger", }, @@ -51,7 +51,7 @@ func (t *k8SDeployment) Deploy(cluster framework.Cluster) error { framework.DefaultTimeout) pods := k8s.ListPods(cluster.GetTesting(), - cluster.GetKubectlOptions(framework.Config.DefaultTracingNamespace), + cluster.GetKubectlOptions(framework.Config.DefaultObservabilityNamespace), metav1.ListOptions{ LabelSelector: "app=jaeger", }, @@ -61,19 +61,19 @@ func (t *k8SDeployment) Deploy(cluster framework.Cluster) error { } k8s.WaitUntilPodAvailable(cluster.GetTesting(), - cluster.GetKubectlOptions(framework.Config.DefaultTracingNamespace), + cluster.GetKubectlOptions(framework.Config.DefaultObservabilityNamespace), pods[0].Name, framework.DefaultRetries, framework.DefaultTimeout) - t.jaegerApiTunnel = k8s.NewTunnel(cluster.GetKubectlOptions(framework.Config.DefaultTracingNamespace), k8s.ResourceTypePod, pods[0].Name, 0, 16686) + t.jaegerApiTunnel = k8s.NewTunnel(cluster.GetKubectlOptions(framework.Config.DefaultObservabilityNamespace), k8s.ResourceTypePod, pods[0].Name, 0, 16686) t.jaegerApiTunnel.ForwardPort(cluster.GetTesting()) return nil } func (t *k8SDeployment) Delete(cluster framework.Cluster) error { kumactl := framework.NewKumactlOptions(cluster.GetTesting(), cluster.GetKuma().GetName(), true) - yaml, err := kumactl.KumactlInstallTracing() + yaml, err := kumactl.KumactlInstallObservability() if err != nil { return err } @@ -84,6 +84,6 @@ func (t *k8SDeployment) Delete(cluster framework.Cluster) error { if err != nil { return err } - cluster.(*framework.K8sCluster).WaitNamespaceDelete(framework.Config.DefaultTracingNamespace) + cluster.(*framework.K8sCluster).WaitNamespaceDelete(framework.Config.DefaultObservabilityNamespace) return nil } diff --git a/test/framework/kumactl.go b/test/framework/kumactl.go index 48d0a9bdd21f..342b17599224 100644 --- a/test/framework/kumactl.go +++ b/test/framework/kumactl.go @@ -151,12 +151,8 @@ func (k *KumactlOptions) KumactlInstallCP(mode string, args ...string) (string, cmd...) } -func (k *KumactlOptions) KumactlInstallMetrics() (string, error) { - return k.RunKumactlAndGetOutput("install", "metrics") -} - -func (k *KumactlOptions) KumactlInstallTracing() (string, error) { - return k.RunKumactlAndGetOutput("install", "tracing") +func (k *KumactlOptions) KumactlInstallObservability() (string, error) { + return k.RunKumactlAndGetOutput("install", "observability") } func (k *KumactlOptions) KumactlConfigControlPlanesAdd(name, address, token string) error {