103 Commits

Author SHA1 Message Date
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
Laszlo Hornyak
3577423da9 removed executable flags from java classes
Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>
2014-11-23 19:49:01 +01:00
Will Stevens
92d4a41a69 CLOUDSTACK-7822: Fixed SSL Cert Tests and relaxed chain validation 2014-11-13 09:55:49 -05:00
pdion891
f28ade56f2 Revert "CLOUDSTACK-7822: updated ssl cert(exp:2096), reactivate tests"
This reverts commit 0d1fa9102d7a87863a9f91f88af05e9f38fe6b91.
2014-10-31 17:12:54 -04:00
pdion891
0d1fa9102d CLOUDSTACK-7822: updated ssl cert(exp:2096), reactivate tests 2014-10-31 16:42:31 -04:00
Frank Zhang
ccf4c66ef1 fix expried certificate in unit test 2014-10-21 16:20:54 -07:00
Wilder Rodrigues
db86bdfb2c Applygin fix from commit ID aaeadc5c44e3fe16a1deea5348b085b08b5f4f4d
Sheng Yang changed 2 classes, ut only one was related to the bug CLOUDSTACK-7605.
I applied the changed on the routerslist, used during the deployment of the virtual routers.

Tested Advanced Zone against the simulator. 69 happy tests in place
2014-10-14 15:08:13 +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
b9bff843c6 Whole router.deployment package got 97% coverage
Conflicts:
	server/src/org/cloud/network/router/deployment/RouterDeploymentDefinitionBuilder.java
	server/test/org/cloud/network/router/deployment/VpcRouterDeploymentDefinitionTest.java
2014-10-14 15:02:13 +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
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
Antonio Fornie
0d81cf09f6 Increasing test coverage for Vpc Deployment 2014-10-14 15:01:16 +02:00
Antonio Fornie
240a539d43 Factor out prepareDeployment and update tests 2014-10-14 15:01:16 +02:00
Antonio Fornie
d2d9157ab0 Complete tests for normal deployment and start vpc one
Conflicts:
	server/src/org/cloud/network/router/deployment/RouterDeploymentDefinitionBuilder.java
2014-10-14 15:01:16 +02:00
Antonio Fornie
a83f5790eb License headers 2014-10-14 15:01:15 +02:00
Antonio Fornie
6fac12675d More refactoring and testing in the same classes
Conflicts:
	server/src/org/cloud/network/router/deployment/RouterDeploymentDefinitionBuilder.java
2014-10-14 15:01:15 +02:00
Antonio Fornie
f3c04172a4 RouterDeployment and VPC. Improving code and Unit Testing 2014-10-14 15:01:14 +02:00
Will Stevens
5d11385c31 CLOUDSTACK-7468: Fixed the NetScaler SSL Termination behavior with Projects
Signed-off-by: Will Stevens <wstevens@cloudops.com>
2014-09-03 10:07:19 -04:00
Murali Reddy
9dc322d46f CLOUDSTACK-7144: No GSLB provider is available during assigning load
balancing rule

this fix ensures any bean implementing GslbProvider interface are injected
into GlobalLoadBalancingRulesServiceImpl.
2014-07-21 16:50:21 +05:30
Hugo Trippaers
cd0ef09344 Fix typo and add the right exception to the error map. 2014-06-25 15:51:28 +02:00
Saksham Srivastava
f2464e4182 CLOUDSTACK-6864: UploadSSlCert API requires double encoding of URL params 2014-06-12 10:35:47 +05:30
Alena Prokharchyk
ac1b4b0316 Fixed unittest 2014-06-05 18:37:56 -07:00
Nitin Mehta
5393387bbd CLOUDSTACK-6599:
1. Adding the missing Template/Volume URLs expiration functionality
2. Improvement - While deleting the volume during expiration use rm -rf as vmware now contains directoy
3. Improvement - Use standard Answer so that the error gets logged in case deletion of expiration link didnt work fine.
4. Improvement - In case of domain change, expire the old urls
2014-05-30 10:48:42 -07:00
root
4b89a45e57 CLOUDSTACK-3272 Latest changes to add global configuration parameters to control the publishing of events on the message bus 2014-05-07 10:09:03 +05:30
Nitin Mehta
dd55095fd5 CLOUDSTACK-6530: Populate the first class entities in the context to be available for publishing more information for the event bus, checking the displayable property etc.
(cherry picked from commit 3e7ea4e8d99a92872007f11a09ab87c8ba61e1da)
2014-04-28 18:21:48 -07:00
Marcus Sorensen
11f5bdd78d CLOUDSTACK-6191 Add support for specifying volume provisioning
type (thin, sparse, fat) in disk/compute offerings.

Submitted-by: Yoshikazu Nojima <mail@ynojima.net>
Reviewed-by: Marcus Sorensen, Mike Tutowski
2014-04-10 09:23:04 -06:00
Min Chen
48e08fe676 Merge branch 'master' into rbac. 2014-03-06 14:02:20 -08:00
Alena Prokharchyk
0f489732c8 Display flag support for LB/InternalLB/NetworkACL rules 2014-02-21 14:03:10 -08:00
Min Chen
3b58a45e04 Merge branch 'master' into rbac. 2014-02-07 13:43:36 -08:00
Alex Huang
7f34282dfa Removed references to secondarystoragevmmanager from code that doesn't use it. 2014-02-05 01:39:15 +00:00
Prachi Damle
9e92197dfd Fixing Build after merge 2014-02-04 15:10:24 -08:00
David Grizzanti
5de9ae0bce CLOUDSTACK-5496 : Account included in ActionEvents is Project Account ID
When Action Events are generated and placed on the Event Bus, an
"account" parameter is included with the event. When these events are
generated for resources within projects, this "account" parameter is not
useful as it's the UUID of the project account, instead of the project.

