{ "info": { "author": "MeusPedidos Engineering Team", "author_email": "israel.bgf@gmail.com, jorge.klemm@hotmail.com, cleberben.warmling@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "# mysql-binlog-explorer\n\nMySQL binlogs are the foundation for replication, but them can be useful for tracking intense write operations on database when using `binlog_format=ROW`. With that we can see all the changes that are actually applied to the database. For example: a statement like `delete from table where timestamp > ?` could affect just 3 or 1 million rows. Besides that, sometimes we have tons of very fast statements, but when composed together in a transaction it can takes lots of time.\n\nThis application aims to aid in tracking which transactions are being too write intensves.\n\n## Usage (simplified)\n\n```\npip install mysql-binlog-explorer\nmysql-binlog-explorer ~/logs/mysql-bin-changelog.411078 --tenant-identifier company_id --schema-ddl schema/my_db.ddl\n```\n\nWe have two not required parameters (but they are quite useful).\n\n- `schema-ddl` is a file with the DDL instructions to create the database. It'll be use used to show the column names in the statements. \n- `tenant-identifier` the name of a column which is used to store the tenant id (usually a column name that repeats across every table). This will aid in the generated charts.\n\n## Usage (the real deal)\n\n- Enable binlog (configuration varies depending on environment)\n- Enable row format for binlog: `binlog_format=ROW`\n- This kind o change needs to restart the server so **be careful**\n\nGiven that you already have a local mysql installation with `brew`, doing the above steps would mean:\n\n```\nmysql.server start --log-bin=binlog --binlog-format=ROW\n```\n\nNow you need the actual logs. In a MySQL session do the following:\n\n```sql\nSHOW BINARY LOGS; -- get the name of the binary log that you want to check\n``` \n\nNow download it:\n\n```\nmysqlbinlog -h -u -p --read-from-remote-server --base64-output=decode-rows -vv > my-bin-log.txt\n```\n\n**Don't forget the** `--base64-output=decode-rows -vv`, it's mandatory for the parser to work!\n\nNow just use it.\n\n```\nmysql-binlog-explorer my-bin-log.txt\n```\n\n## Screenshot\n\n![image](https://user-images.githubusercontent.com/771129/42190310-c3e6ba1e-7e32-11e8-941a-cebb80ad009c.png)\n\nWhen the tenant information is used, the app can plot a chart with transactions/changes distribution per tenant identifier.\n\n## Caveats\n\n- Tested only with MySQL 5.6 binlogs, other versions may not work as expected.\n- The result of the parsing is stored entirely in-memory, so it may crash for very large file sets.", "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/meuspedidos/mysql-binlog-explorer", "keywords": "mysql binlog analysis ui web explore", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "mysql-binlog-explorer", "package_url": "https://pypi.org/project/mysql-binlog-explorer/", "platform": "", "project_url": "https://pypi.org/project/mysql-binlog-explorer/", "project_urls": { "Homepage": "https://github.com/meuspedidos/mysql-binlog-explorer" }, "release_url": "https://pypi.org/project/mysql-binlog-explorer/0.2.4/", "requires_dist": null, "requires_python": "", "summary": "Web UI to Explore MySQL's binlog files a little easier.", "version": "0.2.4" }, "last_serial": 5885860, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "073df9e4e873a3ba2a891fc6ca2adbf4", "sha256": "1e1d360615df0f71658a6c0fdc9e8beb7f044ada8ceca5d9c2b44152a092e9aa" }, "downloads": -1, "filename": "mysql-binlog-explorer-0.1.tar.gz", "has_sig": false, "md5_digest": "073df9e4e873a3ba2a891fc6ca2adbf4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 69983, "upload_time": "2018-02-09T18:15:28", "url": "https://files.pythonhosted.org/packages/e7/41/fd6104c7985ce2438df6cd575e1a075aaa620199e184a0edf1ec6dfc2ca3/mysql-binlog-explorer-0.1.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "231d3d2889192876548a6766ac518c97", "sha256": "96c8d3e0e0b1022f7e74b6346348f128c4159da48a56aad58cd334910190cbf0" }, "downloads": -1, "filename": "mysql-binlog-explorer-0.2.0.tar.gz", "has_sig": false, "md5_digest": "231d3d2889192876548a6766ac518c97", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 153517, "upload_time": "2018-04-06T21:23:10", "url": "https://files.pythonhosted.org/packages/81/fc/9e05c23f4a320b68f6dc15f942efe4e60a5d723b2a7c2ce2f45d560e2392/mysql-binlog-explorer-0.2.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "f7aa7ba66e9f9aff3e7f61c25071da32", "sha256": "504dab2d4d4d0b30edf611363dc2e0c6815b567640d133c8ebd4cd0e7d243748" }, "downloads": -1, "filename": "mysql-binlog-explorer-0.2.1.tar.gz", "has_sig": false, "md5_digest": "f7aa7ba66e9f9aff3e7f61c25071da32", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 153726, "upload_time": "2018-04-06T22:18:31", "url": "https://files.pythonhosted.org/packages/30/d3/f30098f15906a1a50a3b4d8ec2833e15b240c05607ef94be637c189730c1/mysql-binlog-explorer-0.2.1.tar.gz" } ], "0.2.3": [ { "comment_text": "", "digests": { "md5": "46f461a1f41d2cf3d56fb4b8e321945d", "sha256": "5a063c6be132d8d0f5f5fe94464d1edccb3aefc613581c1ef3f06524472ab046" }, "downloads": -1, "filename": "mysql-binlog-explorer-0.2.3.tar.gz", "has_sig": false, "md5_digest": "46f461a1f41d2cf3d56fb4b8e321945d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 155558, "upload_time": "2018-07-02T23:13:44", "url": "https://files.pythonhosted.org/packages/0f/c0/ea7857a4afcc75fc1d0cb831ff66983cfdc3c8c081dfcf33f6f7413f1783/mysql-binlog-explorer-0.2.3.tar.gz" } ], "0.2.4": [ { "comment_text": "", "digests": { "md5": "8f39eb3f4774f396ef373bc4a64fd38e", "sha256": "b699a32afcb24f7a83dc792f09cfe4589ec117957c732e6f25135db38b887ac3" }, "downloads": -1, "filename": "mysql-binlog-explorer-0.2.4.tar.gz", "has_sig": false, "md5_digest": "8f39eb3f4774f396ef373bc4a64fd38e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 154281, "upload_time": "2019-09-25T15:10:43", "url": "https://files.pythonhosted.org/packages/8a/3a/ae93d2f264932be513fcf0abab785c908950c01504a30012bc74ce9a412e/mysql-binlog-explorer-0.2.4.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "8f39eb3f4774f396ef373bc4a64fd38e", "sha256": "b699a32afcb24f7a83dc792f09cfe4589ec117957c732e6f25135db38b887ac3" }, "downloads": -1, "filename": "mysql-binlog-explorer-0.2.4.tar.gz", "has_sig": false, "md5_digest": "8f39eb3f4774f396ef373bc4a64fd38e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 154281, "upload_time": "2019-09-25T15:10:43", "url": "https://files.pythonhosted.org/packages/8a/3a/ae93d2f264932be513fcf0abab785c908950c01504a30012bc74ce9a412e/mysql-binlog-explorer-0.2.4.tar.gz" } ] }