turboFei commented on code in PR #3316: URL: https://github.com/apache/celeborn/pull/3316#discussion_r2136287366
########## assets/grafana/.lint: ########## @@ -0,0 +1,30 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You 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. +# + +# See https://github.com/grafana/dashboard-linter/blob/main/docs/index.md#exclusions-and-warnings + +exclusions: + template-datasource-rule: + reason: Celeborn uses ${DS_PROMETHEUS} variable in the template, which is not supported by the rule. + panel-datasource-rule: + reason: Celeborn uses ${DS_PROMETHEUS} variable in the template, which is not supported by the rule. + panel-title-description-rule: + reason: Some panels have a title but no description. + template-on-time-change-reload-rule: + reason: Allow dashboard variables not to reload on time change. + uneditable-dashboard: + reason: Celeborn dashboards are editable. Review Comment: > It looks like this lint hasn't found any issues with the Grafana dashboard. @FMX With the exclusions, the other lint rules passed, see all the rules in https://github.com/grafana/dashboard-linter/blob/main/docs/index.md#rules ``` (base) ➜ celeborn git:(dashboard) dashboard-linter rules * `template-datasource-rule` - Checks that the dashboard has a templated datasource. * `template-job-rule` - Checks that the dashboard has a templated job. * `template-instance-rule` - Checks that the dashboard has a templated instance. * `template-label-promql-rule` - Checks that the dashboard templated labels have proper PromQL expressions. * `template-on-time-change-reload-rule` - Checks that the dashboard template variables are configured to reload on time change. * `panel-datasource-rule` - Checks that each panel uses the templated datasource. * `panel-title-description-rule` - Checks that each panel has a title and description. * `panel-units-rule` - Checks that each panel uses has valid units defined. * `panel-no-targets-rule` - Checks that each panel has at least one target. * `target-logql-rule` - Checks that each target uses a valid LogQL query. * `target-logql-auto-rule` - Checks that each Loki target uses $__auto for range vectors when appropriate. * `target-promql-rule` - Checks that each target uses a valid PromQL query. * `target-rate-interval-rule` - Checks that each target uses $__rate_interval. * `target-job-rule` - Checks that every PromQL query has a job matcher. * `target-instance-rule` - Checks that every PromQL query has a instance matcher. * `target-counter-agg-rule` - Checks that any counter metric (ending in _total) is aggregated with rate, irate, or increase. * `uneditable-dashboard` - Checks that the dashboard is not editable. ``` As mentioned in https://github.com/grafana/dashboard-linter/tree/main?tab=readme-ov-file#grafana-dashboard-linter, ``` This tool is a command-line application to lint Grafana dashboards for common mistakes. This tool is a work in progress and it's still very early days. ``` It can not detect the duplicate IDs, so I also introduce `lint_grafana.py` for that. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
