35 Commits

Author SHA1 Message Date
Rafael Weingärtner
3c6df7c970 CLOUDSTACK-10196: Remove ejb-api 3.0 dependency (#2348)
Fixed QuotaAlertManagerImplTest, which was injecting mock objects manually.
2017-12-18 23:59:06 +05:30
Jayapal
6e832b55dc Merge pull request #2109 from Accelerite/CLOUDSTACK-9922
CLOUDSTACK-9922 Unable to use 8081 port for Load balancing
2017-08-30 15:15:19 +05:30
SudharmaJain
7f987ace35 CLOUDSTACK-9165: unable to use reserved IP range in a network for external VMs (#1246) 2017-08-22 21:11:45 +02:00
SowjanyaPatha
f66bbb9521 CLOUDSTACK-9922 Unable to use 8081 port for Load balancing 2017-08-08 11:57:45 +05:30
Abhinandan Prateek
ca8a00442c CLOUDSTACK-9683: system.vm.default.hypervisor will pin the hypervisor for VR too with this fix 2016-12-19 13:06:02 +05:30
Wilder Rodrigues
0d075906ad CLOUDSTACK-4374 - Adds HA capabilities to redundant routers
- Redundant Routers are not the same as Haigh Available.
     Having a router HA is actually saying that the given router will be controlled by the High Availability monitor.
     Hence fix any problem we might face.
2015-12-11 07:51:22 +01:00
Boris Schrijver
80cb3adad0 Added isEmpty() check to prevent nullPointerException. 2015-09-23 15:07:16 +02:00
wilderrodrigues
5e9e9b84fb CLOUDSTACK-8814 - Refactoring the configuration of Routers and VPC routers nics 2015-09-08 15:34:29 +02:00
wilderrodrigues
53c9bb4d38 CLOUDSTACK-8759 - Fix guets nic allocation
- When stopping/detroying a VPC router and creating a new one via the addition os a VM, the networks are no plugged correctly
   - The ETH1 ends up with the IP of the guest nic, which remains down. This causes routes problems and the VMs are not reachable via the pub IPs
2015-09-03 09:38:56 +02:00
wilderrodrigues
23d0f3feda CLOUDSTACK-8759 - Adding a marvin test in order to cover the fix
- The test will create a VPC, add 2 tier, 2 VMs, ACL, PF and SSH into the VM
   - Then it will stop the router, destroy the router, add another VM to 1 tier and check that we can reach all the VMs
2015-09-02 17:05:16 +02:00
wilderrodrigues
21df0ffe89 CLOUDSTACK-8759 - The guest nic has to be added after the control nic
- The was an issue introduced on 4.5 with the VPC refactor.
   - Adding a VM to a VPC with no router would create a broken VPC router, with no nics
2015-09-01 14:31:49 +02:00
Boris Schrijver
c30ba1df0b Refactored Nic.java for readability.
Changed methodnames according to Nic.java refactor.

Fixed NicVO.java due to regression from Nic.java refactor.

Fixed VmWareGuru.java after Nic.java refactor.

See issue CLOUDSTACK-8736 for ongoing effort to clean up network code.
2015-08-18 14:04:48 +02:00
Boris Schrijver
5db3371840 Refactored NicProfile.java for readability.
See issue CLOUDSTACK-8736 for ongoing effort to clean up network code.
2015-08-17 14:12:10 +02:00
wilderrodrigues
3d22a16c4f Bump priority stragety is no longer used for redundant virtual routers
- With the changes added by the rVPC work, the bump priority became deprecated.
     This commit includes a refactor to get it removed from the following resources:
     * Java classes
     * domain_router table - removing the is_priority_bumpup column
     * Fixing unit tests

All changes were tested with:

XenServer 6.2 running under our VMWare zone
CloudStack Management Server running on MacBook Pro
MySql running on MackBook Pro
Storage Type: Local
2015-04-02 21:50:49 +02:00
wilderrodrigues
962a62ed5f During the merge I removed by mistake the @Inject tag 2015-03-16 11:40:07 +01:00
wilderrodrigues
be81d2ffa4 Fixing guest network interfaces on redundant routers
- The interfaces were messed up because part of the code was still taking inot account a non-redundant path.
2015-03-16 11:39:49 +01:00
wilderrodrigues
460204fa9f Fixing CsDhcp.py
Fixing assign IPv4 on GuestNetworkGuru.java
Fixing getRouters() on VpcVirtualRouterElement.java
Fixing Fixing paths on keepalived.conf.templ

Refactor on the other files
2015-03-16 11:39:17 +01:00
wilderrodrigues
40eb579115 TK-3135 fixes for VPC restart
* removed the "is redundant" flag form the addVpcRouterToGuestNetwork() method
* removed the "is redundant" flag from the removeVpcRouterFromGuestNetwork() method
* changed the path of the master.py file in the keepalived.conf.temp file
* the call to routerDao.addRouterToGuestNetwork() in the VpcRouterDeploymentDefinition is not needed. That step will be performed once a VM is created
  - In addition, when restarting a VPC the routers will have the guest net configured, if any exists.

* Pushing the POM.xml as well, to use the old Jetty for now. Could not fix the logging problem. Will replace the POM with master version after VPC is done.
2015-03-16 11:39:17 +01:00
wilderrodrigues
381c0e1c69 Fixing the priority in the setup guest network command
Fixing the deploy router in VPC method

formatting some classes
2015-03-16 11:39:16 +01:00
wilderrodrigues
cfbdbd421d Extracting local variable and formatting the code. 2015-03-16 11:39:15 +01:00
Antonio Fornie
09bd847040 Vpc redundancy enabled. Including Vpc & Vpc Offering creation. Marvin tests and UI. 2015-03-16 11:38:05 +01:00
Funs
c27c69438b hypervisors: add OVM3 plugin that supports OVM 3.2.1/3.3.x
This is a plugin that puts in ovm3 support ranging from 3.3.1 to 3.3.2. Basic
functionality is in here, advanced networking etc..

Snapshots only work when a VM is stopped now due to the semantics of OVM's raw
image implementation (so snapshots should work on a storage level underneath the
hypervisor shrug)

This closes #113

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-03-12 11:33:42 +05:30
Rohit Yadav
1a6df6f978 CLOUDSTACK-7908: Add user_id column to vm_instance table
Design Document:
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Allow+VM+listing+by+User+ID

- Adds column to VMInstance DAO
- Adds column in vm_instance table
- Adds column in the UserVMJoinVO
- Adds default admin user which has UID = 2
- Adds migration path that sets user_id to first user of the accountId that
  owns the vm in vm_instance table
- Add arg on list VMs API to query by userId, add support in query layer
- Refactor VMInstanceVO and child classes to accept userId
- Add code to let service layer pass userId if loggedIn user belongs to same
  account as the owner executing an API call or use first user from owner account
- In case of CPVM and SSVM use system user ID
- Fix unit tests and spring injections

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-16 15:02:38 +05:30
Daan Hoogland
b586439c9f CLOUDSTACK-8197 create MinVRVersion config item 2015-02-03 13:18:15 +01:00
Kishan Kavala
4e896938ee BUG-ID: CLOUDSTACK-5324 when router requires upgrade throw ResourceUnavailableException with scope VirtualRouter. API willl return generic Network Unavailable error.
Reviewed-By: Damoder
2014-11-19 09:46:56 +05:30
Wilder Rodrigues
c81b3380df Applying the latest chances from the VPC Refactor branch onto the new one.
We will keep this branch as clean as possible to avoid problems with merge.
2014-10-14 15:08:13 +02:00
wrodrigues
3ac2e222e8 CLOUDSTACK-6278 Baremetal Advanced Networking support from commit id e06fa18ed2ee2ee6a417e089cf5ac6bde11d0079 by Frank Zhang
Conflicts:
	server/src/com/cloud/network/router/NetworkHelperImpl.java
2014-10-14 15:08:13 +02:00
wrodrigues
4e21948f5c Fixing the NetworkHelperImpl class. It was throwing a NPE due to a hypervisor type SIMULATOR not being in the hashmap.
When the refactor took place, we should have changed first structure, then behaviour. By refactoring the deployRouter method
we changed how the templateName was retrieved.
Fixed and tested using the simulator and the following Marvin tests

test_privategateway_acl
test_routers
test_vpc_vpn
test_service_offerings
test_volumes
test_reset_vm_on_reboot
test_multipleips_per_nic

Conflicts:
	server/src/com/cloud/network/router/NetworkHelperImpl.java
2014-10-14 15:08:12 +02:00
Wilder Rodrigues
f2f4732854 Removing the VirtualNetworkStatus, it was not being used properly;
fixing the injection of the network DAO in the PrivateGatewayRules;
all tests that were failing in Travis have been tested before the commit.

Conflicts:
	server/src/com/cloud/network/router/NetworkHelperImpl.java
	server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java
2014-10-14 15:08:11 +02:00
Wilder Rodrigues
dc5fefc018 making sure the instance variable _router in the Rules is being used instead of the parameter
Conflicts:
	server/src/com/cloud/network/router/NetworkHelperImpl.java
2014-10-14 15:08:11 +02:00
Antonio Fornie
cd8cadaf9c Refactor hypervisor retrieval from VpcNwHelper and NwHelper
Conflicts:
	server/src/com/cloud/network/router/NetworkHelperImpl.java
	server/src/org/cloud/network/router/deployment/RouterDeploymentDefinition.java
	server/src/org/cloud/network/router/deployment/VpcRouterDeploymentDefinition.java
	server/test/org/cloud/network/router/deployment/VpcRouterDeploymentDefinitionTest.java
2014-10-14 15:08:09 +02:00
Antonio Fornie
2802d3b75b Refactor and test NetworkHelper#sendCommandsToRouterWithNoAnswers 2014-10-14 15:02:14 +02:00
Antonio Fornie
3d4ddb7251 DeployRouter includes nw creation following TellDontAsk principle
Also factor out NicProfile specific methods and fix some DI config.

Conflicts:
	server/src/org/cloud/network/router/deployment/VpcRouterDeploymentDefinition.java
	server/test/org/cloud/network/router/deployment/VpcRouterDeploymentDefinitionTest.java
2014-10-14 15:02:13 +02:00
Wilder Rodrigues
b96035f356 adding applyStaticRoutes method to the network topology/visitor. it will be used by the VPC virtual net manager appliance.
Conflicts:
	server/src/com/cloud/network/rules/VirtualNetworkApplianceFactory.java
2014-10-14 15:02:12 +02:00
Antonio Fornie
2da3ceda31 Refactor to include network creation as actual deployment
Conflicts:
	server/src/org/cloud/network/router/deployment/RouterDeploymentDefinition.java
	server/src/org/cloud/network/router/deployment/RouterDeploymentDefinitionBuilder.java
	server/src/org/cloud/network/router/deployment/VpcRouterDeploymentDefinition.java
	server/test/org/cloud/network/router/deployment/VpcRouterDeploymentDefinitionTest.java
2014-10-14 15:02:12 +02:00