Statistics
| Branch: | Tag: | Revision:

root / snf-django-lib / snf_django / utils @ 4267cb32

# Date Author Comment
2e90e666 02/24/2014 12:49 pm Christos Stavrakakis

Replace use of 'udec' with 'smart_unicode'

b1f6aea8 02/13/2014 04:20 pm Giorgos Korfiatis

snf_django: Factor out resource reconcile

Generalize the checks operated during resource reconciliation so that they
can be used in all Synnefo components.

Adapt checks for user/project limits, include checks for project limits.

78e1f8da 02/13/2014 04:20 pm Sofia Papagiannaki

pithos: Add support for project originated quota

Introduce ``project`` container policy. The value of this policy denotes
the project from which the container quota originate.

Further changes:
  • domain argument in get_{account|container|object}_meta backend methods...
14402edc 01/24/2014 07:12 pm Christos Stavrakakis

cyclades: Validate fields of API requests

Make sure that all fields of a request (user input) have a valid type.
This commit validates 'ports', 'servers' and 'floating_ips' APIs.

Refs #4979

ba777b02 01/23/2014 03:44 pm Giorgos Korfiatis

cyclades: Detach serial from resource when resolved

2aba7764 12/03/2013 02:44 pm Sofia Papagiannaki

snf_django: Change error status code if request method is not valid

Return 405 (NotAllowed) instead of 400 (BadRequest)
Add Allow header in the response containing the list of valid methods

83157287 11/25/2013 01:13 pm Dionysis Grigoropoulos

Add a new function to assert success code 201

  • Add assertSuccess201 function
  • Use this new function in test/subnets.py
a1dae38d 11/12/2013 01:34 pm Christos Stavrakakis

Merge branch 'feature-cyclades-networks' into develop

Conflicts:
snf-cyclades-app/synnefo/api/management/commands/server-inspect.py
snf-cyclades-app/synnefo/app_settings/urls.py
snf-cyclades-app/synnefo/logic/backend.py
snf-cyclades-app/synnefo/logic/backend_allocator.py...

f019f93d 10/29/2013 05:10 pm Ilias Tsitsimpis

Fix pep8 errors

45c0bcf8 10/29/2013 04:15 pm Giorgos Korfiatis

astakosclient: Separate public/private POST /tokens

Introduce function authenticate(), which performs POST /tokens in
private mode, i.e. giving a token to be checked for authentication.
Function get_endpoints() performs the call in public mode, in order
to retrieve the endpoints....

b4b82ec4 10/29/2013 04:15 pm Giorgos Korfiatis

astakos: Remove call GET /authenticate

Use POST /tokens to authenticate. Delete AstakosClient.get_user_info()
and replace its uses by AstakosClient.authenticate().

ef57e622 10/29/2013 03:37 pm Ilias Tsitsimpis

django-lib: Use the new AstakosClient

2ef199c9 10/14/2013 05:42 pm Dionysis Grigoropoulos

django-lib: Add assertConflict (409) in testing.py

fde2c1f7 10/14/2013 03:51 pm Christos Stavrakakis

cyclades: Fix the os-floating-ips API

Rewrite the of-floating-ips API to match with the new DB schema.

5b8a9240 10/10/2013 08:08 pm Christos Stavrakakis

cyclades: Fix and add new tests for /networks

Also, delete tests for old networks.

6b256427 10/01/2013 06:56 pm Christos Stavrakakis

Request Django=>1.4, <1.5

Drop support for Django 1.2. Remove compatibility code that were used in
order to support Django 1.2 and 1.4. Finally update django documentation
link in the docs.

0a70d2c5 10/01/2013 06:16 pm Christos Stavrakakis

Merge branch 'hotfix-0.14.8' into develop

Merge hotfix-0.14.8 which ports Synnefo to wheezy and Django 1.4.5

Conflicts:
ci/ci_squeeze.conf
ci/ci_wheezy.conf
ci/schemas/one_node_squeeze/packages.conf
ci/schemas/one_node_squeeze/squeeze.conf
ci/schemas/one_node_squeeze/wheezy.conf...

b64a6cb5 09/30/2013 01:35 pm Sofia Papagiannaki

snf_django: Decode the mocked userid to a unicode object

a6b17d33 09/24/2013 05:16 pm Christos Stavrakakis

