@AfterEach
    public void teardownEach() {
        if (!groupStreamCache.isEmpty()) {
            groupStreamCache.forEach(groupStream -> sourceService.deleteAll(groupStream.getLeft(),
                    groupStream.getRight(), GLOBAL_OPERATOR));
            groupMapper.deleteByInlongGroupIds(
                    groupStreamCache.stream().map(Pair::getKey).collect(Collectors.toList()));
            streamMapper.deleteByInlongGroupIds(
                    groupStreamCache.stream().map(Pair::getValue).collect(Collectors.toList()));
        }
        groupStreamCache.clear();
        groupCache.stream().forEach(group -> bindGroup(false, group));;
    }
mock {@link InlongGroupProcessService#restartProcessAsync}, it will restart stream source
inlong-manager/manager-service/src/test/java/org/apache/inlong/manager/service/core/impl/AgentServiceTest.java