722c3e77029c6533c17ae3591563be2caae6ea69 |
|
02-Dec-2014 |
Dan Shi <dshi@chromium.org> |
[autotest] Do not enable autocommit for server database server database may not be used by Autotest. For moblab, server database is not initialized, thus any attempt to connect to it will fail. For server_manager script, it can always call save to push the changes to database if needed. BUG=chromium:430976 TEST=local start scheduler Change-Id: I9b17a770bc0cb04e778dbf704dc63915be9fcb98 Reviewed-on: https://chromium-review.googlesource.com/232761 Commit-Queue: Dan Shi <dshi@chromium.org> Tested-by: Dan Shi <dshi@chromium.org> Reviewed-by: Simran Basi <sbasi@chromium.org>
/external/autotest/frontend/setup_django_environment.py
|
9a535c9f3144690cf85d88a51e07b98c21454159 |
|
24-Nov-2014 |
Dan Shi <dshi@chromium.org> |
[autotest] Add server database to django model. Server database is added to store information about servers running in an Autotest instance. This is the first CL to implement it. Design doc: go/chromeos-lab-serverdb-design django model uses db_router to rout database calls to different database connections: local: All AFE table calls. global: All TKO table calls. readonly: Calls from web frontend. This CL adds another router for all calls to server database to `server`. DEPLOY=migrate_server_db CQ-DEPEND=CL:230814 BUG=chromium:424778 TEST=unitest, part of the test is done by atest code that'll be in another cl. Test server database migration: ./database/migrate.py sync 0 -d AUTOTEST_SERVER_DB ./database/migrate.py sync 1 -d AUTOTEST_SERVER_DB ./database/migrate.py sync 2 -d AUTOTEST_SERVER_DB ./database/migrate.py sync 3 -d AUTOTEST_SERVER_DB python frontend/health/utils_unittest.py Change-Id: I84be386c8f5b7efd53ae1ecbd6293eae4326f19f Reviewed-on: https://chromium-review.googlesource.com/231671 Tested-by: Dan Shi <dshi@chromium.org> Reviewed-by: Fang Deng <fdeng@chromium.org> Commit-Queue: Dan Shi <dshi@chromium.org>
/external/autotest/frontend/setup_django_environment.py
|
8a764d1fb6cd99d08cda6400bd35162fa3ac5fe0 |
|
15-Oct-2014 |
Jakob Juelich <jakobjuelich@chromium.org> |
[autotest] Use global database for tko models in django v3. This adds the global database to django. A django database router is added to determine to which database should be used for which models. All tko models are always taken or written from or into the global database while all other objects remain unchanged. BUG=chromium:422637 TEST=Ran suites, syncdb, restart apache, ran a suite. Confirm global database connection is closed after each attempt to get test view: https://x20web.corp.google.com/~beeps/log/db_routers.html Change-Id: Idf6933d1d112bbc5a2896fa61afd03f6604dafb5 Reviewed-on: https://chromium-review.googlesource.com/223501 Tested-by: Dan Shi <dshi@chromium.org> Reviewed-by: Prashanth B <beeps@chromium.org> Commit-Queue: Dan Shi <dshi@chromium.org>
/external/autotest/frontend/setup_django_environment.py
|
47d61281a7b23a5e6d8c5835659b502f56108d07 |
|
17-Apr-2013 |
Alex Miller <milleral@chromium.org> |
[autotest] Bump django to 1.5. This includes a mysql-python version bump to get rid of a warning message, and a few fixes throughout the codebase to get things working again under django 1.5. TEST=AFE works, RPCs work, run_suite works, scheduler works BUG=chromium:232388 DEPLOY=apache,scheduler Change-Id: Ie0d7f5fd1203a25bdedb78d31778d8373aaf6ff5 Reviewed-on: https://gerrit.chromium.org/gerrit/48402 Reviewed-by: Scott Zawalski <scottz@chromium.org> Reviewed-by: Brian Harring <ferringb@chromium.org> Tested-by: Alex Miller <milleral@chromium.org> Commit-Queue: Alex Miller <milleral@chromium.org>
/external/autotest/frontend/setup_django_environment.py
|
fa8629c3a28b0ccebbd339218883e5e6cbb1ce16 |
|
04-Nov-2008 |
showard <showard@592f7852-d20e-0410-864c-8624ca9c26a4> |
-ensure Django connection is autocommit enabled, when used from monitor_db -fix HostScheduler to not crash when there are no ready hosts -change RebootTask to optionally take a queue entry and pass it to the RepairTask if reboot fails. This allows jobs to be failed if the pre-verify reboot fails, instead of being left hanging. -add unit test for RebootTask -add check for DB inconsistencies to cleanup step. Currently this just checks for HQEs with active=complete=1. -when unexpected existing results files are found, email a warning git-svn-id: http://test.kernel.org/svn/autotest/trunk@2368 592f7852-d20e-0410-864c-8624ca9c26a4
/external/autotest/frontend/setup_django_environment.py
|
364fe862f88bcaaefaa40dd145a777bee840ec9b |
|
17-Oct-2008 |
showard <showard@592f7852-d20e-0410-864c-8624ca9c26a4> |
Refactor the basic environment setup code out of django_test_utils.py into setup_django_environment.py, and rename django_test_utils.py to setup_test_environment.py. Also changed the environment setup code to run at import time. This makes it easy for scripts, both test and non-test, to use Django models without running through manage.py. The idea is that scripts will import setup_django_environment before importing Django code (somewhat akin to common.py), and test code will subsequently import setup_test_environment. git-svn-id: http://test.kernel.org/svn/autotest/trunk@2297 592f7852-d20e-0410-864c-8624ca9c26a4
/external/autotest/frontend/setup_django_environment.py
|