Commit Graph

55 Commits

Author SHA1 Message Date
Alena Prokharchyk 339aa41442 CLOUDSTACK-304: Synchronization support for createSnapshot command - don't sent more than "concurrent.snapshots.threshold.perhost" createSnapshots commands to the backend host.
Conflicts:

	core/src/com/cloud/async/AsyncJobVO.java
	core/src/com/cloud/async/SyncQueueVO.java
	server/src/com/cloud/api/ApiDispatcher.java
	server/src/com/cloud/api/ApiServer.java
	server/src/com/cloud/async/AsyncJobManagerImpl.java
	server/src/com/cloud/async/SyncQueueManager.java
	server/src/com/cloud/async/SyncQueueManagerImpl.java
	server/src/com/cloud/async/dao/SyncQueueDao.java
	server/src/com/cloud/storage/snapshot/SnapshotSchedulerImpl.java
	server/test/com/cloud/async/TestSyncQueueManager.java
	setup/db/create-schema.sql
2012-10-10 13:40:00 -07:00
Mice Xia 5532f58bbc remove cloud.com license headers 2012-09-13 12:34:32 +08:00
David Nalley e87558256c Patch from Chip Childers
https://reviews.apache.org/r/5704/
License header updates for the server folder
2012-07-02 09:51:21 -04:00
Alex Huang 7c6932ef80 some reformatting and a new way to get vos into the system 2012-04-12 11:04:38 -07:00
David Nalley 59436be4ee fixing line endings in server 2012-04-07 20:13:10 -04:00
frank 2f634c0913 Switch to Apache license 2012-04-03 04:50:05 -07:00
kishan 08df288bf5 Bug 13175: Fixed typos. minotoring instead of monitoring, assignbed instead of assigned
Status 13175: resolved fixed
Reviewed-By: Nitin
2012-01-30 14:31:48 +05:30
Alena Prokharchyk 83400cd15f bug 12776: if there are multiple objects involved in resource creation, verify that they belong to the same account
status 12776: resolved fixed
2012-01-17 13:40:37 -08:00
Alena Prokharchyk c581506103 bug 12306: list* command revamp 2012-01-09 10:07:42 -08:00
Alena Prokharchyk 28913c791b bug 11626: return same fields in queryAsyncJobResult and listAsyncJobs API commands
status 11626: resolved fixed
2011-12-09 16:50:08 -08:00
Alena Prokharchyk 7ea6082f22 PhysicalNetworkId is not required in listNetworkServiceProvider call 2011-11-29 10:47:03 -08:00
Kelven Yang 8d8775b533 bug 6745: Using UUID instead of integers - for Async Jobs 2011-11-03 07:33:58 -07:00
alena 41be3716e3 bug 11196: fixed the code when gson serialization was done twice
status 11196: resolved fixed
2011-08-29 14:50:18 -07:00
alena e3f179844e bug 11236: domainAdmin/regularUser can edit/delete/copy/extract Public template/iso only if it was created by them. They still can use/see public template/iso when execute list/deploy/attachIso commands. Root admin can operate with other people templates w/o any restrictions.
status 11236: resolved fixed
2011-08-24 14:48:35 -07:00
Kelven Yang 2335fc5be4 bug 10918: cap async-job execution thread pool to be 2/3 of maximum DB connection limit 2011-07-29 18:37:32 -07:00
Alex Huang d140ca7555 Fixes the issue where the Job-Executor can hit an exception in cleanup and eventually the entire executor pool is gone. 2011-06-02 09:54:34 -07:00
alena b5aabfab75 bug 9898: fixed attachIso by domain admin - no need to make permission check when iso is public
status 9898: resolved fixed
2011-05-17 11:11:13 -07:00
alena a4619c8347 bug 9859: added missing permission checks to queryAsyncJobResult API
status 9859: resolved fixed

Conflicts:

	server/src/com/cloud/async/AsyncJobManagerImpl.java
