From 270fb15ebf54d5d0e6f675c87981e0b378529247 Mon Sep 17 00:00:00 2001 From: Mr Chen Date: Mon, 6 May 2024 17:01:05 +0800 Subject: [PATCH] Update index.py --- plugins/mongodb/index.py | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/plugins/mongodb/index.py b/plugins/mongodb/index.py index a5b3e2a92..01902da4e 100755 --- a/plugins/mongodb/index.py +++ b/plugins/mongodb/index.py @@ -1122,28 +1122,11 @@ def replClose(): setConfig(d) restart() - ip = getConfIp() - port = getConfPort() - - host = ip+':'+str(port) - config = { - '_id': 'test', - "version":1, - 'members': [ - {'_id': 1, 'host': host, 'votes':1}, - # {'_id': 1, 'host': '127.0.0.1:27017','votes':1}, - ] - } - client = mongdbClient() db = client.admin try: - # client.drop_database('local') - # print(repl_info) - # rstatus = db.command('replSetReconfig',config,force=True) restart() except Exception as e: - # info = str(e).split(',') return mw.returnJson(False, str(e)) return mw.returnJson(True, '关闭副本同步成功!')