fix some error
This commit is contained in:
parent
1d3cf3b7d3
commit
66d1d1bb9a
@ -9,14 +9,12 @@ from mysql.mmysql import MysqlBase
|
||||
from config import mysql_promotion_config
|
||||
from log.mylog import define_logger
|
||||
import logging
|
||||
from config import BEGIN, END, ad_list_interface_port
|
||||
|
||||
mydb = MysqlBase(**mysql_promotion_config)
|
||||
define_logger("/data/logs/make_ad_cache.log")
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
BEGIN = '1999-01-01'
|
||||
END = '3000-01-01'
|
||||
|
||||
|
||||
def send_cache_data():
|
||||
now = datetime.datetime.today().strftime("%Y-%m-%d %H:%M:%S")
|
||||
@ -161,7 +159,7 @@ if __name__ == "__main__":
|
||||
send_cache_data()
|
||||
print('start!')
|
||||
app = make_app()
|
||||
app.listen('5555')
|
||||
app.listen(ad_list_interface_port)
|
||||
tornado.ioloop.PeriodicCallback(send_cache_data, 60000).start()
|
||||
# tornado.ioloop.IOLoop.current().call_at(time.time() + 60, lambda: sendNotify(conf, conf['sendtime1']))
|
||||
tornado.ioloop.IOLoop.current().start()
|
||||
|
@ -2,5 +2,10 @@
|
||||
redis_company_config = {'host': '192.168.100.20', 'port': 6379, 'db': 1}
|
||||
expire_time = 7200
|
||||
mysql_promotion_config = {'user': 'miles', 'pswd': 'aspect', 'host': '192.168.100.30', 'db': 'test'}
|
||||
ad_list_interface_port=5555
|
||||
BEGIN = '1999-01-01'
|
||||
END = '3000-01-01'
|
||||
|
||||
|
||||
#mysql_promotion_config = {'user': 'mytga', 'pswd': 'gzVwh4HGR68G', 'host': '10.10.3.5', 'db': 'games_report'}
|
||||
#redis_company_config = {'host': '10.10.3.10', 'port': 6379, 'db': 2}
|
||||
|
Loading…
x
Reference in New Issue
Block a user