aboutsummaryrefslogtreecommitdiff
path: root/app/handlers/defconf.py
AgeCommit message (Collapse)Author
2014-10-16handlers: Make instance method into static one, refactor.Milo Casagrande
* Turn _valid_keys into a static method for all handlers. * Use in batch handlers the valid keys defined in common. * Change the JSON serializer using the default one, and change how mongodb Cursor results are stored (should be slightly faster). Change-Id: I17cf26d9011e34125bf6873edda7179a5202aa39
2014-10-15handlers: Use the newly defined keys and values.Milo Casagrande
* Refactor handlers code to use the newly defined keys. Change-Id: Ib14578bd1f2a57297b2296a0c1d12824700c9f2e
2014-09-08count: Trivia change to status message.Milo Casagrande
Change-Id: I2665b62993a5865e13cb16d9dfe0357676592eef
2014-07-31Massive refactoring.Milo Casagrande
* Will break the frontend. * Rework BaseHandler in order for that to handle all the async calls setup, and leave the subclasses to implement just the correct methods. * TokenHandler is a special case, since we need special token protection for that. * Fix db.py so that it returns plaun mongodb objects (Cursor) and store them as is: they are iteratable. * Make HandlerResponse the only accepted response type to create the response that is sent to the clients. * Fixe, rework and add tests. Change-Id: Ief7dad65b2801f701e7e5f67b3a360329aca69f6
2014-05-16Use more predefined keys.Milo Casagrande
2014-05-15Fix created attribute.Milo Casagrande
* Apparently, mongodb internally has a field called 'created', that collides with the 'created' attribute we have in the models. Sort operations on that field returned weird results when you drop the DB and re-import everything and are expecting to see the real documents date. * Rename created models attribute into created_on, and move it into the base model. * Fix tests.
2014-05-13Extend valid GET keys.Milo Casagrande
2014-05-13Add doc string.Milo Casagrande
2014-04-25Handle aggregate, add more valid GET keys.Milo Casagrande
* Handle the aggregate query on the BaseHandler. * Add more valid GET keys for job and defconfig. * Fix a test.
2014-04-23Fix and clean-up handlers.Milo Casagrande
2014-04-11Fix DELETE for DefconfigHandler.Milo Casagrande
* Fix error calling utils.db.delete, missing an argument. * Add unittest for DELETE.
2014-04-10Defconf handler DELETE does not have payload.Milo Casagrande
* Since it does not need to have a payload, remove the valid keys for a DELETE payload for this handler.
2014-04-09Fix DELETE method for SubscriptionHandler, other fixes.Milo Casagrande
* DELETE should not contain any payload, but for the SubscriptionHandler we make an exception since we want to be able to 'unsubscribe' just a single email from the document. * Reowrk check methods in the parent class, and add new check for headers and content type. * Fix other handlers, and tests as well.
2014-04-07Fix typo in accepted JSON keys.Milo Casagrande
2014-04-07Implement _delete method.Milo Casagrande
2014-04-04Add DELETE support for defconfig handler.Milo Casagrande
2014-03-28PEP8/pylint clean-up.Milo Casagrande
2014-03-25Fix properties and methods.Milo Casagrande
2014-03-24Abstract GET method into base handler.Milo Casagrande
* Implement query for a single document by id. * GET method is now defined into the BaseHandler class, inherited by all handlers. * Subclassed handlers need to define a property to retrieve the mongodb collection where documents are stored.
2014-03-24First commit.Milo Casagrande