2011-05-13 14:03:12 -07:00
alena 1a6d78eae4 Code cleanup. No need to declare runtime exceptions (CloudRuntimeException, InvalidParameterException, PermissionDenied exceptions) 2011-04-21 16:26:53 -07:00
Kelven Yang 1b9cbd9166 bug 9223, 9224: persist runid to form cluster session, based on cluster session and DB condition to issue isolation notification for self-fencing 2011-04-13 15:13:54 -07:00
Alex Huang 075fba5899 stackmaid is now taskmanager 2011-04-05 10:17:22 -07:00
Kelven Yang 65d4cc98be Allow template re-deployment once template is deleted from hypervisor and CloudStack still holds out-dated status 2011-03-17 17:59:51 -07:00
Kelven Yang 6203ba6bfe bug 8558: improve cluster management 2011-03-09 17:18:48 -08:00
Kelven Yang 33b3333d65 Add JMX support to async job management, active job details will be checked in jConsole 2011-03-08 16:34:17 -08:00
Kelven Yang 2f5bacf980 bug 8768: merge fix in 2.2.2 to master 2011-02-28 15:59:21 -08:00
Kelven Yang 1d8eab2a11 Let reset job description to be in API standard 2011-02-22 17:40:05 -08:00
alena e4765fb32b bug 6969: return jobId/jobStatus for IpAddress and SecurityGroup as ids for these objects were introduced in 2.2.x 2011-02-22 09:09:55 -08:00
alena 6f55c4dd7e bug 8270: Synchronize on 1) ipAddress object when create/delete ipForwarding/portForwardingRule and vpn service 2) on networkId when assignTo/removeFrom/deleteLoadBalancer
status 8270: resolved fixed
2011-02-03 18:45:49 -08:00
Kelven Yang 244d8c198b Cleanup UserContext after execution for better security 2011-01-26 17:06:14 -08:00
Kelven Yang ea88089fd2 Bug 7409: Implement forcely-cancelling mechenism for jobs that have been staying in queue for too long
1) introduced a global configuration variable job.cancel.threshold.minutes
2) Default value for the job.cancel.threshold.minutes is 60 minutes, if a job has been staying in processing state for over 60 minutes, system will forcely remove it from the queue to allow others to run
2011-01-05 15:44:10 -08:00
Kelven Yang 7c5895d7d5 Bug 7598: add management server restart and peer-cleanup within cluster handling to async job processing 2011-01-03 16:47:46 -08:00
Kelven Yang 3a6a7e30ce Make management server peer in cluster to help cleanup left-over pending jobs 2010-12-30 18:53:26 -08:00
alena 7b3b9076b0 bug 6168: throw a runtime exception when unable to schedule Async job instead of returning jobId=0L
status 6168: resolved fixed
2010-12-27 17:00:29 -08:00
alena 7e9579dab2 Fixed create/list LoadBalancerRules 2010-12-09 21:06:48 -08:00
will c67d26cec4 bug 6969: First step of now displaying pending async jobs for listXXXCommands. There is a lot more cleanup and fixing to do but all commands acting against VirtualMachines now work. 2010-11-30 19:12:09 -08:00
alena aa8aa6027a Modified UserContext - got rid of accountName, domainId fields as we can get this information from Account field. 2010-11-24 14:29:08 -08:00
alena cb74030d01 bug 7298: throw an Exception when invalid job Id is specified in queryAsyncJobResult
status 7298: resolved fixed
2010-11-23 15:06:29 -08:00
Alex Huang 1e44925564 api refactoring 2010-11-21 12:00:21 -08:00
alena 5fafef9970 More api refactor - build api response is execute() method instead of getResponse method. 2010-11-09 09:58:05 -08:00
alena 1c24deda34 1) Refactored current Apis not to use reflection for method invocation. In new version following has to be done:
* Implement callCreate() and execute() methods in apis extending BaseAsyncCreateCmd (example - CreateVolumeCmd)
* Implement execute() method in apis extending BaseCmd and BaseAsyncCmd (example - deleteVolumeCmd and deleteUserCmd)

We no longer need createMethod(), method(), manager() fields in @Implementation annotation, cleanup has to be done.

2) Moved Account/User related methods to AccountManagerImpl. Methods are exposed via AccountService interface.
3) Enhanced exception handing for Api calls.
4) Created ConfigurationService interface, all Api config methods are exposed via it.
2010-11-08 11:27:36 -08:00
will 05ab3bf673 bug 7063: AsyncJobResult should now return the correct success and error tags upon the completion of a async job. It should now follow either the format ... jobresult.success or jobresult.errorcode and jobresult.errortext
- Fixed a lot of other Async related packaging issues.  It's not all done but will continue to refactor this later.
2010-11-05 17:30:03 -07:00
Kris McQueen 484f334d7a bug 6799: if there's an exception executing the Async command, create an error response with the appropriate information so that queryAsyncJobResult returns the relevant information
status 6799: resolved fixed
2010-10-27 18:23:23 -07:00
Kris McQueen 2740ba6c40 final merge of master->2.1.refactor preparing for merge back into master 2010-10-12 14:46:24 -07:00
anthony 319d4f1aa0 snapshot redesign
1. use full snapshot and delta snapshot, there are maxsnashot/2 of delta snapshot between two full snapshot
2. only support one policy for one volume
3. remove all coleases in secondary storage.
2010-09-28 18:37:46 -07:00
Kris McQueen 848ce60097 Merging master into 2.1.refactor, resolve the merge conflicts as best I can. New commands related to extracting template/iso/volume and related to instance groups were refactored to the new API framework. 2010-09-28 15:47:14 -07:00
Kris McQueen 62257d4021 Fix serializing async job responses by writing a custom adapter for ResponseObjects. Improve exception handling when calling async commands (the job still needs to complete, but with FAILED status). 2010-09-24 13:52:35 -07:00
Kris McQueen 2a4ddac41a Change getResponse() to return a ResponseObject so that the caller can choose how to serialize. This in in preparation for serializing the async commands to the database with class information and deserializing them into the ResponseObject itself when queryAsyncJobResult is called. Once the ResponseObject is deserialized, the proper string can be returned to the caller.
The previous behavior had the JSON response from the command embedded into the queryAsyncJobResult response as a string rather than a JSON object which prevented the client from being able to read the response.  With this new behavior an actual JSON object should be returned which can then be parsed on the client side.
2010-09-23 17:34:28 -07:00
Kris McQueen c32d6e7524 Template id is not a required parameter when listing templates. The proper serialized name for the async job id is jobid, not id. Sadly, ctxAccoutId != ctxAccountId, ugh, no wonder the UserContext wasn't getting set up correctly. Clean up some miscellaneous unnecessary casts. 2010-09-21 17:00:50 -07:00
Kris McQueen e2e0e76063 More work on serializing responses. Now responses have to have the name set on them, and the name will eventually be serialized to the JSON/XML response the way it used to work for commands themselves [the result of cmd.getName() was written to the response string]. For list respones, we wrap the individual objects in a ListResponse object that has the name of the response, and the individual objects have the object name so that accounts will be something like <listaccountsresponse><account><...></account><account><...></account></listaccountsresponse>. 2010-09-17 17:13:04 -07:00
Kris McQueen 4a73639d67 Fix up setting the response object correctly after dispatching the api method call. Begin working on the serialization of the responses which don't include the command name just yet, that's coming. 2010-09-17 14:56:55 -07:00