{ "info": { "author": "Luke Lu", "author_email": "junyilu@fb.com", "bugtrack_url": null, "classifiers": [], "description": "OnlineSchemaChange\n==================\n\nOnlineSchemaChange is a tool for making schema changes for MySQL tables\nin a non-blocking way\n\nExamples\n--------\n\n``OSC`` must be run on the same host as MySQL server.\n\n``copy`` mode\n~~~~~~~~~~~~~\n\nSay we have an existing table named ``my_table`` under database\n``test``:\n\n.. code:: mysql\n\n CREATE TABLE `my_table` (\n `id` int(11) NOT NULL,\n PRIMARY KEY (`id`)\n ) ENGINE=InnoDB DEFAULT CHARSET=latin1\n\nNow if we want to run\n``ALTER TABLE ``my_table`` add column ``data`` varchar(10);`` against\nit. Instead of feed the ``ALTER TABLE`` statement to OSC, we just need\nto put a ``CREATE TABLE`` statement representing the desired schema into\na file ``/tmp/foo.sql`` like below:\n\n.. code:: mysql\n\n CREATE TABLE `my_table` (\n `id` int(11) NOT NULL,\n `data` varchar(10) DEFAULT NULL,\n PRIMARY KEY (`id`)\n ) ENGINE=InnoDB DEFAULT CHARSET=latin1\n\nThen run the following command:\n\n.. code:: sh\n\n osc_cli copy --ddl-file-list=foo.sql --socket=/tmp/mysql.socket --database=test\n\n``cleanup`` mode\n~~~~~~~~~~~~~~~~\n\nTo cleanup the table left behind by last run of OSC\n\n.. code:: sh\n\n osc_cli cleanup --socket=/tmp/mysql.socket --database=test\n\nTo terminate a currently running ``OSC`` process on certain MySQL\nInstance:\n\n.. code:: sh\n\n osc_cli cleanup\n\n``direct`` mode\n~~~~~~~~~~~~~~~\n\nThis mode is reserved for utilizing MySQL's native online ddl for schema\nchange, and help DBA manage all the schema related operation into this\none tool. For now, if you plan to use ``OSC`` for all your schema\nmanagement, this mode is here for you to create a empty new table.\nFollowing command will create an empty table into database ``test``\n\n.. code:: sh\n\n osc_cli direct --ddl-file-list=foo.sql --socket=/tmp/mysql.socket --database=test\n\nRequirements\n------------\n\nOnlineSchemaChange requires\n\n**System packages**\n\nFor Python2\n\n.. code:: sh\n\n sudo apt-get install python-dev libmysqlclient-dev # Debian / Ubuntu\n sudo yum install python-devel mysql-devel # Red Hat / CentOS\n\nFor Python3\n\n.. code:: sh\n\n sudo apt-get install python3-dev # debian / Ubuntu\n sudo yum install python3-devel # Red Hat / CentOS\n\n**Python requirements** \\* python >= 2.7 \\* python module: six,\n`pyparsing `__,\n`MySQLdb `__\n\nInstalling OnlineSchemaChange\n-----------------------------\n\nRun following command to install dependency\n\n.. code:: sh\n\n python setup.py install --install-scripts=/usr/local/bin\n\nIf you have multiple python version available in your environment, or\nyou don't want mess up with system's default python, you can use\n``pyenv`` and ``virtualenv``\n\nHow OnlineSchemaChange works\n----------------------------\n\nCheck wiki page for more detail, and some advanced usage.\n\nHow to contribute\n-----------------\n\nCheck this `wiki\npage `__\nif you want to contribute to this project.\n\nLicense\n-------\n\nOnlineSchemaChange is BSD-licensed. We also provide an additional patent\ngrant.\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/facebookincubator/OnlineSchemaChange", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "online-schema-change", "package_url": "https://pypi.org/project/online-schema-change/", "platform": "", "project_url": "https://pypi.org/project/online-schema-change/", "project_urls": { "Homepage": "https://github.com/facebookincubator/OnlineSchemaChange" }, "release_url": "https://pypi.org/project/online-schema-change/0.0.1.post0/", "requires_dist": null, "requires_python": "", "summary": "Online Schema Change for MySQL", "version": "0.0.1.post0" }, "last_serial": 2896789, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "ced7c01f0bc0dcee5b435a64f5012c6a", "sha256": "a91349796b6b177ecd9f3b918e5812d741f99209c7c6dec8777a99577b9b56c7" }, "downloads": -1, "filename": "online_schema_change-0.0.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "ced7c01f0bc0dcee5b435a64f5012c6a", "packagetype": "bdist_wheel", "python_version": "3.5", "requires_python": null, "size": 84065, "upload_time": "2017-05-22T14:57:25", "url": "https://files.pythonhosted.org/packages/f5/4e/1b251f4fa88a3678d55f5e7375059dec3b7f3f53db3ca177537918d0a22c/online_schema_change-0.0.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ebcd6fa6b8863f9a589c6e3ac0fcc423", "sha256": "06cecfd32552fc74a9b61c60eeddd1f4cde896b611968b65d1d51a0d4ae54738" }, "downloads": -1, "filename": "online-schema-change-0.0.1.tar.gz", "has_sig": false, "md5_digest": "ebcd6fa6b8863f9a589c6e3ac0fcc423", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 63693, "upload_time": "2017-05-22T14:57:23", "url": "https://files.pythonhosted.org/packages/12/24/b1422055e024ec1eb7ab7a308e34128f2a5c57d2788b4cf36706659232a1/online-schema-change-0.0.1.tar.gz" } ], "0.0.1.post0": [ { "comment_text": "", "digests": { "md5": "c64980368b7ac957f4950f36eea42f3a", "sha256": "2fdfbd097c17b374bbaeafedf035578f88fcb098716abbbee83e5287345286e9" }, "downloads": -1, "filename": "online_schema_change-0.0.1.post0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c64980368b7ac957f4950f36eea42f3a", "packagetype": "bdist_wheel", "python_version": "3.5", "requires_python": null, "size": 84161, "upload_time": "2017-05-22T15:15:23", "url": "https://files.pythonhosted.org/packages/b5/cc/5ab17a28d65a0b9caac31ddb1c55532ec0f1d27652455db31c4a00f5c3fa/online_schema_change-0.0.1.post0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "4390764fd0f6b75e9a71c9921619c45e", "sha256": "4abc06d83c4ff341fe47e13e02c40bf113616ecc7a52d8bbafe73801b990448b" }, "downloads": -1, "filename": "online-schema-change-0.0.1.post0.tar.gz", "has_sig": false, "md5_digest": "4390764fd0f6b75e9a71c9921619c45e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 63714, "upload_time": "2017-05-22T15:15:21", "url": "https://files.pythonhosted.org/packages/7c/67/18f5d663c548e255c00bfe7d905d0f4d1633650ff3d6126b550aeb1d729f/online-schema-change-0.0.1.post0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c64980368b7ac957f4950f36eea42f3a", "sha256": "2fdfbd097c17b374bbaeafedf035578f88fcb098716abbbee83e5287345286e9" }, "downloads": -1, "filename": "online_schema_change-0.0.1.post0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c64980368b7ac957f4950f36eea42f3a", "packagetype": "bdist_wheel", "python_version": "3.5", "requires_python": null, "size": 84161, "upload_time": "2017-05-22T15:15:23", "url": "https://files.pythonhosted.org/packages/b5/cc/5ab17a28d65a0b9caac31ddb1c55532ec0f1d27652455db31c4a00f5c3fa/online_schema_change-0.0.1.post0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "4390764fd0f6b75e9a71c9921619c45e", "sha256": "4abc06d83c4ff341fe47e13e02c40bf113616ecc7a52d8bbafe73801b990448b" }, "downloads": -1, "filename": "online-schema-change-0.0.1.post0.tar.gz", "has_sig": false, "md5_digest": "4390764fd0f6b75e9a71c9921619c45e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 63714, "upload_time": "2017-05-22T15:15:21", "url": "https://files.pythonhosted.org/packages/7c/67/18f5d663c548e255c00bfe7d905d0f4d1633650ff3d6126b550aeb1d729f/online-schema-change-0.0.1.post0.tar.gz" } ] }