315 Commits

Author SHA1 Message Date
Mandar Barve
b0c6d47347 - Updated APICommand annotation to add new flags that indicate if API request or response carry sensitive info - Updated all API classes with the new annotation flag values as per the API's sensitivity - Updated server code to check response annotation before audit logging
Signed-off-by: Daan Hoogland <daan@onecht.net>
(cherry picked from commit df270d6387c362b960064ee5123c14782e767a19)
Signed-off-by: Daan Hoogland <daan@onecht.net>
2014-02-25 22:59:10 +01:00
Alena Prokharchyk
782c530685 Revert "CLOUDSTACK-6003 fixing plus refactoring dispatcher" as it breaks API dispatching for commands having Map<String,String> as a parameter type
This reverts commit 447430c3df38c36d947c44c4aebd961d8cbb14c4.

Conflicts:
	api/src/org/apache/cloudstack/api/BaseCmd.java
	server/src/com/cloud/api/ApiDispatcher.java
	server/src/com/cloud/network/as/AutoScaleManagerImpl.java
	server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java
2014-02-06 14:46:58 -08:00
Prachi Damle
f84375442e Merge branch 'master' into rbac
Conflicts:
	api/src/org/apache/cloudstack/api/command/user/autoscale/ListAutoScaleVmProfilesCmd.java
	api/src/org/apache/cloudstack/api/command/user/volume/ResizeVolumeCmd.java
	plugins/network-elements/juniper-contrail/test/org/apache/cloudstack/network/contrail/management/MockAccountManager.java
	server/src/com/cloud/api/ApiServer.java
	server/src/com/cloud/api/query/QueryManagerImpl.java
	server/src/com/cloud/template/TemplateAdapterBase.java
	setup/db/db/schema-430to440.sql
	tools/apidoc/gen_toc.py
2014-02-04 12:07:32 -08:00
Antonio Fornie
447430c3df CLOUDSTACK-6003 fixing plus refactoring dispatcher
Signed-off-by: Daan Hoogland <daan@onecht.net>
(cherry picked from commit a9bcc1ea3b7dfd3fcc5c795b0095c77851ebe618)
Signed-off-by: Daan Hoogland <daan@onecht.net>
2014-02-04 13:37:08 +01:00
Daan Hoogland
a71871d11c findbugs: fixes for ApiServer, ApiSerializerHelper and
ApiXmlDocWriter(cherry picked from commit
9aced41d708acd22b43ef0e512fa2cc657a6c0a2)
2014-01-28 14:47:06 +01:00
Min Chen
33cd1ab921 Merge branch 'master' into rbac 2014-01-22 11:23:51 -08:00
Min Chen
3689f72f27 CLOUDSTACK-5913:API rate limiting throws a different error than expected
when Throttle limit hit in the API.
2014-01-20 15:49:19 -08:00
Min Chen
929fbabaa2 Merge branch 'master' into rbac. 2014-01-17 14:37:08 -08:00
Likitha Shetty
16d36dd75f Fix checkstyle 2014-01-14 14:04:57 +05:30
Likitha Shetty
e5512960af CLOUDSTACK-5865. Unable to use login API if domainId parameter is id and not uuid 2014-01-14 13:47:27 +05:30
Min Chen
43f0f901dd Remove VO and DAO from cloud-engine-schema. 2014-01-10 15:57:39 -08:00
Prachi Damle
e5b4a1d869 Moved the loading of commands.properties to the IAM plugin 2014-01-02 18:39:18 -08:00
Prachi Damle
ce774e184e Fixing the management server startup 2013-12-18 14:14:55 -08:00
Prachi Damle
3f092d14cc Adding the AclEntityType attribute to APICommand annotation 2013-12-13 16:04:25 -08:00
Min Chen
312ff76f69 Separate listZones cmd to use two different views, also renamed previous
listZonesByCmd to listZonesCmd.
2013-12-12 17:40:30 -08:00
Alex Huang
be5e5cc641 All Checkstyle problems corrected 2013-12-12 12:26:07 -08:00
Min Chen
a416f6c3c3 Fix API build error based on new DB schema, now only
RoleBasedEntityAccessChecker needs to be fixed.
2013-12-06 15:09:00 -08:00
Prachi Damle
cf69731a52 Suring startup load the API permissions from commands.properties and @APICommand annotations 2013-11-25 17:01:56 -08:00
Prachi Damle
f231cec5b7 Loading api permissions from commands.properties during startup 2013-11-25 10:59:12 -08:00
Min Chen
81a794a5d3 Change two static response views to Full and Restricted. 2013-11-21 10:32:08 -08:00
Alex Huang
433a631916 Reformat of source code to set a stable base for the future. I couldn't get checkstyle enabled. There's still about a thousand errors from checkstyle. Most of it from length errors from comments and strings. Will attempt to remove those tonight. This change is so large I just want to get it in before any merge nightmares. The changes are fairly minor though and I did a full compile and start a server with the reformat code. 2013-11-21 07:56:47 -08:00
Alex Huang
d620df2bdd Reformatted all of the code. 2013-11-21 06:15:26 -08:00
Likitha Shetty
6aafb9c50d CLOUDSTACK-5227. Cannot pass Japanese characters as parameter values to an API.
During API check for control characters use pattern matching to avoid identifying all non-printable characters as control characters.
2013-11-21 13:40:06 +05:30
Alex Huang
8d62744681 Reformat all source code. Added checkstyle to check the source code 2013-11-20 07:26:53 -08:00
Min Chen
2ef4d5200c Merge branch 'master' into rbac. 2013-10-31 17:16:33 -07:00
Darren Shepherd
e3280bdba2 Merge remote-tracking branch 'origin/spring-modularization'
Conflicts:
	client/tomcatconf/applicationContext.xml.in
	client/tomcatconf/nonossComponentContext.xml.in
	client/tomcatconf/simulatorComponentContext.xml.in
	framework/db/src/com/cloud/utils/db/Transaction.java
	plugins/hypervisors/simulator/src/com/cloud/agent/manager/MockAgentManagerImpl.java
	server/src/com/cloud/api/ApiServer.java
	server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
