{"id":18656628,"url":"https://github.com/zendesk/large_object_store","last_synced_at":"2025-06-28T17:03:23.139Z","repository":{"id":8517640,"uuid":"10131359","full_name":"zendesk/large_object_store","owner":"zendesk","description":"Store large objects in memcache or others by slicing them.","archived":false,"fork":false,"pushed_at":"2024-01-26T22:06:06.000Z","size":69,"stargazers_count":22,"open_issues_count":0,"forks_count":6,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-04-26T00:09:18.198Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zendesk.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2013-05-17T20:19:55.000Z","updated_at":"2024-05-29T20:26:46.469Z","dependencies_parsed_at":"2024-01-26T22:46:27.329Z","dependency_job_id":null,"html_url":"https://github.com/zendesk/large_object_store","commit_stats":null,"previous_names":["anamartinez/large_object_store"],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zendesk%2Flarge_object_store","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zendesk%2Flarge_object_store/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zendesk%2Flarge_object_store/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zendesk%2Flarge_object_store/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zendesk","download_url":"https://codeload.github.com/zendesk/large_object_store/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248458382,"owners_count":21107066,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-11-07T07:24:28.485Z","updated_at":"2025-04-11T18:31:00.610Z","avatar_url":"https://github.com/zendesk.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"Store large objects in memcache or others by slicing them.\n - uses read_multi for fast access\n - returns nil if one slice is missing\n - low performance overhead, only uses single read/write if data is below 1MB\n\nInstall\n=======\n\n```Bash\ngem install large_object_store\n```\n\nUsage\n=====\n\n```Ruby\nRails.cache.write(\"a\", \"a\"*10_000_000) # =\u003e false -\u003e oops too large\n\nstore = LargeObjectStore.wrap(Rails.cache)\nstore.write(\"a\", \"a\"*10_000_000)  # =\u003e true -\u003e always!\nstore.read(\"a\").size              # =\u003e 10_000_000 using multi_get\nstore.read(\"b\")                   # =\u003e nil\nstore.fetch(\"a\"){ \"something\" }   # =\u003e \"something\" executes block on miss\nstore.write(\"a\" * 10_000_000, compress: true)                # compress when greater than 16k\nstore.write(\"a\" * 1000, compress: true, compress_limit: 100) # compress when greater than 100\nstore.write(\"a\" * 1000, raw: true)                           # store as string to avoid marshaling overhead\n```\n\nzstd\n====\n\n[zstd compression](https://engineering.fb.com/2016/08/31/core-data/smaller-and-faster-data-compression-with-zstandard/), a modern improvement over the venerable zlib compression algorithm, is supported by passing the `zstd` flag when writing items:\n\n```\nstore.write(\"a\" * 10_000_000, compress: true, zstd: true)\n```\n\nFor backwards compatibility and to enable safe roll-out of the change in working systems, the `zstd` flag defaults to `false`.\n\nzstd decompression is used when the zstd magic number is detected at the beginning of compressed data, so `zstd: true` does not need to be passed when reading/fetching items.\n\nAuthor\n======\n[Ana Martinez](https://github.com/anamartinez)\u003cbr/\u003e\nacemacu@gmail.com\u003cbr/\u003e\n[Michael Grosser](https://github.com/grosser)\u003cbr/\u003e\nmichael@grosser.it\u003cbr/\u003e\nLicense: MIT\u003cbr/\u003e\n[![CI](https://github.com/anamartinez/large_object_store/actions/workflows/actions.yml/badge.svg)](https://github.com/anamartinez/large_object_store/actions/workflows/actions.yml)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzendesk%2Flarge_object_store","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzendesk%2Flarge_object_store","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzendesk%2Flarge_object_store/lists"}