sortega commented on code in PR #70517:
URL: https://github.com/apache/airflow/pull/70517#discussion_r3803872093
##########
shared/observability/src/airflow_shared/observability/metrics/statsd_logger.py:
##########
@@ -171,12 +173,31 @@ def get_statsd_logger(
statsd_influxdb_enabled: bool = False,
) -> SafeStatsdLogger:
"""Return logger for StatsD."""
- statsd = stats_class(
- host=host,
- port=port,
- prefix=prefix,
- ipv6=ipv6,
- )
+ if socket_path is not None:
+ if stats_class is None:
+ stats_class = UnixSocketStatsClient
+ elif isinstance(stats_class, type) and not issubclass(stats_class,
UnixSocketStatsClient):
+ raise ValueError(
Review Comment:
I managed to keep the check in the other file
--
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]