Browse Source

Merge branch 'develop' of ssh://gitlab.fuxicarbon.com:1111/client_service/voice-gateway-service into develop

shanghui 2 months ago
parent
commit
3e0ea852c0
2 changed files with 3 additions and 0 deletions
  1. 2 0
      src/core/callcenter/agent.py
  2. 1 0
      src/core/callcenter/registry.py

+ 2 - 0
src/core/callcenter/agent.py

@@ -291,6 +291,8 @@ class AgentOperService:
         members = self.redis_handler.redis.hgetall(name)
         if not members:
             return
+
+        registry.MANUAL_AGENT_LIVES.set(len(members))
         for k,v in members.items():
             check_out_daemon(name, k, v)
         # time.sleep(1)

+ 1 - 0
src/core/callcenter/registry.py

@@ -42,5 +42,6 @@ BOT_CREATE_ACCOUNT_LATENCY = Histogram('bot_create_account_latency',  '创建虚
 
 FLASK_ACTIVE_THREADS = Gauge('flask_active_threads', 'Number of active threads')
 BOT_AGENT_LIVES = Gauge('bot_agent_lives', 'Number of active agents')
+MANUAL_AGENT_LIVES = Gauge('manual_agent_lives', 'Number of active agents')