Commit f6a297f4 by 111-PC\111

[+]pulsar消费服务

1 parent 30ec5a2d
...@@ -32,6 +32,7 @@ public class NoticeController { ...@@ -32,6 +32,7 @@ public class NoticeController {
// 解密请求体信息 // 解密请求体信息
try { try {
log.info("消息内容{}",requestBody); log.info("消息内容{}",requestBody);
JSONObject jsonObject1 = JSONObject.parseObject(requestBody);
// 解密传过来的状态值 // 解密传过来的状态值
AqaraEvent aqaraEvent = JSONObject.parseObject(requestBody, AqaraEvent.class); AqaraEvent aqaraEvent = JSONObject.parseObject(requestBody, AqaraEvent.class);
if(Contants.MSG_TYPE_RESOURCE.equals(aqaraEvent.getMsgType())){ if(Contants.MSG_TYPE_RESOURCE.equals(aqaraEvent.getMsgType())){
...@@ -41,7 +42,7 @@ public class NoticeController { ...@@ -41,7 +42,7 @@ public class NoticeController {
} }
JSONObject jsonObject=new JSONObject(); JSONObject jsonObject=new JSONObject();
jsonObject.put("code",0); jsonObject.put("code",0);
jsonObject.put("result","glsxtest"); jsonObject.put("result",jsonObject1.getString("echostr"));
return jsonObject.toJSONString(); return jsonObject.toJSONString();
}catch (Exception e){ }catch (Exception e){
e.printStackTrace(); e.printStackTrace();
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!