Browse Source

fix connection to redis cluster in online notification thread

Grant Limberg 5 years ago
parent
commit
c2409ad6c9
1 changed files with 1 additions and 2 deletions
  1. 1 2
      controller/PostgreSQL.cpp

+ 1 - 2
controller/PostgreSQL.cpp

@@ -1666,8 +1666,7 @@ void PostgreSQL::onlineNotification_Redis()
 		try {
 		try {
 			if (!lastOnline.empty()) {
 			if (!lastOnline.empty()) {
 				if (_rc->clusterMode) {
 				if (_rc->clusterMode) {
-					auto redis = _cluster->redis(controllerId);
-					auto tx = redis.transaction(true);
+					auto tx = _cluster->transaction(controllerId, true);
 					_doRedisUpdate(tx, controllerId, lastOnline);
 					_doRedisUpdate(tx, controllerId, lastOnline);
 				} else {
 				} else {
 					auto tx = _redis->transaction(true);
 					auto tx = _redis->transaction(true);