{ "info": { "author": "Abhinav I", "author_email": "abhinav.qd@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "# django-master-slave-router\n---\nA simple database router that lets you route all reads to slave(s) and writes to a master database in a django project. It **DOES NOT** take care of replication nor does it handle scenarios where your databases are down/unavailable.\n\n## Installation\n\nInstall the package through pip.\n\n pip install django-master-slave-router\n\nPrerequisites:\n\n * Django >= 1.5\n\n\n## Usage\n\nAdd the following settings inside your project's **settings.py**\n\n1) Add 'master\\_slave_router' to INSTALLED\\_APPS.\n\n INSTALLED_APPS = (\n ...\n 'master_slave_router',\n )\n\n2) Add MasterSlaveRouter to DATABASE_ROUTERS\n\n DATABASE_ROUTERS = ('master_slave_router.MasterSlaveRouter')\n\n\n3) Add connection settings for slave/master databases.\n\n DATABASES = {\n 'default': {\n ...\n },\n\n 'test_slave_1': {\n ...\n },\n\n 'test_slave_2': {\n ...\n }\n }\n\n4) Specify name(s) of the master and slave connections.\n\n SLAVE_DATABASES = ('test_slave1', 'test_slave2')\n MASTER_DATABASE = 'default'\n\n\n\n## Licence\nMIT.", "description_content_type": null, "docs_url": null, "download_url": "https://github.com/code-haven/django-master-slave-router/tarball/0.1", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/code-haven/django-master-slave-router", "keywords": "django,master,slave,database,router", "license": "MIT License", "maintainer": null, "maintainer_email": null, "name": "django-master-slave-router", "package_url": "https://pypi.org/project/django-master-slave-router/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-master-slave-router/", "project_urls": { "Download": "https://github.com/code-haven/django-master-slave-router/tarball/0.1", "Homepage": "https://github.com/code-haven/django-master-slave-router" }, "release_url": "https://pypi.org/project/django-master-slave-router/0.2/", "requires_dist": null, "requires_python": null, "summary": "A simple master-slave database router that can route all reads to slave(s) and writes to a master database.", "version": "0.2" }, "last_serial": 2067926, "releases": { "0.2": [] }, "urls": [] }