To solve this, I updated ActionEventsUtil class to include a "project"
parameter in the generated events when the resource is being
changed/add/deleted in a project.
2014-01-30 17:35:01 +05:30
Alex Huang
be5e5cc641 All Checkstyle problems corrected 2013-12-12 12:26:07 -08:00
Alex Huang
d620df2bdd Reformatted all of the code. 2013-11-21 06:15:26 -08:00
Alex Huang
eaa250fd3c Formatted again after all the tab expansions and eol removals 2013-11-21 04:47:01 -08:00
Alex Huang
62e9273581 Removed trailing spaces 2013-11-21 03:12:05 -08:00
Alex Huang
8d62744681 Reformat all source code. Added checkstyle to check the source code 2013-11-20 07:26:53 -08:00
Harikrishna Patnala
c29cd9d3c7 CLOUDSTACK-4835: Update global configuration test cases failed in master Changes made in update/list configuration API to use ConfigDepot
CLOUDSTACK-4169: Scoped configuraion parameters logic moved to ConfigDepot

CLOUDSTACK-5163: missing parameters in configuration table
2013-11-15 12:19:31 +05:30
Laszlo Hornyak
f091b6ae1d Add assumtion on OpenJDK for tests that build on JCE
This patch adds an assumption that OpenJDK is used in some of the tests.
OpenJDK detection utility also added. By specifying -Dcloudstack.jce.enabled=true in the test parameters the OpenJDK detection can be overridden.

Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>
2013-11-12 22:06:12 +01:00
Laszlo Hornyak
bd67ccdd6d few cleanups in CertServiceTest and CertService
Tests:
- all tests are @Test rather than having one test to call them, so they can be run one by one
- tests that expect exception from a method fail if there is none
- no longer extends TestCase so that the original method names could be kept as test

Implementation:
- include root cause in exceptions when possible - helps at troubleshuting
- close readers

Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>
2013-11-12 08:13:59 +01:00
Syed
0076307863 Squashed merge of Ssl Termination feature
Bug: https://issues.apache.org/jira/browse/CLOUDSTACK-4821
FS: https://cwiki.apache.org/confluence/display/CLOUDSTACK/SSL+Termination+Support

This patch implements the SSL offload feature for loadbalancers
and includes the implementaion for this to work with Netscaler.

The following are the new API's that this patch adds

uploadSslCert
deleteSslCert
listSslCert
assignCertToLoadBalancer
removeCertFromLoadBalancer

Unit tests are also included in the patch.
2013-11-08 16:49:16 +05:30
Prachi Damle
cb6d8d0190 CLOUDSTACK-5045 [Automation][BVT] Affinity group type is missing "create affinity group page" and failed to create Affinity group
Changes:
- Changes to Unit tests needed after this fix.
2013-11-07 21:40:39 -08:00
Bharat Kumar
7095ea2b5e CLOUDSTACK-4738 Dynamic compute offering.
Signed-off-by: Koushik Das <koushik@apache.org>
2013-11-07 12:41:20 +05:30
Alena Prokharchyk
24725f8e21 ResourceDetails:
1) Added support for Zone resource details
2) Renamed DcDetailsDao to DataCenterDetailsDao to follow the CS name convention for DataCenter related classes
2013-10-24 15:54:49 -07:00
Darren Shepherd
81d01369d7 Merge commit 'df728fcf41ba0dfddabfaadea8cbcb77d18bfa96'
Conflicts:
	engine/orchestration/src/com/cloud/vm/VirtualMachineManagerImpl.java
2013-10-23 12:31:53 -07:00
Laszlo Hornyak
4b530c874f Safe properties loader
- new utility method introduced in PropertiesUtil to load properties objects from files
- RegionManagerImpl modified to use the utility method
- Tests added for both

Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>
2013-10-23 20:50:00 +02:00
Darren Shepherd
205a77a5bb Merge remote-tracking branch 'origin/txn-refactor'
Conflicts:
	engine/orchestration/src/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java
	server/src/com/cloud/configuration/ConfigurationManagerImpl.java
	server/src/com/cloud/metadata/ResourceMetaDataManagerImpl.java
	server/src/com/cloud/vm/UserVmManagerImpl.java
2013-10-23 10:40:44 -07:00
dhoogland
c0c46268ac CLOUDSTACK-4328 httpclose/mode as keepAliveEnabled 2013-10-22 12:44:23 +02:00
Darren Shepherd
f62e28c1ec New Transaction API
Introduction of a new Transaction API that is more consistent with the style
of Spring's transaction managment.  The existing Transaction class was renamed
to TransactionLegacy.  All of the non-DAO code in the management server has been
updated to use the new Transaction API.
2013-10-16 09:21:00 -07:00
Alex Huang
1f5699b29f Fixed unit tests 2013-09-06 15:40:39 -07:00