3393 Commits

Author SHA1 Message Date
Will Stevens
8c3722d953 Merge pull request #1444 from rafaelweingartner/workAroundPR780
CLOUDSTACK-8800 : Improved the listVirtualMachines API call to include memory utilization information for a VMThis PR introduces the changes proposed in PR #780 with some work to make the code null safe.

During this PR, I have also removed some unused code.

* pr/1444:
  Removed unnecessary check when creating the “userVmResponse” object.
  Fixed issues from CLOUDSTACK-8800 that were introduced in PR 780
  CLOUDSTACK-8800 : Improved the listVirtualMachines API call to include memory utilization information for a VM for xenserver,kvm and for vmware.

Signed-off-by: Will Stevens <williamstevens@gmail.com>
2016-05-12 16:49:14 -04:00
Will Stevens
20cf8b23c0 Merge pull request #1453 from GabrielBrascher/brascher-removeUnusedClasses2
Remove classes with no referencesI used UCDetector (http://www.ucdetector.org/) as a plugin for Eclipse.  With this tool, I discovered a lot of code without any reference (variables, methods and classes).

Following the work that was done at [https://github.com/apache/cloudstack/pull/1448]; this pull request had the goal of removing some of these classes. To check if I wasn't missing anything I searched for any file that could reference some of those classes. As I haven't found any way of these classes being used, they were removed. Note that some of them I found other references, but references such as commented lines or tests, nothing that could indicate their use (as XML files configuring beans or another class instantiating an object with "new").

Waiting for tests. Please tell me if I am missing something.

Removed Classes:
- org.apache.cloudstack.framework.jobs.JobCancellationException (**Note:** removed
variable JobCancellationException in com.cloud.utils.SerialVersionUID)
- org.apache.cloudstack.ldap.NoSuchLdapUserException (**Note:** removed test file
/cloud-plugin-user-authenticator-ldap/test/groovy/org/apache/cloudstack/ldap/NoSuchLdapUserExceptionSpec.groovy)
- com.cloud.agent.api.storage.CreateVolumeOVAAnswer
- com.cloud.exception.MissingParameterValueException
- org.apache.cloudstack.api.response.StatusResponse
- org.apache.cloudstack.api.response.VolumeDetailResponse
- org.apache.cloudstack.api.response.UpgradeVmResponse
- org.apache.cloudstack.api.response.AddIpToVmNicResponse
- org.apache.cloudstack.api.response.TemplateZoneResponse (**Note:** at
org.apache.cloudstack.api.response.TemplateResponse, there is this
comment "To avoid breaking backwards compatibility, we still treat a
template at different zones as different templates, so not embedding
template_zone information in this TemplateZoneResponse set. `private
Set<TemplateZoneResponse> zones;`" but right now it is not used)
- org.apache.cloudstack.api.response.NicDetailResponse

* pr/1453:
  Removed classes with no reference

Signed-off-by: Will Stevens <williamstevens@gmail.com>
2016-05-12 16:48:03 -04:00
Rohit Yadav
07564469e9 CLOUDSTACK-9299: Out-of-band Management for CloudStack
Support access to a host’s out-of-band management interface (e.g. IPMI, iLO,
DRAC, etc.) to manage host power operations (on/off etc.) and querying current
power state in CloudStack.

Given the wide range of out-of-band management interfaces such as iLO and iDRA,
the service implementation allows for development of separate drivers as plugins.
This feature comes with a ipmitool based driver that uses the
ipmitool (http://linux.die.net/man/1/ipmitool) to communicate with any
out-of-band management interface that support IPMI 2.0.

This feature allows following common use-cases:
- Restarting stalled/failed hosts
- Powering off under-utilised hosts
- Powering on hosts for provisioning or to increase capacity
- Allowing system administrators to see the current power state of the host

For testing this feature `ipmisim` can be used:
https://pypi.python.org/pypi/ipmisim

FS:
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Out-of-band+Management+for+CloudStack

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2016-05-12 11:05:40 +05:30
Rohit Yadav
4347776ac6 CLOUDSTACK-8562: DB-Backed Dynamic Role Based API Access Checker
This feature allows root administrators to define new roles and associate API
permissions to them.

A limited form of role-based access control for the CloudStack management server
API is provided through a properties file, commands.properties, embedded in the
WAR distribution. Therefore, customizing API permissions requires unpacking the
distribution and modifying this file consistently on all servers. The old system
also does not permit the specification of additional roles.

FS:
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Dynamic+Role+Based+API+Access+Checker+for+CloudStack

DB-Backed Dynamic Role Based API Access Checker for CloudStack brings following
changes, features and use-cases:
- Moves the API access definitions from commands.properties to the mgmt server DB
- Allows defining custom roles (such as a read-only ROOT admin) beyond the
  current set of four (4) roles
- All roles will resolve to one of the four known roles types (Admin, Resource
  Admin, Domain Admin and User) which maintains this association by requiring
  all new defined roles to specify a role type.
- Allows changes to roles and API permissions per role at runtime including additions or
  removal of roles and/or modifications of permissions, without the need
  of restarting management server(s)

Upgrade/installation notes:
- The feature will be enabled by default for new installations, existing
  deployments will continue to use the older static role based api access checker
  with an option to enable this feature
- During fresh installation or upgrade, the upgrade paths will add four default
  roles based on the four default role types
- For ease of migration, at the time of upgrade commands.properties will be used
  to add existing set of permissions to the default roles. cloud.account
  will have a new role_id column which will be populated based on default roles
  as well

Dynamic-roles migration tool: scripts/util/migrate-dynamicroles.py
- Allows admins to migrate to the dynamic role based checker at a future date
- Performs a harder one-way migrate and update
- Migrates rules from existing commands.properties file into db and deprecates it
- Enables an internal hidden switch to enable dynamic role based checker feature

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2016-05-11 09:45:19 +05:30
Rohit Yadav
95abb6efc3 CLOUDSTACK-9361: Centrally handle API validations
Validate API arguments based on annotations. Introduces:
- NotNullOrEmpty: for doing null and empty string checks
- PositiveNumber: number > 0 (natural number)

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2016-05-11 09:40:22 +05:30
nvazquez
baa8610061 CLOUDSTACK-9351: Add ids parameter to resource listing API calls 2016-05-06 14:42:42 -03:00
Maneesha.P
7ad3c5e834 CLOUDSTACK-8800 : Improved the listVirtualMachines API call to include memory utilization information for a VM for xenserver,kvm and for vmware. 2016-04-29 14:06:49 -03:00
Will Stevens
ff0e7f3ec4 Merge pull request #1126 from anshul1886/CLOUDSTACK-9088
CLOUDSTACK-9088: Update the description for migrateVirtualMachineWithVolume apihttps://issues.apache.org/jira/browse/CLOUDSTACK-9088

* pr/1126:
  CLOUDSTACK-9088: Update the description for migrateVirtualMachineWithVolume api.

Signed-off-by: Will Stevens <williamstevens@gmail.com>
2016-04-21 16:39:15 -04:00
Will Stevens
a957821074 Merge pull request #1363 from ustcweizhou/fix-scalevm-issue
CLOUDSTACK-9251: Fix issue in scale VM to dynamic service offeringThis reverts commit 9c4162ac7f451fc3e2155418dcfff224c8c08a4a and 16baa1289b7de383e98d0070717b3f1873fa2db3

Before change: exception when change compute offering (to dynamic service offering) on UI
After change: succeed

* pr/1363:
  Fix issue in scale VM to dynamic service offering

Signed-off-by: Will Stevens <williamstevens@gmail.com>
2016-04-18 08:37:25 -04:00
Will Stevens
08f2ec5044 Merge pull request #1263 from rafaelweingartner/lrg-cs-hackday-018
Removed unused code from com.cloud.api.ApiServer**Removed \_ from variables names**: private variables with \_ at the beginning is common in C++ but not in Java.

**Removed unused code from ApiServer:**
- com.cloud.api.ApiServer.getPluggableServices(): unused method;
- com.cloud.api.ApiServer.getApiAccessCheckers(): unused method;

**Methods and variables access level reviewed:**
- com.cloud.api.ApiServer.handleAsyncJobPublishEvent(String, String ,Object): this method was private but the annotation @MessageHandler requests public methods, as can be seen in org.apache.cloudstack.framework.messagebus.MessageDispatcher.buildHandlerMethodCache(Class\<?\>), which searches methods with the @MessageHandler annotation and changes
it to be accessible (setAccessible(true)). Thus, there is no reason for handleAsyncJobPublishEvent be a private method and lead some other dev to wrong conclusions about the use of the method;
- Global variables and methods called just by this class (ApiServer) were changed to private.

**Changed variables and methods from static to non-static (if possible):** as some variables/methods are used just by one object of this class, instantiated by Spring, they were changed to non-static.

With that, calls from com.cloud.api.ApiServlet.ApiServlet() that used static methods from ApiServer, were changed from ApiServer.\<staticMethodName\> to \_apiServer.\<methodName\> that refers to the org.apache.cloudstack.api.ApiServerService interface. Thus, methods com.cloud.api.ApiServer.getJSONContentType() and com.cloud.api.ApiServer.isSecureSessionCookieEnabled() had to be added in the interface (org.apache.cloudstack.api.ApiServerService, interface implemented by class ApiServer).

* pr/1263:
  The goal of this PR is to review com.cloud.api.ApiServer class, with the following actions:

Signed-off-by: Will Stevens <williamstevens@gmail.com>
2016-04-18 08:34:53 -04:00
gabrascher
48888e7405 The goal of this PR is to review com.cloud.api.ApiServer class, with the
following actions:

Removed “_” in beginning of global variables names:
Variables was changed from “_<variablename>” to “<variablename>”, as
this convension (private veriables with “_”) is common in C++ but not in
Java.

Removed unused code from ApiServer:
- com.cloud.api.ApiServer.getPluggableServices():
	Unused method.
- com.cloud.api.ApiServer.getApiAccessCheckers():
	Unused method.

Methods and variables access level reviewed:
- com.cloud.api.ApiServer.handleAsyncJobPublishEvent(String, String,
Object):
	This method was private but the annotation @MessageHandler requests
public methods, as can be seen in
org.apache.cloudstack.framework.messagebus.MessageDispatcher.buildHandlerMethodCache(Class<?>),
which searches methods with the @MessageHandler annotation and changes
it to accessible (“setAccessible(true)”). Thus, there is no reason for
handleAsyncJobPublishEvent be a private method.

- Global variables and methods called just by this class (ApiServer)
were changed to private.

Changed variables and methods from static to non static (if possible):
As some variables/methods are used just by one object of this class
(instantiated by springer), they were changed to non static.

With that, calls from com.cloud.api.ApiServlet.ApiServlet() that used
static methods from ApiServer, was changed from
ApiServer.<staticMethodName> to _apiServer.<methodName> that refers to
the org.apache.cloudstack.api.ApiServerService interface. Thus, methods
com.cloud.api.ApiServer.getJSONContentType() and
com.cloud.api.ApiServer.isSecureSessionCookieEnabled() had to be
included in the interface (org.apache.cloudstack.api.ApiServerService,
interface implemented by class ApiServer).

However, com.cloud.api.ApiServer.isEncodeApiResponse() was keept static,
as its call hierarchy would have to be changed (more than planed for
this PR).
2016-04-12 15:46:07 -03:00
weingartner
4179606c0b Removed classes with no reference
- org.apache.cloudstack.framework.jobs.JobCancellationException (removed
variable JobCancellationException in com.cloud.utils.SerialVersionUID)
- org.apache.cloudstack.ldap.NoSuchLdapUserException (removed test file
/cloud-plugin-user-authenticator-ldap/test/groovy/org/apache/cloudstack/ldap/NoSuchLdapUserExceptionSpec.groovy)
- com.cloud.agent.api.storage.CreateVolumeOVAAnswer
- com.cloud.exception.MissingParameterValueException
- org.apache.cloudstack.api.response.StatusResponse
- org.apache.cloudstack.api.response.VolumeDetailResponse
- org.apache.cloudstack.api.response.UpgradeVmResponse
- org.apache.cloudstack.api.response.AddIpToVmNicResponse
- org.apache.cloudstack.api.response.TemplateZoneResponse (at
org.apache.cloudstack.api.response.TemplateResponse, there is this
comment "To avoid breaking backwards compatibility, we still treat a
template at different zones as different templates, so not embedding
template_zone information in this TemplateZoneResponse set. `private
Set<TemplateZoneResponse> zones;`" but right now it is not used)
- org.apache.cloudstack.api.response.NicDetailResponse
2016-04-07 21:03:05 -03:00
Will Stevens
419f8fba63 Merge pull request #1425 from nvazquez/listtemplates
CLOUDSTACK-9298: Improve performance of resource retrieval that have tags associated and target volumes, VMs and templatesJIRA TICKET: https://issues.apache.org/jira/browse/CLOUDSTACK-9298

## Description of the problem
When retrieving a large number of resources which have tags associated with, retrieval methods took too long. Our goal is to improve performance of this methods avoiding query the database for each tag, managing that information in memory.
API methods to improve: <code>listTemplates</code>, <code>listVolumes</code>, <code>listVirtualMachines</code>

To achive it, it's necessary to include new columns in <code>template_view</code>, <code>volume_view</code> and <code>user_vm_view</code>:
* tag_account_name
* tag_domain_name
* tag_domain_uuid

* pr/1425:
  CLOUDSTACK-9298: Remove user definer from view creations
  CLOUDSTACK-9298: Add @MappedSuperClass support for persistence inheritance
  CLOUDSTACK-9298: Improve ListTemplatesCmd, ListVolumesCmd and ListVMsCmd performance

Signed-off-by: Will Stevens <williamstevens@gmail.com>
2016-03-31 22:24:36 -04:00
Will Stevens
c48b6c33c0 Revert "Merge pull request #780 from maneesha-p/pull-19" due code quality issues and lack of CI results.
This reverts commit dc0ba6bd1a774d3ff4bc4a4dcc00e1434ab1f6e3, reversing
changes made to 63f58dd5785ff2515b087d907bdf686347c75727.
2016-03-21 17:38:04 -04:00
Kishan Kavala
dc0ba6bd1a Merge pull request #780 from maneesha-p/pull-19
CLOUDSTACK-8800 : Improved the listVirtualMachines API call to include memory utilization information for a VMfor xenserver,kvm and for vmware.

* pr/780:
  CLOUDSTACK-8800 : Improved the listVirtualMachines API call to include memory utilization information for a VM for xenserver,kvm and for vmware.

Signed-off-by: Kishan Kavala <kishan@apache.org>
2016-03-17 12:35:48 +05:30
Maneesha.P
732a85295d CLOUDSTACK-8800 : Improved the listVirtualMachines API call to include memory utilization information for a VM for xenserver,kvm and for vmware. 2016-03-16 16:13:10 +05:30
Rafael Weingärtner
63f58dd578 Merge pull request #1434 from GabrielBrascher/rook-fix
Change variable "ROOK_DISK_CONTROLLER" to "ROOT_DISK_CONTROLLER"Change com.cloud.vm.VmDetailConstants variable name from "ROOK_DISK_CONTROLLER" to "ROOT_DISK_CONTROLLER". The ROOK_DISK_CONTROLLER variable stores the "rootDiskController" String; thus, this PR changes the name to "ROOT_DISK_CONTROLLER".

* pr/1434:
  VmDetailConstants "ROOK_DISK_CONTROLLER" to "ROOT_DISK_CONTROLLER"

Signed-off-by: Rafael Weingärtner <rafael@apache.org>
2016-03-10 20:29:08 -03:00
nvazquez
db54b26fed CLOUDSTACK-9298: Improve ListTemplatesCmd, ListVolumesCmd and ListVMsCmd performance 2016-03-10 06:07:29 -08:00
gabrascher
fea264c5da VmDetailConstants "ROOK_DISK_CONTROLLER" to "ROOT_DISK_CONTROLLER"
The ROOK_DISK_CONTROLLER variable stores the "rootDiskController"
String; thus, this commit changes the name to "ROOT_DISK_CONTROLLER".
2016-03-09 22:43:55 -03:00
Nuno Tavares
783aac8268 ADD be explicit about the underlying limitation - OpenSwan 2016-03-02 11:11:34 +01:00
Rohit Yadav
366629fb6b Merge pull request #831 from yvsubhash/CLOUDSTACK-8850
CLOUDSTACK-8850: revertSnapshot command does not workUpdating the documentation before the api is actually supported

* pr/831:
  Updating the Description as only supported with KVM
  CLOUDSTACK-8850: revertSnapshot command does not work Updating the documentation before the api is actually supported

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2016-01-27 15:56:51 +01:00
Remi Bergsma
43ab98d823 Updating pom.xml version numbers for release 4.9.0-SNAPSHOT
Signed-off-by: Remi Bergsma <github@remi.nl>
2016-01-26 15:12:20 +01:00
Remi Bergsma
32fcc47117 Updating pom.xml version numbers for release 4.8.1-SNAPSHOT
Signed-off-by: Remi Bergsma <github@remi.nl>
2016-01-26 09:39:00 +01:00
Remi Bergsma
8c60ad214f Merge release branch 4.7 to 4.8
* 4.7:
  CLOUDSTACK-9254: Make longer names display pretty
  CLOUDSTACK-9245 - Deletes ACL items when destroying the VPC or deleting the ACL itself
  CLOUDSTACK-9245 - Formatting NetworkACLServiceImpl class
  CLOUDSTACK-9245 - Formatting VpcManagerImpl class
  CLOUDSTACK-9245 - Formatting NetworkACLManagerImpl class
  More VR performance!
2016-01-26 08:39:28 +01:00
Wei Zhou
ef3dfbbd34 Fix issue in scale VM to dynamic service offering
This reverts commit 9c4162ac7f451fc3e2155418dcfff224c8c08a4a and 16baa1289b7de383e98d0070717b3f1873fa2db3

Before change: exception when change compute offering (to dynamic service offering) on UI
After change: succeed
2016-01-25 15:32:29 +01:00
Wilder Rodrigues
3ec37a0efd CLOUDSTACK-9245 - Deletes ACL items when destroying the VPC or deleting the ACL itself 2016-01-22 12:49:48 +01:00
Remi Bergsma
62f218b7bd Updating pom.xml version numbers for release 4.8.0
Signed-off-by: Remi Bergsma <github@remi.nl>
2016-01-20 23:43:35 +01:00
Remi Bergsma
bca6076f15 Merge pull request #864 from bvbharatk/CLOUDSTACK-8860
CLOUDSTACK-8860: improve error messages in VM deployment code path.improved the error messages in vm deployment code path. added some more data to the error messages and also fixed some errors using internal ids to use uuids.

* pr/864:
  CLOUDSTACK-8860: improve error messages in VM deployment code path.

Signed-off-by: Remi Bergsma <github@remi.nl>
2016-01-20 15:05:09 +01:00
Remi Bergsma
6f9215cf39 Merge release branch 4.7 to master
* 4.7:
  Refactor public ip retrieval into method
  CLOUDSTACK-9244 Fix setting up RFC1918 routes
  CLOUDSTACK-9239 throw exception on deprecated command
  Enhance VR performance by selectively executing tasks instead of brute-forcing
  CLOUDSTACK-9236: Load Balancing Health Check button displayed when non-NetScaler offering is used
2016-01-20 14:18:09 +01:00
Remi Bergsma
d9ce59f11c Merge pull request #1349 from DaanHoogland/CLOUDSTACK-9239
CLOUDSTACK-9239 throw exception on deprecated commandan API call to LockAccount fails silently with a 200 return and no contents. client are responsible to check and will find that no locking has actually occured. This way they may be lured to a sense of false security.
Throwing an exption makes the failure explicit.
cloudmonkey lock account name=<name> domainid=<id>
now errors out with an http result of 530

* pr/1349:
  CLOUDSTACK-9239 throw exception on deprecated command

Signed-off-by: Remi Bergsma <github@remi.nl>
2016-01-20 13:47:26 +01:00
Remi Bergsma
f98f983583 Merge release branch 4.7 to master
* 4.7:
  ui: improve metrics view implementation
  CLOUDSTACK-9132: API createVolume takes empty string for name parameter
2016-01-19 17:48:25 +01:00
Remi Bergsma
c7ad1b6083 Merge pull request #1319 from nitin-maharana/CloudStack-Nitin15_4.7
CLOUDSTACK-9132: API createVolume takes empty string for name parameterSteps to Reproduce:
================

Create a volume using createVolume API where parameter name is empty.
It creates a volume with empty name.
But the name parameter is mandatory.(Issue)

Expected Behaviour:
================

It shouldn't create a volume with an empty name. Error should be returned.

Solution:
=======

Added a condition to check in case of empty string. If the name is an empty string, it generates a random name for the volume. Made the name field optional in UI as well as in API.

* pr/1319:
  CLOUDSTACK-9132: API createVolume takes empty string for name parameter

Signed-off-by: Remi Bergsma <github@remi.nl>
2016-01-19 17:44:56 +01:00
Daan Hoogland
9e72796e96 CLOUDSTACK-9239 throw exception on deprecated command 2016-01-19 10:29:43 +01:00
Remi Bergsma
75b68c6829 Merge release branch 4.7 to master
* 4.7:
  Fix unable to setup more than one Site2Site VPN Connection
  FIX S2S VPN rVPC: Check only redundant routers in state MASTER
  PEP8 of integration/smoke/test_vpc_vpn
  Add S2S VPN test for Redundant VPC
  Make integration/smoke/test_vpc_vpn Hypervisor independant
  FIX VPN: non-working ipsec commands
  [UI] MADNESS
  [DB] Add force_encap field to s2s_customer_gateway table
  [ROUTER] Add forceencaps field to python router ipsec config method
  [TEST] unittest needs rework
  [MARVIN] Add forceencap field to VpnCustomerGateway class in marvin base
  [CORE] Add Force UDP Encapsulation option to Site2Site VPN
  CLOUDSTACK-9186: Root admin cannot see VPC created by Domain admin user
  CLOUDSTACK-9192: UpdateVpnCustomerGateway is failing
  CLOUDSTACK-6485 prevent ip asignment of private gw iface
  CLOUDSTACK-9204 Do not error when staticroute is already gone
  make both check lines consistent
  CLOUDSTACK-9181 Prevent syntax error in checkrouter.sh
  CLOUDSTACK-9202 Bump ssh timeout
2016-01-16 19:54:41 +01:00
Nitin Kumar Maharana
55f8b32aa0 CLOUDSTACK-9132: API createVolume takes empty string for name parameter
Added conditions to check if the name is empty or blank.
If it is empty or blank, then it generates a random name.
Made the name field as optional in UI as well as in API.
Added required unit tests.
2016-01-08 13:41:41 +05:30
Michael Andersen
6da3bc1237 [CORE] Add Force UDP Encapsulation option to Site2Site VPN 2016-01-07 19:27:37 +01:00
nvazquez
0b20ed4074 CLOUDSTACK-9074: Add NetworkGuruAdditionalFunctions license 2015-12-24 16:07:06 -03:00
nvazquez
06d5b46e53 CLOUDSTACK-9074: New NiciraNVP classes to support Shared Networks 2015-12-24 16:07:06 -03:00
nvazquez
8149081658 CLOUDSTACK-9074: API Changes: Add nsxLogicalSwitch and nsxLogicalSwitchPort to listNics 2015-12-24 16:07:06 -03:00
nvazquez
46f9fbabdf CLOUDSTACK-9074: API Changes: Add l2gatewayserviceuuid to NVP devices 2015-12-24 16:07:06 -03:00
Remi Bergsma
8f5a2920e8 Updating pom.xml version numbers for release 4.8.0-SNAPSHOT
Signed-off-by: Remi Bergsma <github@remi.nl>
2015-12-21 22:09:31 +01:00
Remi Bergsma
5b112408c7 Updating pom.xml version numbers for release 4.7.1-SNAPSHOT
Signed-off-by: Remi Bergsma <github@remi.nl>
2015-12-21 19:55:04 +01:00
Remi Bergsma
2b76f394c0 Updating pom.xml version numbers for release 4.6.3-SNAPSHOT
Signed-off-by: Remi Bergsma <github@remi.nl>
2015-12-21 13:53:54 +01:00
Remi Bergsma
2f26a859a9 Updating pom.xml version numbers for release 4.7.0
Signed-off-by: Remi Bergsma <github@remi.nl>
2015-12-13 21:09:53 +01:00
Daan Hoogland
1063508003 Merge pull request #1186 from remibergsma/462_version
Updating pom.xml version numbers for release 4.6.2-SNAPSHOTSet next version in 4.6 release branch to version 4.6.2-SNAPSHOT.

Using ` ./tools/build/setnextversion.sh`.

Ping @bhaisaab @DaanHoogland before we merge this, how will we be creating the upgrade paths from 4.6.2 to 4.7? After this PR is merged, we need to manually do a fwd-merge and make sure we keep the pom versions in master/4.7. Much like in #1071.

* pr/1186:
  Fixed typo in iam/pom.xml
  Updating pom.xml version numbers for release 4.6.2-SNAPSHOT

Signed-off-by: Daan Hoogland <daan@onecht.net>
2015-12-12 23:17:19 +01:00
Remi Bergsma
cdfcea3da2 Merge release branch 4.6 to master
* 4.6:
  [UI] bug fix: Delete added ACL lists is not available for Domain Admin and normal users
  CLOUDSTACK-4787: Allow users to select disk controller for VM/template
  CLOUDSTACK-4787 Allow selection of scsi controller type in vSphere
2015-12-12 22:29:19 +01:00
Remi Bergsma
5147dec4ff Updating pom.xml version numbers for release 4.6.2-SNAPSHOT
Signed-off-by: Remi Bergsma <github@remi.nl>
2015-12-12 21:49:37 +01:00
Daan Hoogland
8c78f89c91 Merge pull request #1132 from shapeblue/4.6-vmware-diskcontrollers
[4.6] CLOUDSTACK-4787 - vmware diskcontrollersSame as #1131 (see this for screenshots etc)

* pr/1132:
  CLOUDSTACK-4787: Allow users to select disk controller for VM/template
  CLOUDSTACK-4787 Allow selection of scsi controller type in vSphere

Signed-off-by: Daan Hoogland <daan@onecht.net>
2015-12-12 14:38:28 +01:00
Wei Zhou
24f1396ac1 CLOUDSTACK-9129: list vpc routers by keyword in Infrastructure -> Virtual Routers
and two more changes:
(1) add network name/vpc name in the listRouters response
(2) add network name/vpc id, vpc name in the router details page
2015-12-10 09:14:12 +01:00
Abhinandan Prateek
987fcbd441 CLOUDSTACK-8592: Implement Quota service
Quota service while allowing for scalability will make sure that the cloud is
not exploited by attacks, careless use and program errors. To address this
problem, we propose to employ a quota-enforcement service that allows resource
usage within certain bounds as defined by policies and available quotas for
various entities.  Quota service extends the functionality of usage server to
provide a measurement for the resources used by the accounts and domains using a
common unit referred to as cloud currency in this document. It can be configured
to ensure that your usage won’t exceed the budget allocated to accounts/domain
in cloud currency.  It will let user know how much of the cloud resources he is
using. It will help the cloud admins, if they want, to ensure that a user does
not go beyond his allocated quota. Per usage cycle if a account is found to be
exceeding its quota then it is locked. Locking an account means that it will not
be able to initiat e a new resource allocation request, whether it is more
storage or an additional ip. Needless to say quota service as well as any action
on the account is configurable.

Changes from Github code review:

- Added marvin test for quota plugin API
- removed unused commented code
- debug messages in debug enabled check
- checks for nulls, fixed access to member variables and feature
- changes based on PR comments
- unit tests for UsageTypes
- unit tests for all Cmd classes
- unit tests for all service and manager impls
- try-catch-finally or try-with-resource in dao impls for failsafe db switching
- remove dead code
- add missing quota calculation case (regression fixed)
- replace tabs with spaces in pom.xmls
- quota: though default value for quota_calculated is 0, the usage server
  makes it null while entering usage entries. Flipping the condition so
  as to acocunt for that.
- quotatypes: fix NPE in quota type
- quota framework test fixes
- made statement period configurable
- changed default email templates to reflect the fact that exhausted quota may not result in a locked account
- added quotaUpdateCmd that refreshes quota balances and sends alerts and statements
- report quotaSummary command returns quota balance, quota usage and state for all account
- made UI framework changes to allow for text area input in edit views
- process usage entries that have greater than 0 usage
- orocess quota entries only if tariff is non zero
- if there are credit entries but no balance entry create a dummy balance entry
- remove any credit entries that are before the last balance entry
  when displaying balance statement
- on a rerun the last balance is now getting added

FS: https://cwiki.apache.org/confluence/display/CLOUDSTACK/Quota+Service+-+FS
PR: https://github.com/apache/cloudstack/pull/768

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-12-07 23:02:48 +05:30