[BugFix:   fix upgrade to 3.8.3 failed
@@ -11,7 +11,6 @@ import org.zstack.core.asyncbatch.While;
import org.zstack.core.cloudbus.CloudBus;
import org.zstack.core.cloudbus.CloudBusCallBack;
import org.zstack.core.cloudbus.MessageSafe;
-import org.zstack.core.cloudbus.ResourceDestinationMaker;
import org.zstack.core.componentloader.PluginRegistry;
import org.zstack.core.db.*;
import org.zstack.core.db.SimpleQuery.Op;
@@ -166,8 +165,6 @@ public class VirtualRouterManagerImpl extends AbstractService implements Virtual
private VipConfigProxy vipProxy;
@Autowired
protected VirutalRouterDefaultL3ConfigProxy defaultL3ConfigProxy;
- @Autowired
- private ResourceDestinationMaker destinationMaker;
@Override
@@ -620,16 +617,13 @@ public class VirtualRouterManagerImpl extends AbstractService implements Virtual
}
+ @Transactional
private void prepareDbInitialValueForPublicVip() {
/* vip upgrade for multiple public interface */
List<VipVO> vips = new ArrayList<>();
List<VirtualRouterVipVO> vvips = new ArrayList<>();
List<VirtualRouterVmVO> vrVos = Q.New(VirtualRouterVmVO.class).list();
for (VirtualRouterVmVO vr : vrVos) {
- if (!destinationMaker.isManagedByUs(vr.getUuid())) {
- continue;
- }
-
if (vr.getDefaultL3NetworkUuid() == null) {
SQL.New(VirtualRouterVmVO.class).eq(VirtualRouterVmVO_.uuid, vr.getUuid())
.set(VirtualRouterVmVO_.defaultL3NetworkUuid, vr.getPublicNetworkUuid()).update();
