1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-01 08:21:15 +03:00

More commenting out of statsd

This commit is contained in:
Matthew Jones 2016-04-06 16:42:30 -04:00
parent 3ba591cea2
commit c0afa3ca0f

View File

@ -50,28 +50,25 @@ import psutil
# Only use statsd if there's a statsd host in the environment # Only use statsd if there's a statsd host in the environment
# otherwise just do a noop. # otherwise just do a noop.
if os.environ.get('GRAPHITE_PORT_8125_UDP_ADDR'): # NOTE: I've disabled this for the time being until we sort through the venv dependency around this
from statsd import StatsClient # if os.environ.get('GRAPHITE_PORT_8125_UDP_ADDR'):
statsd = StatsClient(host=os.environ['GRAPHITE_PORT_8125_UDP_ADDR'], # from statsd import StatsClient
port=8125, # statsd = StatsClient(host=os.environ['GRAPHITE_PORT_8125_UDP_ADDR'],
prefix='tower.job.event_callback', # port=8125,
maxudpsize=512) # prefix='tower.job.event_callback',
else: # maxudpsize=512)
from statsd import StatsClient # else:
# from statsd import StatsClient
class NoStatsClient(StatsClient): # class NoStatsClient(StatsClient):
def __init__(self, *args, **kwargs): # def __init__(self, *args, **kwargs):
pass # pass
# def _prepare(self, stat, value, rate):
def _prepare(self, stat, value, rate): # pass
pass # def _send_stat(self, stat, value, rate):
# pass
def _send_stat(self, stat, value, rate): # def _send(self, *args, **kwargs):
pass # pass
# statsd = NoStatsClient()
def _send(self, *args, **kwargs):
pass
statsd = NoStatsClient()
CENSOR_FIELD_WHITELIST=[ CENSOR_FIELD_WHITELIST=[
'msg', 'msg',