|
@@ -138,7 +138,7 @@ class MessageService extends BaseService
|
|
|
*/
|
|
*/
|
|
|
public function getGroupList($userId)
|
|
public function getGroupList($userId)
|
|
|
{
|
|
{
|
|
|
- $cachekey = "caches:messages:topList_{$userId}";
|
|
|
|
|
|
|
+ $cachekey = "caches:message:topList_{$userId}";
|
|
|
$datas = RedisService::get($cachekey);
|
|
$datas = RedisService::get($cachekey);
|
|
|
if($datas){
|
|
if($datas){
|
|
|
$datas['cache'] = true;
|
|
$datas['cache'] = true;
|
|
@@ -188,7 +188,7 @@ class MessageService extends BaseService
|
|
|
$item['unread'] = intval($unread);
|
|
$item['unread'] = intval($unread);
|
|
|
$total += intval($unread);
|
|
$total += intval($unread);
|
|
|
}
|
|
}
|
|
|
- RedisService::set($cachekey, ['list'=>$datas,'total'=>$total,'types'=>$types], rand(3,5));
|
|
|
|
|
|
|
+ RedisService::set($cachekey, ['list'=>$datas,'total'=>$total,'types'=>$types], rand(2,3));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
return ['list'=>$datas,'total'=> $total,'types'=>$types];
|
|
return ['list'=>$datas,'total'=> $total,'types'=>$types];
|