mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-02 20:02:29 +01:00
package rename
Conflicts: server/src/com/cloud/network/rules/DhcpEntryRules.java server/src/com/cloud/network/rules/DhcpSubNetRules.java
This commit is contained in:
parent
563f853d59
commit
e1866bf90d
@ -192,10 +192,10 @@
|
||||
<bean id="virtualNetworkApplianceFactory"
|
||||
class="com.cloud.network.rules.VirtualNetworkApplianceFactory" />
|
||||
|
||||
<bean id="topologyContext" class="com.cloud.network.topology.NetworkTopologyContext" init-method="init" />
|
||||
<bean id="topologyContext" class="org.apache.cloudstack.network.topology.NetworkTopologyContext" init-method="init" />
|
||||
|
||||
<bean id="basicNetworkTopology" class="com.cloud.network.topology.BasicNetworkTopology" />
|
||||
<bean id="advancedNetworkTopology" class="com.cloud.network.topology.AdvancedNetworkTopology" />
|
||||
<bean id="basicNetworkTopology" class="org.apache.cloudstack.network.topology.BasicNetworkTopology" />
|
||||
<bean id="advancedNetworkTopology" class="org.apache.cloudstack.network.topology.AdvancedNetworkTopology" />
|
||||
|
||||
<bean id="routerControlHelper"
|
||||
class="com.cloud.network.router.RouterControlHelper" />
|
||||
|
||||
@ -31,6 +31,8 @@ import org.apache.cloudstack.api.command.admin.router.CreateVirtualRouterElement
|
||||
import org.apache.cloudstack.api.command.admin.router.ListOvsElementsCmd;
|
||||
import org.apache.cloudstack.api.command.admin.router.ListVirtualRouterElementsCmd;
|
||||
import org.apache.cloudstack.framework.config.dao.ConfigurationDao;
|
||||
import org.apache.cloudstack.network.topology.NetworkTopology;
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyContext;
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
import com.cloud.agent.api.to.LoadBalancerTO;
|
||||
@ -81,8 +83,6 @@ import com.cloud.network.rules.LoadBalancerContainer;
|
||||
import com.cloud.network.rules.PortForwardingRule;
|
||||
import com.cloud.network.rules.RulesManager;
|
||||
import com.cloud.network.rules.StaticNat;
|
||||
import com.cloud.network.topology.NetworkTopology;
|
||||
import com.cloud.network.topology.NetworkTopologyContext;
|
||||
import com.cloud.offering.NetworkOffering;
|
||||
import com.cloud.offerings.NetworkOfferingVO;
|
||||
import com.cloud.offerings.dao.NetworkOfferingDao;
|
||||
|
||||
61
server/src/com/cloud/network/rules/DhcpEntryRules.java
Normal file
61
server/src/com/cloud/network/rules/DhcpEntryRules.java
Normal file
@ -0,0 +1,61 @@
|
||||
// Licensed to the Apache Software Foundation (ASF) under one
|
||||
// or more contributor license agreements. See the NOTICE file
|
||||
// distributed with this work for additional information
|
||||
// regarding copyright ownership. The ASF licenses this file
|
||||
// to you under the Apache License, Version 2.0 (the
|
||||
// "License"); you may not use this file except in compliance
|
||||
// with the License. You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing,
|
||||
// software distributed under the License is distributed on an
|
||||
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
// KIND, either express or implied. See the License for the
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.deploy.DeployDestination;
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.VirtualMachineProfile;
|
||||
|
||||
public class DhcpEntryRules extends RuleApplier {
|
||||
|
||||
private final NicProfile nic;
|
||||
private final VirtualMachineProfile profile;
|
||||
private final DeployDestination destination;
|
||||
|
||||
public DhcpEntryRules(final Network network, final NicProfile nic, final VirtualMachineProfile profile, final DeployDestination destination) {
|
||||
super(network);
|
||||
|
||||
this.nic = nic;
|
||||
this.profile = profile;
|
||||
this.destination = destination;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean accept(final NetworkTopologyVisitor visitor, final VirtualRouter router) throws ResourceUnavailableException {
|
||||
this.router = router;
|
||||
|
||||
return visitor.visit(this);
|
||||
}
|
||||
|
||||
public NicProfile getNic() {
|
||||
return nic;
|
||||
}
|
||||
|
||||
public VirtualMachineProfile getProfile() {
|
||||
return profile;
|
||||
}
|
||||
|
||||
public DeployDestination getDestination() {
|
||||
return destination;
|
||||
}
|
||||
}
|
||||
@ -17,11 +17,12 @@
|
||||
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.deploy.DeployDestination;
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.VirtualMachineProfile;
|
||||
|
||||
|
||||
61
server/src/com/cloud/network/rules/DhcpSubNetRules.java
Normal file
61
server/src/com/cloud/network/rules/DhcpSubNetRules.java
Normal file
@ -0,0 +1,61 @@
|
||||
// Licensed to the Apache Software Foundation (ASF) under one
|
||||
// or more contributor license agreements. See the NOTICE file
|
||||
// distributed with this work for additional information
|
||||
// regarding copyright ownership. The ASF licenses this file
|
||||
// to you under the Apache License, Version 2.0 (the
|
||||
// "License"); you may not use this file except in compliance
|
||||
// with the License. You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing,
|
||||
// software distributed under the License is distributed on an
|
||||
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
// KIND, either express or implied. See the License for the
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.deploy.DeployDestination;
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.VirtualMachineProfile;
|
||||
|
||||
public class DhcpSubNetRules extends RuleApplier {
|
||||
|
||||
private final NicProfile nic;
|
||||
private final VirtualMachineProfile profile;
|
||||
private final DeployDestination destination;
|
||||
|
||||
public DhcpSubNetRules(final Network network, final NicProfile nic, final VirtualMachineProfile profile, final DeployDestination destination) {
|
||||
super(network);
|
||||
|
||||
this.nic = nic;
|
||||
this.profile = profile;
|
||||
this.destination = destination;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean accept(final NetworkTopologyVisitor visitor, final VirtualRouter router) throws ResourceUnavailableException {
|
||||
this.router = router;
|
||||
|
||||
return visitor.visit(this);
|
||||
}
|
||||
|
||||
public NicProfile getNic() {
|
||||
return nic;
|
||||
}
|
||||
|
||||
public VirtualMachineProfile getProfile() {
|
||||
return profile;
|
||||
}
|
||||
|
||||
public DeployDestination getDestination() {
|
||||
return destination;
|
||||
}
|
||||
}
|
||||
@ -20,6 +20,8 @@ package com.cloud.network.rules;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.agent.api.routing.LoadBalancerConfigCommand;
|
||||
import com.cloud.agent.api.routing.NetworkElementCommand;
|
||||
import com.cloud.agent.api.routing.SetFirewallRulesCommand;
|
||||
@ -46,7 +48,6 @@ import com.cloud.network.lb.LoadBalancingRule.LbStickinessPolicy;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.rules.FirewallRule.Purpose;
|
||||
import com.cloud.network.rules.LoadBalancerContainer.Scheme;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.offering.NetworkOffering;
|
||||
import com.cloud.offerings.NetworkOfferingVO;
|
||||
import com.cloud.utils.net.Ip;
|
||||
|
||||
@ -24,6 +24,8 @@ import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.agent.api.Command;
|
||||
import com.cloud.agent.api.routing.IpAssocCommand;
|
||||
import com.cloud.agent.api.routing.NetworkElementCommand;
|
||||
@ -37,7 +39,6 @@ import com.cloud.network.Networks.TrafficType;
|
||||
import com.cloud.network.PublicIpAddress;
|
||||
import com.cloud.network.dao.NetworkVO;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.utils.net.NetUtils;
|
||||
import com.cloud.vm.NicVO;
|
||||
|
||||
|
||||
@ -19,6 +19,8 @@ package com.cloud.network.rules;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.agent.api.routing.LoadBalancerConfigCommand;
|
||||
import com.cloud.agent.api.routing.NetworkElementCommand;
|
||||
import com.cloud.agent.api.to.LoadBalancerTO;
|
||||
@ -35,7 +37,6 @@ import com.cloud.network.lb.LoadBalancingRule.LbSslCert;
|
||||
import com.cloud.network.lb.LoadBalancingRule.LbStickinessPolicy;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.rules.LoadBalancerContainer.Scheme;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.offering.NetworkOffering;
|
||||
import com.cloud.utils.net.Ip;
|
||||
import com.cloud.vm.DomainRouterVO;
|
||||
|
||||
@ -19,10 +19,11 @@ package com.cloud.network.rules;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.network.vpc.NetworkACLItem;
|
||||
|
||||
public class NetworkAclsRules extends RuleApplier {
|
||||
|
||||
@ -17,10 +17,11 @@
|
||||
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.VirtualMachineProfile;
|
||||
|
||||
|
||||
@ -19,10 +19,11 @@ package com.cloud.network.rules;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.network.vpc.NetworkACLItem;
|
||||
|
||||
public class PrivateGatewayRules extends RuleApplier {
|
||||
|
||||
@ -18,6 +18,7 @@
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.framework.config.dao.ConfigurationDao;
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.dc.dao.DataCenterDao;
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
@ -30,7 +31,6 @@ import com.cloud.network.lb.LoadBalancingRulesManager;
|
||||
import com.cloud.network.router.NEWVirtualNetworkApplianceManager;
|
||||
import com.cloud.network.router.RouterControlHelper;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.offerings.dao.NetworkOfferingDao;
|
||||
import com.cloud.vm.VirtualMachineManager;
|
||||
import com.cloud.vm.dao.DomainRouterDao;
|
||||
|
||||
@ -17,10 +17,11 @@
|
||||
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.VirtualMachineProfile;
|
||||
|
||||
|
||||
@ -20,6 +20,8 @@ package com.cloud.network.rules;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.agent.api.routing.NetworkElementCommand;
|
||||
import com.cloud.agent.api.routing.SetStaticNatRulesCommand;
|
||||
import com.cloud.agent.api.to.StaticNatRuleTO;
|
||||
@ -29,7 +31,6 @@ import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.IpAddress;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
public class StaticNatRules extends RuleApplier {
|
||||
|
||||
|
||||
@ -17,11 +17,12 @@
|
||||
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.deploy.DeployDestination;
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.VirtualMachineProfile;
|
||||
|
||||
|
||||
@ -17,12 +17,13 @@
|
||||
|
||||
package com.cloud.network.rules;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.agent.api.Command;
|
||||
import com.cloud.agent.manager.Commands;
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.VirtualMachineProfile;
|
||||
|
||||
|
||||
@ -19,11 +19,12 @@ package com.cloud.network.rules;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.PublicIpAddress;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
public class VpcIpAssociationRules extends RuleApplier {
|
||||
|
||||
|
||||
@ -20,6 +20,8 @@ package com.cloud.network.rules;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.cloudstack.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
import com.cloud.agent.api.routing.NetworkElementCommand;
|
||||
import com.cloud.agent.api.routing.VpnUsersCfgCommand;
|
||||
import com.cloud.agent.manager.Commands;
|
||||
@ -28,7 +30,6 @@ import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
import com.cloud.network.VpnUser;
|
||||
import com.cloud.network.router.VirtualRouter;
|
||||
import com.cloud.network.topology.NetworkTopologyVisitor;
|
||||
|
||||
public class VpnRules extends RuleApplier {
|
||||
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.topology;
|
||||
package org.apache.cloudstack.network.topology;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@ -15,7 +15,7 @@
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.topology;
|
||||
package org.apache.cloudstack.network.topology;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.topology;
|
||||
package org.apache.cloudstack.network.topology;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@ -15,7 +15,7 @@
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.topology;
|
||||
package org.apache.cloudstack.network.topology;
|
||||
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.Network;
|
||||
@ -15,7 +15,7 @@
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.topology;
|
||||
package org.apache.cloudstack.network.topology;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@ -15,7 +15,7 @@
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.topology;
|
||||
package org.apache.cloudstack.network.topology;
|
||||
|
||||
import java.util.Hashtable;
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
// specific language governing permissions and limitations
|
||||
// under the License.
|
||||
|
||||
package com.cloud.network.topology;
|
||||
package org.apache.cloudstack.network.topology;
|
||||
|
||||
import com.cloud.exception.ResourceUnavailableException;
|
||||
import com.cloud.network.rules.DhcpRules;
|
||||
Loading…
x
Reference in New Issue
Block a user