wheezy: urls module doesn't export defaults

2c6ac437 09/24/2013 12:30 pm Christos Stavrakakis

Fix missing import and broken test

dcb8545f 09/24/2013 11:39 am Christos Stavrakakis

snf-django: Add missing import

3f9db536 09/24/2013 10:55 am Christos Stavrakakis

snf-django: pep8 fixes

7f59d209 09/23/2013 05:03 pm Christos Stavrakakis

snf-django: pep8 fixes

c9a2aff3 09/23/2013 01:39 pm Christos Stavrakakis

snf_django: Fix encoding in mocked userid

ed2064f8 09/18/2013 05:17 pm Christos Stavrakakis

Merge branch 'hotfix-0.14.6' into develop

Conflicts:
Changelog
docs/admin-guide.rst
snf-cyclades-app/synnefo/api/management/commands/network-remove.py
snf-cyclades-app/synnefo/api/servers.py
snf-cyclades-app/synnefo/api/tests/servers.py
snf-cyclades-app/synnefo/logic/backend.py...

f2080d16 09/17/2013 02:33 pm Christos Stavrakakis

cyclades: Mock vm removal if creation fails

In case creating a VM fails before the OP_INSTANCE_CREATE job is
enqueued in Ganeti, the VM and its NICs must be deleted, and the
resources must be released from Quotaholder, which is exactly what is
done when a VM is deleted from Ganeti. Instead of duplicating the code,...

347b2ba1 09/12/2013 06:26 pm Giorgos Korfiatis

common: Strip trailing slash from endpoints

Remove trailing slash from the endpoints' publicURL field in service
definitions. These values end up in the response of POST /tokens, and,
according to the keystone API, should not end in slash. A trailing slash...

6ee6677e 08/08/2013 05:17 pm Sofia Papagiannaki

pithos: Add tests

3a19e99b 07/02/2013 04:56 pm Sofia Papagiannaki

pithos: update tests

f3787696 07/02/2013 04:23 pm Sofia Papagiannaki

pithos: WIP - rewrite pithos tests

41a7fae7 07/02/2013 12:31 pm Christos Stavrakakis

cyclades: Major refactor to api and logic apps

Major refactor to cyclades api and logic apps that removes most code
from the api views and moves it to logic app, so that the same logic
code can be used by different apps (e.g. EC2 API). Code is moved into...

f724142f 07/02/2013 12:31 pm Christos Stavrakakis

snf_django: Fix bug in BaseAPITest

Include 202 in success responses.

e5a47968 07/02/2013 12:31 pm Christos Stavrakakis

snf_django: Mock quotaholder to BaseAPITest

Mock quotaholder in all of BaseAPITest calls.

2ad4eb80 06/17/2013 01:35 pm Kostas Papadimitriou

django-lib: Additional BaseAPITest helper assertion

Introduce assertMethodNotAllowed method in BaseAPITest class. The method
asserts that provided response is a valid ``Method not allowed`` API response.

67c10753 06/13/2013 12:37 pm Kostas Papadimitriou

djangolib: Improve root redirect handling

- avoid registering root url in case <base_path> equals to root url
- additional helper redirect for non trailing slash <base_path> endpoint

2ea43f58 06/13/2013 11:38 am Kostas Papadimitriou

djangolib: Append trailling slash on default root redirects

b657485d 06/05/2013 08:31 pm Kostas Papadimitriou

django_lib: Component's urlpatterns utilty

extend_with_root_redirects can be used by components to easily extend the
registered urlpatterns with utility redirect views for the root urls.

aba462a2 05/16/2013 02:55 pm Giorgos Korfiatis

astakos: Adapt tests to 2.6-style unittest

Define assertGreater, assertIn, assertRaises in snf_django.utils.testing

27899d6f 05/09/2013 03:13 pm Christos Stavrakakis

Improve mocked quotaholder

Mock 'resolve_commissions' call.

184a2a8c 04/30/2013 05:05 pm Christos Stavrakakis

Mock quotaholder for Cyclades tests

Create 'mocked_quotaholder' context manager to bypass commission and use
it in Cyclades tests. Also this commit does some various fixes to other
tests.

d2b8ec7b 04/08/2013 11:07 am Christos Stavrakakis

Move common test code to snf_django.lib.testing