def process(slug): authz.require(authz.source_write(slug)) source = obj_or_404(Source.by_slug(slug)) process_collection.delay(source.slug) return jsonify({'status': 'ok'})
def process(collection_name, force=False): """ Index all documents in the given collection. """ process_collection.delay(collection_name, overwrite=force)