fuweng11 commented on code in PR #8540:
URL: https://github.com/apache/inlong/pull/8540#discussion_r1264920275
##########
inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/heartbeat/HeartbeatServiceImpl.java:
##########
@@ -220,6 +225,23 @@ public PageResult<StreamHeartbeatResponse>
listStreamHeartbeat(HeartbeatPageRequ
}
}
+ /**
+ * Update heartbeatMsg for agent , if groupMsg is empty, then logically
remove all stream source related.
+ * If type of stream_source is file, change status from heartbeat_timeout
+ *
+ * @param request
+ * @return
+ */
+ private Boolean updateAgentHeartbeatOpt(HeartbeatReportRequest request) {
+ // If heartbeatMsg not contain any group ,just delete
+ if (CollectionUtils.isEmpty(request.getGroupHeartbeats()) &&
StringUtils.isNotBlank(request.getIp())) {
+ String agentIp = request.getIp();
+ sourceMapper.logicalDeleteByAgentIp(agentIp,
SourceStatus.SOURCE_DISABLE.getCode(),
Review Comment:
```suggestion
sourceMapper.logicalDeleteByAgentIp(agentIp,
SourceStatus.HEARTBEAT_TIMEOUT.getCode(),
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]