# -*- coding: utf-8 -*-
# @ModuleName: flowpool_abtest_config_update
# @Author: Liqian
# @Time: 2023/9/23 13:31
# @Software: PyCharm
import json
from my_config import set_config
from log import Log
from db_helper import RedisHelper

config_, _ = set_config()
log_ = Log()

flow_pool_abtest_config = {
    'control_group': [],
    'experimental_flow_set_level': [8, 9, 10, 11, 12, 13, 14, 15, 16],
    'experimental_flow_set_level_score':[7]
}
log_.info(f"flow_pool_abtest_config: {flow_pool_abtest_config}")
redis_helper = RedisHelper()
redis_helper.set_data_to_redis(
    key_name=config_.FLOWPOOL_ABTEST_KEY_NAME, value=json.dumps(flow_pool_abtest_config), expire_time=365 * 24 * 3600
)
redis_helper.persist_key(key_name=config_.FLOWPOOL_ABTEST_KEY_NAME)
log_.info(f"flow_pool_abtest_config update finished!")
