{"id":24482944,"url":"https://github.com/marcy-terui/ddbc","last_synced_at":"2026-04-29T10:33:31.655Z","repository":{"id":44474919,"uuid":"77572428","full_name":"marcy-terui/ddbc","owner":"marcy-terui","description":"Amazon DynamoDB as a cache store","archived":false,"fork":false,"pushed_at":"2018-03-29T08:24:40.000Z","size":15,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-08T19:01:23.265Z","etag":null,"topics":["amazon-dynamodb","aws","cache","python"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/marcy-terui.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-12-29T01:27:42.000Z","updated_at":"2018-03-29T08:24:42.000Z","dependencies_parsed_at":"2022-09-03T09:41:01.861Z","dependency_job_id":null,"html_url":"https://github.com/marcy-terui/ddbc","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/marcy-terui/ddbc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcy-terui%2Fddbc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcy-terui%2Fddbc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcy-terui%2Fddbc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcy-terui%2Fddbc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/marcy-terui","download_url":"https://codeload.github.com/marcy-terui/ddbc/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcy-terui%2Fddbc/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32421853,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T06:29:02.080Z","status":"ssl_error","status_checked_at":"2026-04-29T06:29:00.631Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["amazon-dynamodb","aws","cache","python"],"created_at":"2025-01-21T12:15:58.598Z","updated_at":"2026-04-29T10:33:31.634Z","avatar_url":"https://github.com/marcy-terui.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"ddbc\n=======\n\n[![Version](https://img.shields.io/pypi/v/ddbc.svg)](https://pypi.python.org/pypi/ddbc)\n[![Build Status](https://img.shields.io/travis/marcy-terui/ddbc/master.svg)](http://travis-ci.org/marcy-terui/ddbc)\n[![Coverage](https://img.shields.io/coveralls/marcy-terui/ddbc.svg)](https://coveralls.io/github/marcy-terui/ddbc)\n\n# Description\n\nAmazon DynamoDB as a cache store.\n\n# Requirements\n\n- Python2.7\n- pip\n\n# Installation\n\n## PyPI\n\n```sh\npip install ddbc\n```\n\n# Setup\n\n- Create IAM Role or User\n\nPolicy example:\n\n```json\n{\n    \"Version\": \"2012-10-17\",\n    \"Statement\": [\n        {\n            \"Effect\": \"Allow\",\n            \"Action\": [\n              \"dynamodb:CreateTable\",\n              \"dynamodb:DeleteItem\",\n              \"dynamodb:GetItem\",\n              \"dynamodb:PutItem\",\n              \"dynamodb:DescribeTable\"\n            ],\n            \"Resource\": \"arn:aws:dynamodb:\u003cregion\u003e:\u003caccount-id\u003e:table/\u003ccache-table\u003e\"\n        }\n    ]\n}\n```\n\n- Create the DynamoDB table for cache\n\nScript Example:\n\n```python\n#!/usr/bin/env python\n\nimport ddbc.utils\n\nddbc.utils.create_table(\n    table_name='cache_table',\n    region='us-east-1', # optional\n    read_units=10,      # default: 5\n    write_units=10      # default: 5\n)\n```\n\n# Usage\n\n```python\nimport ddbc.cache\nimport time\n\ncache = ddbc.cache.Client(\n    table_name='cache_table',\n    region='us-east-1', # optional\n    default_ttl=100,    # default: -1 (Infinity)\n    report_error=True   # default: False\n)\ncache['foo'] = 'bar'\nprint(cache['foo']) # =\u003e 'bar'\n\ntime.sleep(100)\nprint(cache['foo']) # =\u003e None\n\ncache.set('foo', 'bar', 1000)\ntime.sleep(100)\nprint(cache['foo']) # =\u003e 'bar'\n\ndel cache['foo']\nprint(cache.get('foo', 'buz')) # =\u003e 'buz'\n```\n\nDevelopment\n-----------\n\n-   Source hosted at [GitHub](https://github.com/marcy-terui/ddbc)\n-   Report issues/questions/feature requests on [GitHub\n    Issues](https://github.com/marcy-terui/ddbc/issues)\n\nPull requests are very welcome! Make sure your patches are well tested.\nIdeally create a topic branch for every separate change you make. For\nexample:\n\n1.  Fork the repo\n2.  Create your feature branch (`git checkout -b my-new-feature`)\n3.  Commit your changes (`git commit -am 'Added some feature'`)\n4.  Push to the branch (`git push origin my-new-feature`)\n5.  Create new Pull Request\n\nAuthors\n-------\n\nCreated and maintained by [Masashi Terui](https://github.com/marcy-terui) (\u003cmarcy9114@gmail.com\u003e)\n\nLicense\n-------\n\nMIT License (see [LICENSE](https://github.com/marcy-terui/ddbc/blob/master/LICENSE))\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarcy-terui%2Fddbc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarcy-terui%2Fddbc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarcy-terui%2Fddbc/lists"}