Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Add develover sql switch | Elrond | 2012-01-28 | 1 | -2/+9 |
| | | | | | | | | | | | | | | | | | If you want to play with the current state of sql, you need a switch to turn it on. So here is the super secret developer switch. So you want to know where it is? Here it is: Create a file mediagoblin/db/sql_switch.py and put one line in it: "use_sql = True" (or False to disable again). Right, that's it. If you want to delete it, remember to delete the *.pyc too. Be careful not to "git add" it by accident! | ||||
* | Import MigrationManager from mongo in mongo backend. | Elrond | 2012-01-04 | 1 | -1/+1 |
| | | | | | | Inside the mongo db backend, use the mongo MigrationManager. This is hopefully the last reference to the generic MigrationManager reference on db.util. | ||||
* | Move db/util.py -> db/mongo/util.py | Elrond | 2011-12-20 | 1 | -276/+2 |
| | | | | | - Change some reference - Provide a wrapper db/util.py | ||||
* | Move db/indexes.py to db/mongo/indexes.py | Elrond | 2011-12-20 | 1 | -1/+1 |
| | | | | And change references (one!). | ||||
* | has_key is deprecated, converting uses to use "in" operator. | Nathan Yergler | 2011-10-01 | 1 | -1/+1 |
| | |||||
* | Whitespace and formatting cleanup. | Nathan Yergler | 2011-10-01 | 1 | -2/+3 |
| | | | | | | | * Removed trailing whitespace * Line length < 80 where possible * Honor conventions on number of blank lines * Honor conventions about spaces around :, = | ||||
* | 508. Updates copyright/license information | Will Kahn-Greene | 2011-09-01 | 1 | -1/+1 |
| | |||||
* | Merge branch 'master' into f411_new_migrations | Christopher Allan Webber | 2011-07-13 | 1 | -3/+10 |
|\ | | | | | | | | | Conflicts: mediagoblin/db/open.py | ||||
| * | Changing things back so that we keep information about deprecated | Christopher Allan Webber | 2011-07-09 | 1 | -3/+10 |
| | | | | | | | | indexes around. | ||||
* | | Duplicate migration numbers not allowed, bro | Christopher Allan Webber | 2011-07-13 | 1 | -0/+2 |
| | | |||||
* | | We should *raise* MissingCurrentMigration :) | Christopher Allan Webber | 2011-07-13 | 1 | -1/+1 |
| | | | | | | | | Thanks for the catch, Elrond. | ||||
* | | Made it so that it's migrate_new() which installs the migration | Christopher Allan Webber | 2011-07-10 | 1 | -3/+18 |
| | | | | | | | | version if missing, migrations_to_run just throws an error if not set | ||||
* | | No reason to have migration_number optional or default to None | Christopher Allan Webber | 2011-07-10 | 1 | -1/+1 |
| | | |||||
* | | Move the call to install_migration_version_if_missing() to migrations_to_run() | Christopher Allan Webber | 2011-07-10 | 1 | -5/+7 |
| | | | | | | | | | | This means there's a serious side effect of calling this, but there's no way to get useful data here unless if that's set anyway. | ||||
* | | install_migration_version_if_missing() now a separate function | Christopher Allan Webber | 2011-07-10 | 1 | -7/+19 |
| | | | | | | | | | | Also added it to MigrationManager.migrate_new(), because we'll always need a migration number when migrating. | ||||
* | | Make sure all these strings in db/util.py are unicode | Christopher Allan Webber | 2011-07-10 | 1 | -6/+6 |
| | | |||||
* | | Simpler run_migrations method. | Christopher Allan Webber | 2011-07-10 | 1 | -16/+13 |
| | | | | | | | | | | | | | | | | Allows for calbacks, should be useful for printing output and catching things in tests. Gets rid of the generator stuff which now that I think of it is a messy idea. | ||||
* | | Making sure migration_number > 0 :) | Christopher Allan Webber | 2011-07-09 | 1 | -1/+3 |
| | | |||||
* | | run_new_migrations() makes more sense | Christopher Allan Webber | 2011-07-09 | 1 | -1/+1 |
| | | |||||
* | | Some instructions in the RegisterMigration docstring on how to use. | Christopher Allan Webber | 2011-07-09 | 1 | -0/+13 |
| | | |||||
* | | latest_migration now returns migration numbers only, and 0 if no migrations. | Christopher Allan Webber | 2011-07-09 | 1 | -6/+10 |
| | | |||||
* | | Migrating quietly, not iteratively, that comment should say! | Christopher Allan Webber | 2011-07-09 | 1 | -1/+1 |
| | | |||||
* | | New migration utility code.... I haven't tested this! ;) | Christopher Allan Webber | 2011-07-09 | 1 | -0/+136 |
|/ | | | | | | | | I think it's looking right though. - Provides MigrationManager which should have plenty of utilities for doing migrations hopefully correctly :) - Provides RegisterMigration which should be able to decorate migrations and register them in doing so | ||||
* | adds previous and next links in the sidebar | Caleb Forbes Davis V | 2011-07-02 | 1 | -1/+1 |
| | | | | | | | | Feature #401 - previous/next navigation on media pages * media.html includes a new prev_next.html template containing the links * prev_next.html calls functions added to the media model to retrieve the appropriate objects from the database, formatted with urlgen * a small change to util.py brings ASCENDING into the mix | ||||
* | Documenging index utils and adjusting how remove_deprecated_indexes gets ↵ | Christopher Allan Webber | 2011-06-27 | 1 | -2/+17 |
| | | | | | | | | | | arguments More specifically, we now just take a dictionary of lists, like: {'collection': ['index_identifier1', 'index_identifier2']} Previously we took something with more info like in add_new_indexes, but that extra info isn't really necessary. | ||||
* | Tools to add / remove indexes from collections | Christopher Allan Webber | 2011-06-27 | 1 | -0/+65 |
| | |||||
* | Move InvalidId to db.util | Elrond | 2011-06-20 | 1 | -0/+1 |
| | | | | | | Instead of import InvalidId from the low level bson module, first import it in our db.util wrapper and second import it from pymongo.errors. | ||||
* | Factor out most of the database connection into db/open.py | Elrond | 2011-05-19 | 1 | -13/+0 |
| | | | | | | | | I needed to split the db connection/opening into open.py, due to an import loop: - util.py needs db/util.py:ObjectId - db/util.py would need db/models.py - db/models.py needs util.py:slugify | ||||
* | Renaming connect_database to connect_database_from_config and using in ↵ | Christopher Allan Webber | 2011-05-18 | 1 | -1/+1 |
| | | | | from_celery | ||||
* | Need to import asint for users who specify ports via config file | Christopher Allan Webber | 2011-05-18 | 1 | -0/+2 |
| | |||||
* | Adding copyright headers and explaining why these unused imports are here | Christopher Allan Webber | 2011-05-18 | 1 | -0/+18 |
| | |||||
* | Move ObjectId, DESCENDING to db.util | Elrond | 2011-05-18 | 1 | -0/+2 |
| | | | | | | We used to import those from pymongo and mongokit directly. We should import them from a single place. So let's try db.util for this. | ||||
* | Move "connect to database" into db/util.py | Elrond | 2011-05-18 | 1 | -0/+11 |