You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "hussein-awala (via GitHub)" <gi...@apache.org> on 2023/03/05 23:02:56 UTC

[GitHub] [airflow] hussein-awala commented on a diff in pull request #29881: Blocklist to disable specific metric tags or metric names

hussein-awala commented on code in PR #29881:
URL: https://github.com/apache/airflow/pull/29881#discussion_r1125751437


##########
airflow/stats.py:
##########
@@ -291,10 +315,11 @@ def wrapper(self, stat=None, *args, tags=None, **kwargs):
         if self.influxdb_tags_enabled:
             if stat is not None and tags is not None:
                 for k, v in tags.items():
-                    if all((c not in [",", "="] for c in v + k)):
-                        stat += f",{k}={v}"
-                    else:
-                        log.error("Dropping invalid tag: %s=%s.", k, v)
+                    if self.metric_tags_validator.test(k):

Review Comment:
   Why do we need to check if the tag is filtered here?



-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org