From a51b41110104ff43bbd716fddd3e44368256beef Mon Sep 17 00:00:00 2001
From: jiang <893224616@qq.com>
Date: 星期二, 19 七月 2022 18:13:42 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/wvp-28181-2.0' into wvp-28181-2.0

---
 src/main/java/com/genersoft/iot/vmp/service/impl/StreamPushServiceImpl.java |   48 ------------------------------------------------
 1 files changed, 0 insertions(+), 48 deletions(-)

diff --git a/src/main/java/com/genersoft/iot/vmp/service/impl/StreamPushServiceImpl.java b/src/main/java/com/genersoft/iot/vmp/service/impl/StreamPushServiceImpl.java
index faac5c9..62cf20f 100644
--- a/src/main/java/com/genersoft/iot/vmp/service/impl/StreamPushServiceImpl.java
+++ b/src/main/java/com/genersoft/iot/vmp/service/impl/StreamPushServiceImpl.java
@@ -134,29 +134,6 @@
         stream.setStatus(true);
         stream.setCreateTime(DateUtil.getNow());
         int add = gbStreamMapper.add(stream);
-
-        // 鏌ユ壘寮�鍚簡鍏ㄩ儴鐩存挱娴佸叡浜殑涓婄骇骞冲彴
-        List<ParentPlatform> parentPlatforms = parentPlatformMapper.selectAllAhareAllLiveStream();
-        if (parentPlatforms.size() > 0) {
-            for (ParentPlatform parentPlatform : parentPlatforms) {
-                stream.setCatalogId(parentPlatform.getCatalogId());
-                stream.setPlatformId(parentPlatform.getServerGBId());
-                String streamId = stream.getStream();
-                StreamProxyItem streamProxyItem = platformGbStreamMapper.selectOne(stream.getApp(), streamId, parentPlatform.getServerGBId());
-                if (streamProxyItem == null) {
-                    platformGbStreamMapper.add(stream);
-                    eventPublisher.catalogEventPublishForStream(parentPlatform.getServerGBId(), stream, CatalogEvent.ADD);
-                }else {
-                    if (!streamProxyItem.getGbId().equals(stream.getGbId())) {
-                        // 姝ゆ祦浣跨敤鍙︿竴涓浗鏍嘔d宸茬粡涓庤骞冲彴鍏宠仈锛岀Щ闄ゆ璁板綍
-                        platformGbStreamMapper.delByAppAndStreamAndPlatform(stream.getApp(), streamId, parentPlatform.getServerGBId());
-                        platformGbStreamMapper.add(stream);
-                        eventPublisher.catalogEventPublishForStream(parentPlatform.getServerGBId(), stream, CatalogEvent.ADD);
-                    }
-                }
-            }
-        }
-
         return add > 0;
     }
 
@@ -345,31 +322,6 @@
     public void batchAdd(List<StreamPushItem> streamPushItems) {
         streamPushMapper.addAll(streamPushItems);
         gbStreamMapper.batchAdd(streamPushItems);
-        // 鏌ユ壘寮�鍚簡鍏ㄩ儴鐩存挱娴佸叡浜殑涓婄骇骞冲彴
-        List<ParentPlatform> parentPlatforms = parentPlatformMapper.selectAllAhareAllLiveStream();
-        if (parentPlatforms.size() > 0) {
-            for (StreamPushItem stream : streamPushItems) {
-                for (ParentPlatform parentPlatform : parentPlatforms) {
-                    stream.setCatalogId(parentPlatform.getCatalogId());
-                    stream.setPlatformId(parentPlatform.getServerGBId());
-                    String streamId = stream.getStream();
-                    StreamProxyItem streamProxyItem = platformGbStreamMapper.selectOne(stream.getApp(), streamId, parentPlatform.getServerGBId());
-                    if (streamProxyItem == null) {
-                        platformGbStreamMapper.add(stream);
-                        eventPublisher.catalogEventPublishForStream(parentPlatform.getServerGBId(), stream, CatalogEvent.ADD);
-                    }else {
-                        if (!streamProxyItem.getGbId().equals(stream.getGbId())) {
-                            // 姝ゆ祦浣跨敤鍙︿竴涓浗鏍嘔d宸茬粡涓庤骞冲彴鍏宠仈锛岀Щ闄ゆ璁板綍
-                            platformGbStreamMapper.delByAppAndStreamAndPlatform(stream.getApp(), streamId, parentPlatform.getServerGBId());
-                            platformGbStreamMapper.add(stream);
-                            eventPublisher.catalogEventPublishForStream(parentPlatform.getServerGBId(), stream, CatalogEvent.ADD);
-                            stream.setGbId(streamProxyItem.getGbId());
-                            eventPublisher.catalogEventPublishForStream(parentPlatform.getServerGBId(), stream, CatalogEvent.DEL);
-                        }
-                    }
-                }
-            }
-        }
     }
 
     @Override

--
Gitblit v1.8.0