{ "info": { "author": "Renato Ramos", "author_email": "ramos.renato@outlook.com", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 3" ], "description": "# CosmosDB bulk updater\n\nA package to update a tons of documents in Microsoft CosmosDB\n\n**How it works?**\n\nIt executes a query and iterate all the items executing an update function defined by the user. This query\nwill be executed until it return any result\n\n**Usage**\n\nThe sample bellow show how to add a new field into the all database documents\n\n```python\nfrom cosmosdb_bulk_updater import BulkUpdater, Database\n\n\ndef update_document(document: dict):\n\n document['new_field'] = 'blah'\n return document\n\n\ndef run():\n database = Database(\n endpoint=\"[ENDPOINT]\",\n key=\"[YOUR_KEY]\",\n database=\"[DATABASE]\",\n collection=\"[COLLECTION]\"\n )\n\n updater = BulkUpdater(\n database=database,\n query=\"SELECT TOP 500 VALUE c FROM c where NOT IS_DEFINED(c.new_field)\"\n )\n\n updater.execute_update(\n execute_fn=update_document\n )\n\n\nif __name__ == '__main__':\n run()\n\n```\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/renato04/cosmosdb-bulk-updater", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "cosmosdb-bulk-updater", "package_url": "https://pypi.org/project/cosmosdb-bulk-updater/", "platform": "", "project_url": "https://pypi.org/project/cosmosdb-bulk-updater/", "project_urls": { "Homepage": "https://github.com/renato04/cosmosdb-bulk-updater" }, "release_url": "https://pypi.org/project/cosmosdb-bulk-updater/0.5.0/", "requires_dist": null, "requires_python": "", "summary": "A bulk updater for Microsoft CosmosDB", "version": "0.5.0" }, "last_serial": 5221475, "releases": { "0.5.0": [ { "comment_text": "", "digests": { "md5": "f66456c897ef3c37fc5194d3519ced9e", "sha256": "9465f780031bea803246c297fedd95a558e3282d46fe419bd86ec10c3f010c13" }, "downloads": -1, "filename": "cosmosdb_bulk_updater-0.5.0-py3-none-any.whl", "has_sig": false, "md5_digest": "f66456c897ef3c37fc5194d3519ced9e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4320, "upload_time": "2019-05-03T11:50:52", "url": "https://files.pythonhosted.org/packages/ff/54/9cc139aaf960ab514e020650f7f4be63bbedfccf7b701785f81303df0d77/cosmosdb_bulk_updater-0.5.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "78cc4808cd75cc3ccaa4fb87a74cce8e", "sha256": "60254f329d02c6a9052f0e9c1c9cb8f061dfa9b5717f9fdad833b00ea8f5dab2" }, "downloads": -1, "filename": "cosmosdb-bulk-updater-0.5.0.tar.gz", "has_sig": false, "md5_digest": "78cc4808cd75cc3ccaa4fb87a74cce8e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2888, "upload_time": "2019-05-03T11:50:54", "url": "https://files.pythonhosted.org/packages/c0/12/638c7f49f7495c5fa2d5f5de2a2d056698e80e2dfd1393176c7d11ee1645/cosmosdb-bulk-updater-0.5.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "f66456c897ef3c37fc5194d3519ced9e", "sha256": "9465f780031bea803246c297fedd95a558e3282d46fe419bd86ec10c3f010c13" }, "downloads": -1, "filename": "cosmosdb_bulk_updater-0.5.0-py3-none-any.whl", "has_sig": false, "md5_digest": "f66456c897ef3c37fc5194d3519ced9e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4320, "upload_time": "2019-05-03T11:50:52", "url": "https://files.pythonhosted.org/packages/ff/54/9cc139aaf960ab514e020650f7f4be63bbedfccf7b701785f81303df0d77/cosmosdb_bulk_updater-0.5.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "78cc4808cd75cc3ccaa4fb87a74cce8e", "sha256": "60254f329d02c6a9052f0e9c1c9cb8f061dfa9b5717f9fdad833b00ea8f5dab2" }, "downloads": -1, "filename": "cosmosdb-bulk-updater-0.5.0.tar.gz", "has_sig": false, "md5_digest": "78cc4808cd75cc3ccaa4fb87a74cce8e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2888, "upload_time": "2019-05-03T11:50:54", "url": "https://files.pythonhosted.org/packages/c0/12/638c7f49f7495c5fa2d5f5de2a2d056698e80e2dfd1393176c7d11ee1645/cosmosdb-bulk-updater-0.5.0.tar.gz" } ] }