Statistics
| Branch: | Tag: | Revision:

root / db @ dddb9274

# Date Author Comment
3ca38a07 03/02/2011 06:03 pm Vassilios Karakoidas

Many fixes and refactoring in models

  • Simplified code in VirtualMachine._update_state()
  • Added comments in Flavor._get_costs() and other model methods
27816aae 03/02/2011 04:17 pm Vassilios Karakoidas

Added update_state() method (fixes)

  • Rename update_state to new _update_state() method, used by the
    VirtualMachine model internally to update its state. Not to be
    called by external entities.
dac43564 03/02/2011 03:18 pm Vassilios Karakoidas

Added update_state() method

  • VirtualMachine model now has the update_state() method
    to set the _operstate field
  • Modified the other models to user update_state() method
452d2391 03/02/2011 02:29 am Vassilios Karakoidas

Implemented Charger Functionality

  • Re-implemented the tests
  • Added functionality to all charger-related functions
  • Added functionality to the charger itself

The code needs still lots of testing

c0124a81 02/28/2011 10:42 am Dimitris Moraitis

add functional test for the wizard

39d236e9 02/27/2011 10:19 pm Dimitris Moraitis

allow the destruction of suspended vms

3c53cf3a 02/27/2011 08:09 pm Dimitris Moraitis

complete the rename of AccountingLog to Debid - fix breakage

The changes in d174b105e0fb3038bcf69623f3624f99f437ea3f broke the
app and the tests. The AccountingLog class had been renamed but
several references were left using the old name.

Also removed the violation attribute from fixtures since it was...

d174b105 02/27/2011 01:09 pm Vassilios Karakoidas

Changed models to match current specification

  • Rename AccountingLog -> Debit
  • FlavorCostHistory -> FlavorCost
  • Tests are broken (work in progress)
  • CreditAllocator is broken
7b4b06a2 02/25/2011 08:50 pm Markos Gogoulos

removed get_vmid and vm_id from Image

since sourcevm field has been added

0a92f190 02/25/2011 05:32 pm Constantinos Venetsanopoulos

Add VirtualMachineMetadata values in fixtures

739bd6e8 02/25/2011 04:37 pm Constantinos Venetsanopoulos

Add values for 'size' and 'sourcevm' in Image fixtures

d6094a56 02/25/2011 04:24 pm Constantinos Venetsanopoulos

Add the 'size' field in the Image model

The 'size' field was added in the Image model.
It shows the Image's size in MBs

e171c0be 02/25/2011 12:26 pm Vangelis Koukis

Fix bug in VirtualMachine.start_action().

Modify start_action() to set self.deleted/suspended.

48223290 02/24/2011 10:08 pm Markos Gogoulos

fixed bug on start_action (needed self.deleted instead of deleted)

c750d1d6 02/24/2011 02:44 pm Vangelis Koukis

Add deleted field VirtualMachine model.

Add a 'deleted' field in VirtualMachine model. Remove 'inactive' field.
Update the start_action() method to manage deleted/suspended fields for
the DESTROY and SUSPEND action respectively.

e336bde6 02/24/2011 01:47 pm Markos Gogoulos

addresses and metadata fields on GET /servers/detail

4daac449 02/23/2011 09:01 pm Vassilios Karakoidas
  • Fixed an syntax error in Flavor (added a comma)
  • Added field inactive in VirtualMachine model
13b3c5ff 02/23/2011 08:10 pm Vassilios Karakoidas
  • Add desccription (verbose_name) to many models in the db/models.py; no need for translation with _()
  • Removed unique=False from Flavor.cpu|ram|disk
bf48028e 02/22/2011 08:14 pm Vassilios Karakoidas
  • SynnefoUser.monthly_rate deleted
  • Introduced three limits (MONTHLY_RATE, QUOTA_CREDIT, MAX_VIOLATIONS)
  • Added three test limits in db_test_data.json
  • mothly_rate, credit_quota, max_violations properties are now introduced in SynnefoUser class
b3b54e38 02/22/2011 07:54 pm Vassilios Karakoidas
  • AccountingLogTestCase & VirtualMachineTestCase are noow working properly
966be609 02/22/2011 07:53 pm Vassilios Karakoidas
  • Fixed FlavorTestCase
