{"id":42042591,"url":"https://github.com/arpitbbhayani/levelcache","last_synced_at":"2026-01-26T05:36:51.008Z","repository":{"id":304036256,"uuid":"1016922668","full_name":"arpitbbhayani/levelcache","owner":"arpitbbhayani","description":"LevelCache is an ephemeral embedded cache with TTL support built on top of LevelDB.","archived":false,"fork":false,"pushed_at":"2025-07-11T17:25:23.000Z","size":59,"stargazers_count":54,"open_issues_count":3,"forks_count":9,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-10-19T23:38:11.551Z","etag":null,"topics":["cache","database","embedded-database","kv-store","kvstore","leveldb"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/arpitbbhayani.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"zenodo":null}},"created_at":"2025-07-09T18:28:57.000Z","updated_at":"2025-10-06T15:44:03.000Z","dependencies_parsed_at":"2025-07-11T01:12:26.298Z","dependency_job_id":"bb632360-e5fe-4ae9-b039-3cc8ce4b747c","html_url":"https://github.com/arpitbbhayani/levelcache","commit_stats":null,"previous_names":["arpitbbhayani/levelcache"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/arpitbbhayani/levelcache","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arpitbbhayani%2Flevelcache","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arpitbbhayani%2Flevelcache/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arpitbbhayani%2Flevelcache/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arpitbbhayani%2Flevelcache/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/arpitbbhayani","download_url":"https://codeload.github.com/arpitbbhayani/levelcache/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arpitbbhayani%2Flevelcache/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28767359,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-26T03:54:34.369Z","status":"ssl_error","status_checked_at":"2026-01-26T03:54:33.031Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5: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":["cache","database","embedded-database","kv-store","kvstore","leveldb"],"created_at":"2026-01-26T05:36:50.462Z","updated_at":"2026-01-26T05:36:50.993Z","avatar_url":"https://github.com/arpitbbhayani.png","language":"C","readme":"# LevelCache\n\n[![License](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)\n\nLevelCache is a high-performance, ephemeral, embedded key-value caching library written in C. It is built on top of Google's [LevelDB](https://github.com/google/leveldb) and provides a simple, clean API for caching with Time-to-Live (TTL) support.\n\n## Features\n\n- **Time-to-Live (TTL)**: Set an expiration time for each key, after which it is automatically considered invalid and deleted upon access.\n- **Memory Management**: Control the maximum memory usage of the LevelDB cache to manage your application's footprint.\n- **Simple C API**: A straightforward and easy-to-use function set for `open`, `close`, `put`, `get`, and `delete` operations.\n- **High Performance**: Optimized for fast read and write operations. See the [Performance](#performance) section for details.\n- **Well-Tested**: Includes a comprehensive test suite using the Google Test framework.\n\n## Getting Started\n\nGetting started with levelcache is simple and a step by step guide is documented in [examples](examples) directory.\n\n## Makefile Targets\n\n- `all`: Builds the `liblevelcache.a` static library.\n- `test`: Builds and runs the Google Test suite.\n- `benchmark`: Builds and runs the performance benchmark suite.\n- `clean`: Removes all build artifacts.\n\n## Performance\n\nThe following benchmarks were run on a 16-core machine with a 100MB database cache. The results are the mean of 3 repetitions.\n\nTo run the benchmarks on your own machine, use `make benchmark`.\n\n| Operation | Throughput (ops/sec) | p50 Latency | p90 Latency | p95 Latency | p99 Latency |\n|-----------|------------------------|-------------|-------------|-------------|-------------|\n| **Write** | ~224,000               | ~3.6 µs     | ~4.6 µs     | ~5.0 µs     | ~6.4 µs     |\n| **Read**  | ~2,016,000             | ~0.3 µs     | ~1.1 µs     | ~2.0 µs     | ~2.9 µs     |\n\n## Contributing\n\nContributions are welcome! Feel free to open an issue to report a bug or suggest a feature, or submit a pull request with your improvements.\n\n## License\n\nThis project is licensed under the Apache License 2.0. See the [LICENSE](LICENSE) file for details.","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farpitbbhayani%2Flevelcache","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Farpitbbhayani%2Flevelcache","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farpitbbhayani%2Flevelcache/lists"}