{ "info": { "author": "Allan Caffee", "author_email": "allan.caffee@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 2 - Pre-Alpha", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: MacOS :: MacOS X", "Operating System :: POSIX", "Programming Language :: Python", "Topic :: Database" ], "description": "==========\nScalyMongo\n==========\n:Author: Allan Caffee \n\nAbout\n=====\n\nThe ScalyMongo package is a set of tools to simplify the development of large\nscale distributed software utilizing MongoDB.\n\nProject Status\n==============\n\nScalyMongo is still in Pre-Alpha development and is not yet ready to be deployed\nin the wild.\n\nKey Priciples\n=============\n\nScalyMongo is intended to help developers in the following ways:\n\n * **scalability**: ScalyMongo makes it easy to write software intended to work efficiently on sharded MongoDB deployments. Internal checks warn developers when their queries or inserts are liable to perform poorly on sharded collections.\n\n * **simplicity**: ScalyMongo makes interacting with your documents easier by providing a simple Python-friendly document interface.\n\n * **flexibility**: ScalyMongo doesn't try to be everything for everyone. Where necessary users can interact directly with the underlying PyMongo driver.\n\n\nGetting Started\n===============\n\nBelow is simple example of a sharded collection of blog posts\n\n>>> from scalymongo import Document, Connection\n\n>>> class BlogPost(Document):\n... structure = {\n... 'author': basestring,\n... 'title': basestring,\n... 'body': basestring,\n... 'unique_views': int,\n... 'comments': [{\n... 'author': basestring,\n... 'comment': basestring,\n... 'rank': int,\n... }],\n... }\n... indexes = [{\n... 'fields': ['author', 'title'],\n... 'shard_key': True,\n... 'unique': True,\n... }]\n... __database__ = 'blog'\n... __collection__ = 'blog_posts'\n...\n\nThe example above describes the structure for a blog post. Notice that we\ndeclared a unique index on the ``author`` and ``title`` fields. The index\nhasn't actually been created yet, but knowing what indexes exist allow\nScalyMongo to warn you about potentially poor choices in queries. Also notice\nthat we declared this index to be used as the shard key.\n\nNow that we've got a simple document class let's create a sample post.\n\n>>> conn = Connection(\"localhost\", 27017)\n>>> post = conn.models.BlogPost()\n>>> post['author'] = 'Allan'\n>>> post['title'] = 'My first post'\n>>> post['body'] = \"Well, I don't actually have anything to write about...\"\n>>> post.save()\n\nGreat! Now we've got our first blog post. Now let's look Allan's post up to\nmake sure it was really saved.\n\n>>> conn.models.BlogPost.find_one({'author': 'Allan'})\nTraceback (most recent call last):\n ...\nscalymongo.errors.GlobalQueryException: Some or all of the shard key was not specified. Missing fields were title.\n\nWhat happended!? Remember that we declared a shard key on the ``author`` and\n``title`` fields? ScalyMongo noticed that we trying to query without having the\nfull shard key. This means that the query might potentially have to hit *every*\nshard in our cluster to find the one document we were looking for. That's\nprobably not what we wanted to do, and it certainly wouldn't be something we\nwould want to occur on a regular basis in a production cluster. Let's refine\nour query a bit so that it doesn't hit every shard.\n\n>>> conn.models.BlogPost.find_one({'author': 'Allan', 'title': 'My first post'})\n{u'_id': ObjectId('4deb90e41717953527000000'),\n u'author': u'Allan',\n u'body': u\"Well, I don't actually have anything to write about...\",\n u'title': u'My first post'}\n\nAnd sure enough that's our first post. Of course sometimes we *really do* want\nto find something even if we don't have the full shard key. Sometimes this is\nuseful during development to look up documents from the interactive console. We\ncan just override ScalyMongo's recomendations and force the query anyway:\n\n>>> conn.models.BlogPost.find_one({'author': 'Allan'}, allow_global=True)\n{u'_id': ObjectId('4deb90e41717953527000000'),\n u'author': u'Allan',\n u'body': u\"Well, I don't actually have anything to write about...\",\n u'title': u'My first post'}\n\nTake *that* best practices!\n\nWell that's it for our basic overview of ScalyMongo. Coming soon is a more\nin-depth introduction.\n\n\nSpecial Thanks\n==============\n\nScalyMongo was heavily influenced by the semantics and interface of the popular\ndatabase framework MongoKit_. Special thanks go to Namlook and all of the\ndevelopers who have contributed to MongoKit.\n\n.. _MongoKit : https://github.com/namlook/mongokit", "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/allancaffee/scaly-mongo", "keywords": "mongo sharding db", "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "scalymongo", "package_url": "https://pypi.org/project/scalymongo/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/scalymongo/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/allancaffee/scaly-mongo" }, "release_url": "https://pypi.org/project/scalymongo/0.2.0/", "requires_dist": null, "requires_python": null, "summary": "A scaling-centric MongoDB object document mapper", "version": "0.2.0" }, "last_serial": 799266, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "26206a787fa4b5a1394979f4cb5be1d6", "sha256": "237b886441c64b9ece03a4cdbfc4381dac7e499927982be159922144774ccbb3" }, "downloads": -1, "filename": "scalymongo-0.1.0.tar.gz", "has_sig": false, "md5_digest": "26206a787fa4b5a1394979f4cb5be1d6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11764, "upload_time": "2011-07-17T17:12:57", "url": "https://files.pythonhosted.org/packages/47/d3/2c2b20d6c5294146edec34ec9be9b5b821656751f57f16e42c20cc5f50fd/scalymongo-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "65c20433b0456a5012fcf1c66f038bcd", "sha256": "05ca70697951cab452493c7e4705abd593ecab91c9189129e5da3a0c5cc943d5" }, "downloads": -1, "filename": "scalymongo-0.1.1.tar.gz", "has_sig": false, "md5_digest": "65c20433b0456a5012fcf1c66f038bcd", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11925, "upload_time": "2011-08-30T22:57:09", "url": "https://files.pythonhosted.org/packages/e1/65/98ac08b8e48a24ca86f24d0ab72d11ca462c2e14bcba4125d688db7ff92e/scalymongo-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "fb2af947d736d9d2ff8ca4d0657545ef", "sha256": "ed57c9d80f07b4c9d1891ef659da072c6c80e12dddc2f109f8372cead8233050" }, "downloads": -1, "filename": "scalymongo-0.1.2.tar.gz", "has_sig": false, "md5_digest": "fb2af947d736d9d2ff8ca4d0657545ef", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11947, "upload_time": "2011-09-16T21:00:23", "url": "https://files.pythonhosted.org/packages/5f/ba/21fb5a588094f6c4e57394342ac189149714e44ad9ca9ab6c5df09c927fb/scalymongo-0.1.2.tar.gz" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "057257fe76ad7a4934485d10e64ed088", "sha256": "1905a15c7c8b82d9183bb773b56d1b965f3c07c8d4bbcad45cc51ebd4e752ebc" }, "downloads": -1, "filename": "scalymongo-0.1.3.tar.gz", "has_sig": false, "md5_digest": "057257fe76ad7a4934485d10e64ed088", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12274, "upload_time": "2011-09-22T03:05:57", "url": "https://files.pythonhosted.org/packages/2f/f9/65696f32ad4a86978dd4870df11e9024752ddd4a2f9ca917e1ab3fb805c6/scalymongo-0.1.3.tar.gz" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "0f17d4ae912d4505351102e6245e509e", "sha256": "58ff92730ff90af74986eb2e01fa8bb74cd0b5bbdafd37dcd5e395e139357da5" }, "downloads": -1, "filename": "scalymongo-0.1.4.tar.gz", "has_sig": false, "md5_digest": "0f17d4ae912d4505351102e6245e509e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13260, "upload_time": "2011-10-16T22:05:58", "url": "https://files.pythonhosted.org/packages/ba/ab/7389444c18e002d5c53d992e106f36246ba774ed8b9d52f092ae7f0ed926/scalymongo-0.1.4.tar.gz" } ], "0.1.5": [ { "comment_text": "", "digests": { "md5": "15c76785b8a4ee2f8c6ce5e8837feab6", "sha256": "55afaa18217cb8b6d053e9e799106f5015f5e08924a6ecf537a21c8b2b8ce433" }, "downloads": -1, "filename": "scalymongo-0.1.5.tar.gz", "has_sig": false, "md5_digest": "15c76785b8a4ee2f8c6ce5e8837feab6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13889, "upload_time": "2012-01-02T21:32:03", "url": "https://files.pythonhosted.org/packages/6d/54/db70e8d6f17cae68d525896d445d5025d2b9f097ad451083bba2a6f9fa66/scalymongo-0.1.5.tar.gz" } ], "0.1.6": [ { "comment_text": "", "digests": { "md5": "40a8b6389bfca4fca3509b9cdcecb240", "sha256": "d97073d640c1c125e8503d1525d9de0c71e99ae573b089579749183f4cf8e127" }, "downloads": -1, "filename": "scalymongo-0.1.6.tar.gz", "has_sig": false, "md5_digest": "40a8b6389bfca4fca3509b9cdcecb240", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14503, "upload_time": "2012-01-12T05:13:18", "url": "https://files.pythonhosted.org/packages/34/6d/0e2f0a4195eb47c23d1d211db69580c5da3f4357e529cb1f034fb86df765/scalymongo-0.1.6.tar.gz" } ], "0.1.7": [ { "comment_text": "", "digests": { "md5": "8e49e740131bcdbb0ab63d0e1c9db165", "sha256": "9e7b29d56b9a82bee2956e69bca46d69e52336fc9e35bc8fa6d82edfdd0e790b" }, "downloads": -1, "filename": "scalymongo-0.1.7.tar.gz", "has_sig": false, "md5_digest": "8e49e740131bcdbb0ab63d0e1c9db165", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15189, "upload_time": "2012-02-27T14:45:39", "url": "https://files.pythonhosted.org/packages/0e/4e/231e7ee2a5f859a4d77f66434d8a799ff2c131ed8cce0b30e5831137ee48/scalymongo-0.1.7.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "387a7ddf4e1a37e3c0c5b0b0f233db72", "sha256": "5c76ec0ee1496f241fd2a4543a4dad87c6fa4a0b286b2bfea97510282a0b0428" }, "downloads": -1, "filename": "scalymongo-0.2.0.tar.gz", "has_sig": false, "md5_digest": "387a7ddf4e1a37e3c0c5b0b0f233db72", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14750, "upload_time": "2013-04-09T19:42:59", "url": "https://files.pythonhosted.org/packages/4b/ee/a626aa42858ebe8c7168aacfb5e05b532166b047c0f12f0d541982d88fd3/scalymongo-0.2.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "387a7ddf4e1a37e3c0c5b0b0f233db72", "sha256": "5c76ec0ee1496f241fd2a4543a4dad87c6fa4a0b286b2bfea97510282a0b0428" }, "downloads": -1, "filename": "scalymongo-0.2.0.tar.gz", "has_sig": false, "md5_digest": "387a7ddf4e1a37e3c0c5b0b0f233db72", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14750, "upload_time": "2013-04-09T19:42:59", "url": "https://files.pythonhosted.org/packages/4b/ee/a626aa42858ebe8c7168aacfb5e05b532166b047c0f12f0d541982d88fd3/scalymongo-0.2.0.tar.gz" } ] }