eb66f1fe 02/22/2011 07:46 pm Vassilios Karakoidas
  • CreditAllocatorTestCase is working now properly
b4808d2b 02/22/2011 07:33 pm Vassilios Karakoidas
  • Image now includes Foreign Key relationship with VirtualMachine (sourcevm)
  • Fixed primary key ranges in db/db_test_data.json
60bf38e1 02/22/2011 06:22 pm Vangelis Koukis

Split initial_data.json, minor fixes in models.py.

Split initial_data.json into different fixtures, one for each model.
Fixtures can be loaded as needed using the loaddata command.
See the README for all the details.

Add a complete set of instances for the Flavor model....

c92af313 02/22/2011 03:41 pm Vangelis Koukis

Minor fixes in VM model and db_controller.py

Added comments for VirtualMachine attributes pertaining
to internal operating state (ACTIONS, OPER_STATES, etc.).

Minor fixes in db_controller.py.

52194743 02/22/2011 01:57 pm Vangelis Koukis

Update fixtures, introduce created/updated fields.

Introduce auto-generated created/updated fields in all models,
use two different fixtures, one for db initialization, one for testing. * All models have created/updated fields. * VirtualMachine model has an owner field....

29833195 02/22/2011 01:09 pm Christos Psaltis

moved fixtures to proper folder db/fixtures

6a94c3c4 02/22/2011 01:05 pm Christos Psaltis

renamed fixtures file so it can be called automatically

43d8f0e4 02/21/2011 04:53 pm Vassilios Karakoidas

Corrected a comment in Flavor.find_cost()

8bda0440 02/21/2011 04:49 pm Vassilios Karakoidas
  • Removed FlavorCostHistoryTestCase
  • Migrated find_cost test in FlavorTestCase
  • Moved FlavorCostHistory.find_cost() -> Flavor.find_cost()
1583f11a 02/21/2011 04:01 pm Vassilios Karakoidas
  • Moved Limit.get_limit_from_user() to SynnefoUser.get_limit()
  • CreditAllocatorTestCase is modified accordingly to check the new method
104c3c5f 02/21/2011 12:50 pm Markos Gogoulos

fixed previous commit problems. removed UserLimit from admin.py, since no UserLimit model is on the models.py

