|
@@ -2,6 +2,7 @@ package com.fdkk.fdkkmeta.redis.impl;
|
|
|
|
|
|
import com.alibaba.fastjson.JSON;
|
|
import com.alibaba.fastjson.JSON;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
|
+import com.fdkk.fdkkmeta.grpc.JoystickRequest;
|
|
import com.fdkk.fdkkmeta.grpc.RotateRequest;
|
|
import com.fdkk.fdkkmeta.grpc.RotateRequest;
|
|
import com.fdkk.fdkkmeta.redis.RedisSubscribeService;
|
|
import com.fdkk.fdkkmeta.redis.RedisSubscribeService;
|
|
import com.fdkk.fdkkmeta.util.ProtoJsonUtils;
|
|
import com.fdkk.fdkkmeta.util.ProtoJsonUtils;
|
|
@@ -30,6 +31,17 @@ public class RedisSubscribeServiceImpl implements RedisSubscribeService {
|
|
RotateRequest.Builder builder = RotateRequest.newBuilder();
|
|
RotateRequest.Builder builder = RotateRequest.newBuilder();
|
|
ProtoJsonUtils.toProtoBean(builder,message);
|
|
ProtoJsonUtils.toProtoBean(builder,message);
|
|
log.info("builder-userid,{}",builder.getUserId());
|
|
log.info("builder-userid,{}",builder.getUserId());
|
|
|
|
+ }
|
|
|
|
|
|
|
|
+ @Override
|
|
|
|
+ public void joystickMessage(String message) {
|
|
|
|
+ if (Objects.isNull(message)) {
|
|
|
|
+ log.error("消息为空");
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ log.info("订阅频道:joystickMessage消息:{}", message);
|
|
|
|
+ JoystickRequest.Builder builder = JoystickRequest.newBuilder();
|
|
|
|
+ ProtoJsonUtils.toProtoBean(builder,message);
|
|
|
|
+ log.info("builder-userid,{}",builder.getUserId());
|
|
}
|
|
}
|
|
}
|
|
}
|