2013-10-23 11:14:42 -07:00
Darren Shepherd
711ad386d1 Random cleanup 2013-10-16 16:18:49 -07: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
Min Chen
d84d62a1e0 Separate Admin and User command and response for ListVMsCmd. 2013-10-02 17:45:14 -07:00
Darren Shepherd
67186429e1 Spring Modularization
ACS is now comprised of a hierarchy of spring application contexts.
Each plugin can contribute configuration files to add to an existing
module or create it's own module.

Additionally, for the mgmt server, ACS custom AOP is no longer used
and instead we use Spring AOP to manage interceptors.
2013-10-02 15:41:04 -07:00
Darren Shepherd
aed5e9dc2a Add Manage Context framework
The managed context framework provides a simple way to add logic
to ACS at the various entry points of the system.  As threads are
launched and ran listeners can be registered for onEntry or onLeave
of the managed context.  This framework will be used specifically
to handle DB transaction checking and setting up the CallContext.
This framework is need to transition away from ACS custom AOP to
Spring AOP.
2013-10-02 13:09:52 -07:00
Darren Shepherd
efbfae723e Switch to setter injection for extensibility
Various classes are using member injection to inject extensible objects.
Really those object should come from an AdapterList that is injected in.
This patch switches the code to use setter injection that will later allow
spring to inject an AdapterList or something similar to allow
extensibility.
2013-09-30 09:45:07 -07:00
Prachi Damle
aba54356d5 Account_Type Refactoring for Root Admin Role
- change the AccountService::isRootAdmin(short) to  isRootAdmin(long accountId);
- Change all callers
- Change all places that check the account.getType() directly to call the AccountManagerImpl.
2013-09-24 15:31:09 -07:00
Alex Huang
b8e79c30a8 Compile complete 2013-09-06 15:40:37 -07:00
Min Chen
97ff4981c5 CLOUDSTACK-3274: Remove duplicate cleanString calls in logging api for
performance improvement.
2013-08-16 11:10:25 -07:00
Alex Huang
5495f10bce Revert "Reverting the range of commits that broke the build"
This reverts commit b59e3aaefced03d40d5b4b63c421c69743bcd387.
2013-08-08 15:02:40 -07:00
Prasanna Santhanam
b59e3aaefc Reverting the range of commits that broke the build
This reverts commits 30c33415..f6a2c817bc

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-08-08 14:46:56 +05:30
Alex Huang
942f282a6e Moved config into it's own package 2013-08-07 16:41:02 -07:00
Alex Huang
8930cfa983 Switched over to use the new jobs framework 2013-08-02 11:07:55 -07:00
Chiradeep Vittal
1744ed7ad5 CLOUDSTACK-3626 register the correct user and account for api calls made with api keys and secret keys 2013-07-25 14:45:59 +05:30
Alena Prokharchyk
d0422904d7 CLOUDSTACK-3711: return descriptive error message to the regular user when his resource limit has exceed. No harm in returning this info as the user aware of the resource limits/number of resources available for allocation, for his account
Conflicts:
	server/src/com/cloud/api/ApiServer.java
2013-07-22 10:28:42 -07:00
Min Chen
d423a755f5 CLOUDSTACK-3274: API Refactoring: secretkey and accesskey of the backing
store is found in plaintext in the logs.

Conflicts:
	server/src/com/cloud/api/ApiServer.java
	server/src/com/cloud/api/ApiServlet.java
2013-07-20 18:01:49 -07:00
ahuang
11971b5a58 Bring over from vmsync changes in utils package. Simple changes. New files are not being used yet in master 2013-07-17 18:29:42 -07:00
ahuang
11e1e585b1 UserContext switched to CallContext. Added generic storage mechanism for other code to carry information throughout a call. Made the calling User and Account a must have. Added an interface to carry entities in error. Fixed up the code. Part of the vmsync branch 2013-07-16 11:24:21 -07:00
Ryan Dietrich
70f33efa72 CLOUDSTACK-3190: Async jobs actions now trigger event bus messages to be
published

-AsyncJobManagerImpl to publish async job events when async jobs are
created, updated and completed
2013-07-05 17:48:25 +05:30
Prasanna Santhanam
767ed065c5 CLOUDSTACK-2815: Include dedication in simulator context
SimulatoComponentContext need sto include the dedicated resource manager
to see the commands/apis exposed by it.

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-06-03 21:51:18 +05:30
Alena Prokharchyk
da53ef1aed ApiServer: fixed non primitive Long "snapshotLimit" comparsion 2013-05-30 15:21:31 -07:00
Alena Prokharchyk
62ad6c4519 ApiServer: replaced hardcoded value of the integration.api.port paramter with the reference to the actual paramter name 2013-05-30 15:21:31 -07:00
Alena Prokharchyk
1300fc8128 AccountManager/Service: reduced visibility for methods that are called only from AccountManagerImpl itself 2013-05-30 11:18:32 -07:00
Alena Prokharchyk
0ea409546e RulesManager interface: changed visibility for methods that are being called only from RulesManagerImpl class, from public and defined in the interface, to private/protected 2013-05-30 11:18:31 -07:00