62c6d260 02/21/2011 01:52 am Vassilios Karakoidas
  • Implemented VirtualMachine.get_accounting_logs()
  • Added VirtualMachineTestCase unit test
  • Now the db_test_data adds AccountingLog entries for 1003 VM (also introduced some corrections in Disk models data
  • Working on the charger which is still completelly broken (along with the related test case)
df9dc46b 02/20/2011 11:43 pm Vassilios Karakoidas
  • Minor comment corrections
e3bc2088 02/20/2011 11:30 pm Vassilios Karakoidas
  • Unit tests are greatly simplified
  • All unit tests are using fixtures
e4c395b7 02/20/2011 11:26 pm Vassilios Karakoidas
  • Added AccountingLog entries to db_test_data.json
  • AccountingLogTestCase is corrected and works as intended
ec08e9ce 02/20/2011 11:18 pm Vassilios Karakoidas
  • Add db/fixtures/db_test_data.json fixture (data for testing)
da46c52a 02/20/2011 11:17 pm Vassilios Karakoidas
  • Fixed a bug in FlavorTestCase
8922a5a9 02/20/2011 11:15 pm Vassilios Karakoidas
  • FlavorTestCase now works correctly with the fixtures
e48404ca 02/20/2011 11:12 pm Vassilios Karakoidas
  • FlavorCostHistoryTestCase now loads the fixtures and works correctly
d39ea372 02/20/2011 10:59 pm Vassilios Karakoidas
  • Removed initial_data JSON fixture
  • Fixtures are now loaded on unittesting as intended
  • Modified CreditAllocatorTestCase to load fixtures
90b28517 02/20/2011 10:26 pm Vassilios Karakoidas

CreditAllocator now uses Limit according to the changes to the model

  • CreditAllocatorTestCase has been modified to match the new requirements
  • CreditAllocatorTestCase also test Limit.get_limit_for_user() method
f51e7b50 02/20/2011 09:53 pm Vassilios Karakoidas

Added comment in FlavorCostHistory.find_cost(), also made a minor optimisation

2d45374d 02/20/2011 09:39 pm Vassilios Karakoidas

Models are modified to use limit through the model

  • Removed models Limit, UserLimit and replaced them with Limit (new) that use choices instead from many-to many relationship
  • Removed max_violations, quota from SynnefoUser
9071888e 02/18/2011 02:24 pm Constantinos Venetsanopoulos

Initial Disk Management API (DM API) implementation

The DM API is accessible under api/v1.0grnet1/ and
it extends the Rackspace Cloud Servers v1.0 API
for the use of Disks. Notable changes:

  • Added the "Disk" model in db/models.py
  • Added the "DiskHandler" in api/handlers.py...
f0f4edac 02/18/2011 12:51 pm Vassilios Karakoidas

Adding/Correcting comments

0e1fbceb 02/18/2011 12:37 pm Vassilios Karakoidas

now Flavor._update_costs uses hasattr

e2b0ffec 02/18/2011 12:54 am Vassilios Karakoidas

Merge branch 'master' of https://code.grnet.gr/git/synnefo

9e9db964 02/18/2011 12:53 am Vassilios Karakoidas

fix bug in CreditAllocatorTestCase (bad data initialisation)

f1220c03 02/17/2011 07:16 pm Markos Gogoulos

documentation

b86e97ed 02/16/2011 11:58 pm Vassilios Karakoidas

AccountingLog test is finished; most charger-related operations are ready and tested

dddb0035 02/16/2011 10:53 pm Vassilios Karakoidas

Setup/TearDown AccountingLogTestCase is finished

9373e677 02/16/2011 10:21 pm Vassilios Karakoidas

VM owner is derived from the Image

a34d0602 02/16/2011 09:08 pm Vassilios Karakoidas

FlavorCostHistoryTestCase is complete

5cb8d769 02/16/2011 08:58 pm Vassilios Karakoidas

Flavor.get_price_list() should query with filter, not get

6d6b83a3 02/16/2011 08:50 pm Vassilios Karakoidas

FlavorTestCase works as intended; Add FlavorCostHistoryTestCase (in progress)

3846dfd0 02/16/2011 08:26 pm Vassilios Karakoidas

remove obsolete tests; introduce various corrections/additions in models

f81c2077 02/16/2011 07:29 pm Vassilios Karakoidas

datetime.datetime.now is a function, so use datetime.datetime.now()

37c42c95 02/16/2011 07:10 pm Vassilios Karakoidas

added violations concept

91509aed 02/16/2011 07:00 pm Vassilios Karakoidas

remove rcredit local variable; credits can have negative value

c5fb1b95 02/16/2011 06:59 pm Vassilios Karakoidas

simplified SynnefoUser a little; remove _total_hours

55f1006f 02/15/2011 06:01 pm Vassilios Karakoidas

user can now have negative amount of credits

5db87ed5 02/15/2011 01:21 am Vangelis Koukis

Make ZMQ thread in db_controller stoppable.

Make db_controller run all 0mq operations in a separate StoppableThread
with a stop() method. The main thread calls it, then publishes on an in-proc
PUB socket to interrupt any zmq_recv() call and join the thread when cleaning...

53827f6d 02/14/2011 10:36 am Markos Gogoulos

creation of ImageMetadata model

00d83c42 02/11/2011 04:45 pm Markos Gogoulos

added get_vmid on Image model to return the first VMs id, if any. This was the serverid variable

58cac9ab 02/11/2011 02:34 pm Vassilios Karakoidas

unit testing now works for CreditAllocator

3f53219b 02/11/2011 02:23 pm Vassilios Karakoidas

updated initial data to test credit allocator testcase

7dc44117 02/11/2011 01:13 pm Vassilios Karakoidas

Merge branch 'master' of https://code.grnet.gr/git/synnefo

6496c622 02/11/2011 01:12 pm Vassilios Karakoidas
  • minor changes in models and tests (db)
0a2964a1 02/10/2011 06:45 pm Vangelis Koukis

Merge branch 'master' of https://code.grnet.gr/git/synnefo

78d9b6b7 02/10/2011 06:42 pm Vangelis Koukis

Private fields in VM model, updated fixtures

Updated names of fields pertaining to VM state in VirtualMachine model,
updated fixtures.

database.sqlite can be removed, use:

rm database.sqlite; python manage.py syncdb

to recreate it from fixtures.

5db7630e 02/10/2011 05:51 pm Vassilios Karakoidas

Merge branch 'master' of https://code.grnet.gr/git/synnefo

21f59a5d 02/10/2011 12:35 pm Vangelis Koukis

Use zmq_recv() in dedicated thread in db_controller.

It seems Python can only do signal processing in the main thread.
If the main thread calls zmq_recv(), no exceptions get raised
when a SIGINT is received for example.

WIP:
This moves the zmq_recv() to a separate thread, while the main...

562549e3 02/10/2011 12:24 pm Vassilios Karakoidas

Fix: fixtures now works correctly

86221fd5 02/09/2011 09:31 am Panos Louridas

Fix path issue.

d08a5f6f 02/08/2011 11:32 pm Vangelis Koukis

What commit b4141604 should have contained.

The proper contents of commit b4141604 are included here.


b4141604 02/08/2011 06:21 pm Vangelis Koukis

Major fixes trying to integrate everything.

Most notable changes:
  • db/db_controller.py: Listens on 0mq, receives notifications from Ganeti, updates
    VM state in database calling methods of the VirtualMachine model.
  • Extended the VirtualMachine model:
    start_action() is to be called before submitting requests to Ganeti....
5abfb207 02/07/2011 11:56 pm Vassilios Karakoidas
  • Fix unit tests in db app
6ce6dee1 02/07/2011 06:57 pm Markos Gogoulos

added User ForeignKey on Image

a31ff6cb 02/07/2011 05:46 pm Markos Gogoulos

initialization of VirtualMachineGroup and VirtualMachineGroupHandler that lists/creates/deletes VirtualMachineGroups

these are groups of virtual machines for a User

61b80d9a 02/06/2011 10:48 pm Vassilios Karakoidas
  • Charger now works properly
bfd0754e 02/06/2011 01:05 am Vassilios Karakoidas

Add all custom commands

9ee31b09 02/06/2011 12:45 am Vassilios Karakoidas

Add charge_users command

d4d3f2d4 02/05/2011 10:46 pm Vassilios Karakoidas

rename creditalloc -> credit_alloc

027ce194 02/05/2011 09:50 pm Vassilios Karakoidas

Added command to invoke credit allocation for users

20f15623 02/05/2011 09:21 pm Vassilios Karakoidas

tests should work now

d7c1ed72 02/05/2011 09:18 pm Vassilios Karakoidas

rename dbcontrol and charger into proper python name

b670157f 02/05/2011 09:16 pm Vassilios Karakoidas

rename to proper python names

7bd0ac17 02/04/2011 04:32 pm Vassilios Karakoidas

Add test case about the virtual machine model (only data are generated so far).

04a6d900 02/04/2011 03:43 pm Vassilios Karakoidas
  • Add unit testing for Charger
0b5a51f7 02/04/2011 01:37 pm Vassilios Karakoidas
  • Enforcing PEP-8 in models.py
1d722015 02/04/2011 01:36 pm Vassilios Karakoidas
  • Enchance FlavorTest and fixed a bug in Flavor
e8fa4283 02/04/2011 12:30 pm Vassilios Karakoidas
  • Add tests for Flavor model
  • cost_active and cost_inactive are now returned correctly
90d311a7 02/04/2011 11:58 am Vassilios Karakoidas
  • Add one more test to CreditAllocatorTestCase class
cb2e4505 02/04/2011 11:51 am Vassilios Karakoidas
  • Added test for credit allocator
2ce7420d 02/03/2011 10:18 pm Vassilios Karakoidas
  • Charger now works; need testing
05a90a5b 02/03/2011 09:57 pm Vassilios Karakoidas
  • Messing with the Flavor and FlavorCostHistory; define two new properties to easily obtain active and inactive costs
e107ee57 02/03/2011 03:23 pm Markos Gogoulos

a few changes on the handlers in order to work with the rapi (since we now have access).

f5ad2956 02/03/2011 02:40 pm Markos Gogoulos

removed id_from_instance function from the VirtualMachine model and put it back since it will be needed as a global function
to be imported by handlers and not as a staticmethod of the VM model.

224b5e19 02/03/2011 02:25 pm Markos Gogoulos

changed name of ganeti_id and prefix to backend_id and backend_prefix_id