级联平台添加GPS订阅支持
This commit is contained in:
@@ -23,7 +23,7 @@ public class GPSMsgInfo {
|
||||
private double speed;
|
||||
|
||||
/**
|
||||
* 产生通知时间,
|
||||
* 产生通知时间, 时间格式: 2020-01-14T14:32:12
|
||||
*/
|
||||
private String time;
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ public class RedisGPSMsgListener implements MessageListener {
|
||||
@Override
|
||||
public void onMessage(Message message, byte[] bytes) {
|
||||
GPSMsgInfo gpsMsgInfo = JSON.parseObject(message.getBody(), GPSMsgInfo.class);
|
||||
System.out.println(JSON.toJSON(gpsMsgInfo));
|
||||
redisCatchStorage.updateGpsMsgInfo(gpsMsgInfo);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user