From bc75abd022bd3b59b2bb99d74bf5ae1b07b60cdf Mon Sep 17 00:00:00 2001 From: pengtao Date: Mon, 19 Aug 2019 17:04:09 +0800 Subject: [PATCH] =?UTF-8?q?=20=E6=96=B0=E5=A2=9E=E5=AE=9E=E6=97=B6?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E9=87=87=E9=9B=86=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/config_real.py | 2 +- ops/myinflux.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/config/config_real.py b/config/config_real.py index 5694db3..8f0b6ab 100644 --- a/config/config_real.py +++ b/config/config_real.py @@ -3,5 +3,5 @@ # gameid,channel,event_type is_debug = True -My_influx = {'host': '10.10.3.19', 'port': 8086, 'username': 'miles', 'password': 'aspect', 'database': 'useronline'} +My_influx = {'host': '10.10.3.19', 'port': 8086, 'username': 'miles', 'password': 'aspect', 'database': 'real_data'} influx_meas = 'real_game_data' diff --git a/ops/myinflux.py b/ops/myinflux.py index 3bb9475..82c8876 100644 --- a/ops/myinflux.py +++ b/ops/myinflux.py @@ -16,6 +16,7 @@ class Myinflux: def _write(self, body): try: self.influxdb.write_points(body) + print(f"write {body} 2 influx!") return True except exceptions.InfluxDBClientError: log.error(f"write {body} to influx failed!", exc_info=True)