private void insertOrUpdateNodeGroup(InlongClusterNodeEntity clusterNode, HeartbeatMsg heartbeat) {
        Set<String> groupSet = StringUtils.isBlank(heartbeat.getNodeGroup()) ? new HashSet<>()
                : Arrays.stream(heartbeat.getNodeGroup().split(InlongConstants.COMMA)).collect(Collectors.toSet());
        String extParams = null;
        switch (clusterNode.getType()) {
            case ClusterType.AGENT:
                AgentClusterNodeDTO agentClusterNodeDTO = new AgentClusterNodeDTO();
                if (StringUtils.isNotBlank(clusterNode.getExtParams())) {
                    agentClusterNodeDTO = AgentClusterNodeDTO.getFromJson(clusterNode.getExtParams());
                    agentClusterNodeDTO.setAgentGroup(Joiner.on(InlongConstants.COMMA).join(groupSet));
                }
                extParams = GSON.toJson(agentClusterNodeDTO);
                break;
            case ClusterType.DATAPROXY:
                DataProxyClusterNodeDTO dataProxyClusterNodeDTO = new DataProxyClusterNodeDTO();
                if (StringUtils.isNotBlank(clusterNode.getExtParams())) {
                    dataProxyClusterNodeDTO = DataProxyClusterNodeDTO.getFromJson(clusterNode.getExtParams());
                    dataProxyClusterNodeDTO.setReportSourceType(heartbeat.getReportSourceType());
                }
                extParams = GSON.toJson(dataProxyClusterNodeDTO);
                break;
        }
        clusterNode.setExtParams(extParams);
    }
Check whether the configuration information carried in the heartbeat has been updated

@param oldHB last heartbeat msg
@param newHB current heartbeat msg
@return
inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/heartbeat/HeartbeatManager.java