{ "info": { "author": "Andy Gayton", "author_email": "andy@thecablelounge.com", "bugtrack_url": null, "classifiers": [], "description": "Fity3\n-----\n\nFity3 is a Twitter snowflake like scheme generator that fits in 53 bits.\n\n.. image:: https://travis-ci.org/cablehead/python-fity3.svg?branch=master\n :target: https://travis-ci.org/cablehead/python-fity3\n\nIts scheme is::\n\n timestamp | worker_id | sequence\n 41 bits | 8 bits | 4 bits\n\n`Twitter's snowflake scheme\n`_ for id generation has a\nbunch of nice properties. An enormous number of roughly-sorted ids can be\ncreated per second in an uncoordinated manner.\n\nHowever it's *painful* working with 64 bit integers in environments that use\nIEEE 754 floating points for numerics. Particularly `JavaScript\n`_ and the\n`scores for Redis' sorted sets\n`_.\n\nThis scheme allows for:\n\n * 69 years of ids (the same as snowflakes)\n * at most 256 unique id generating workers\n * each worker can produce at most 16 ids per millisecond\n * so at most 4 million ids per second\n\nIf you're building a system in the sweet spot of not being too popular that\nusage will grow to creating more than 4 million new things a second but you\ncould benefit from uncoordinated incrementing id generation and don't want to\npunch yourself in the face every time you request data over a websocket from\nJavaScript, this scheme might be a useful alternative.\n\n.. code:: python\n\n >>> import fity3\n >>> f3 = fity3.generator(1)\n >>> next(f3)\n 14127739136\n >>> next(f3)\n 14132125952\n >>> next(f3)\n 14135079168\n\n # convenience to convert to a unix timestamp\n >>> fity3.to_timestamp(14135079168)\n 1413374250\n\nLet's just hope we won't be the ones supporting any of these systems in 2079.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/cablehead/python-fity3", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "python-fity3", "package_url": "https://pypi.org/project/python-fity3/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/python-fity3/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/cablehead/python-fity3" }, "release_url": "https://pypi.org/project/python-fity3/0.7/", "requires_dist": null, "requires_python": null, "summary": "Fity3 is a Twitter snowflake like scheme generator that fits in 53 bits.", "version": "0.7" }, "last_serial": 1384127, "releases": { "0.6": [ { "comment_text": "", "digests": { "md5": "83858bb546dc76d5fc092dc306d452c6", "sha256": "f62465bb444dbf709193d6db6ab6f349b87af8230c57a136bf0dc31cf4b40c8b" }, "downloads": -1, "filename": "python-fity3-0.6.tar.gz", "has_sig": false, "md5_digest": "83858bb546dc76d5fc092dc306d452c6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3968, "upload_time": "2014-10-15T20:35:25", "url": "https://files.pythonhosted.org/packages/1c/3e/d68739bf0b14af28f7f6562174a16620c8cfede36449f2a2034f85b4cc08/python-fity3-0.6.tar.gz" } ], "0.7": [ { "comment_text": "", "digests": { "md5": "6528e67f1ad1bd1673de4259c1fe0597", "sha256": "0adcf212a53f5a3fb3e888236a02fba7855855d1f8ecd2e0b8869a4778f381e7" }, "downloads": -1, "filename": "python-fity3-0.7.tar.gz", "has_sig": false, "md5_digest": "6528e67f1ad1bd1673de4259c1fe0597", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3985, "upload_time": "2015-01-15T21:58:26", "url": "https://files.pythonhosted.org/packages/e7/6f/ca5041a6b98bdcca039b21d9e6794b83e7f101777de5adda4a75b05564fd/python-fity3-0.7.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "6528e67f1ad1bd1673de4259c1fe0597", "sha256": "0adcf212a53f5a3fb3e888236a02fba7855855d1f8ecd2e0b8869a4778f381e7" }, "downloads": -1, "filename": "python-fity3-0.7.tar.gz", "has_sig": false, "md5_digest": "6528e67f1ad1bd1673de4259c1fe0597", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3985, "upload_time": "2015-01-15T21:58:26", "url": "https://files.pythonhosted.org/packages/e7/6f/ca5041a6b98bdcca039b21d9e6794b83e7f101777de5adda4a75b05564fd/python-fity3-0.7.tar.gz" } ] }