Commit 62e34938 authored by 周昊's avatar 周昊

1、修改日志输出

parent d375eca8
...@@ -50,12 +50,6 @@ public class StreamingJob { ...@@ -50,12 +50,6 @@ public class StreamingJob {
SingleOutputStreamOperator<AlgorithmPushDto> streamOperator = mqttStream SingleOutputStreamOperator<AlgorithmPushDto> streamOperator = mqttStream
.filter(new UpdateLiveFilterFunction(sceneId)); .filter(new UpdateLiveFilterFunction(sceneId));
//3、4 Object -> String
streamOperator = streamOperator.map(algorithmPushDto ->{
System.out.println(algorithmPushDto.toString());
return algorithmPushDto;
});
//3、1 默认 是否存在结果集判断 //3、1 默认 是否存在结果集判断
streamOperator = streamOperator streamOperator = streamOperator
.filter(new ResultExistFilterFunction()); .filter(new ResultExistFilterFunction());
......
...@@ -104,7 +104,6 @@ public class MqttConsumer extends RichParallelSourceFunction<AlgorithmPushDto> { ...@@ -104,7 +104,6 @@ public class MqttConsumer extends RichParallelSourceFunction<AlgorithmPushDto> {
public void messageArrived(String s, MqttMessage message) throws Exception { public void messageArrived(String s, MqttMessage message) throws Exception {
//订阅消息字符 //订阅消息字符
String msg = new String(message.getPayload()); String msg = new String(message.getPayload());
System.out.println(msg);
byte[] bymsg = getBytesFromObject(msg); byte[] bymsg = getBytesFromObject(msg);
AlgorithmPushDto algorithmPushDto = JSON.parseObject(msg, AlgorithmPushDto.class); AlgorithmPushDto algorithmPushDto = JSON.parseObject(msg, AlgorithmPushDto.class);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment