This repository was archived by the owner on Apr 1, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
google/cloud/bigtable/data/_metrics Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3636# by default, exceptions in the metrics system are logged,
3737# but enabling this flag causes them to be raised instead
3838ALLOW_METRIC_EXCEPTIONS = os .getenv ("BIGTABLE_METRICS_EXCEPTIONS" , False )
39- LOGGER = (
40- logging .getLogger (__name__ ) if os .getenv ("BIGTABLE_METRICS_LOGS" , False ) else None
41- )
39+ LOGGER = logging .getLogger (__name__ )
4240
4341# default values for zone and cluster data, if not captured
4442DEFAULT_ZONE = "global"
@@ -429,8 +427,7 @@ def _handle_error(message: str) -> None:
429427 full_message = f"Error in Bigtable Metrics: { message } "
430428 if ALLOW_METRIC_EXCEPTIONS :
431429 raise ValueError (full_message )
432- if LOGGER :
433- LOGGER .warning (full_message )
430+ LOGGER .warning (full_message )
434431
435432 async def __aenter__ (self ):
436433 """
You can’t perform that action at this time.
0 commit comments