{"id":18677249,"url":"https://github.com/elixir-toniq/groot","last_synced_at":"2025-12-12T00:25:05.193Z","repository":{"id":41815588,"uuid":"231961463","full_name":"elixir-toniq/groot","owner":"elixir-toniq","description":"Distributed KV store for ephemeral data","archived":false,"fork":false,"pushed_at":"2023-04-10T11:00:49.000Z","size":62,"stargazers_count":53,"open_issues_count":2,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-05-01T12:25:25.395Z","etag":null,"topics":["crdt","elixir","elixir-lang","hlc","kv-store"],"latest_commit_sha":null,"homepage":"","language":"Elixir","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/elixir-toniq.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2020-01-05T18:51:44.000Z","updated_at":"2024-04-07T10:46:48.000Z","dependencies_parsed_at":"2023-07-12T17:01:39.388Z","dependency_job_id":null,"html_url":"https://github.com/elixir-toniq/groot","commit_stats":null,"previous_names":["keathley/groot"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elixir-toniq%2Fgroot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elixir-toniq%2Fgroot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elixir-toniq%2Fgroot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elixir-toniq%2Fgroot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elixir-toniq","download_url":"https://codeload.github.com/elixir-toniq/groot/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223490176,"owners_count":17153916,"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":["crdt","elixir","elixir-lang","hlc","kv-store"],"created_at":"2024-11-07T09:33:09.298Z","updated_at":"2025-12-12T00:25:05.136Z","avatar_url":"https://github.com/elixir-toniq.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Groot\n\nI am Groot.\n\n## Usage\n\nGroot provides a distributed KV store for ephemeral data. It utilizes LWW-register\nCRDTs and Hybrid-Logical clocks to ensure availability and a level\nof consistency. For technical information on Groot's implementation, please\nrefer to the [docs](https://hexdocs.pm/groot).\n\n## Installation\n\n```elixir\ndef deps do\n  [\n    {:groot, \"~\u003e 0.1\"}\n  ]\nend\n```\n\n## Usage\n\n```elixir\n# Changes are propogated to other nodes.\n:ok = Groot.set(:key, \"value\")\n\n# Read existing values. \"Gets\" are always done from a local ETS table.\n\"value\" = Groot.get(:key)\n```\n\n`set` operations will be replicated to all connected nodes. If new nodes join, or if a node rejoins the cluster after a network partition, then the other nodes in the cluster will replicate all of their registers to the new node.\n\n## Caveats\n\nGroot relies on distributed erlang. All of the data stored in Groot is\nephemeral and is *not* maintained between node restarts.\n\nBecause we're using CRDTs to propagate changes, a change made on one node may take time to spread to the other nodes. It's safe to run the same operation on multiple nodes. Groot always chooses the register with the latest HLC.\n\nGroot replicates all registers to all nodes. If you attempt to store thousands of keys in Groot, you'll probably have a bad time.\n\n## Should I use this?\n\nIf you need to store and replicate a relatively small amount of transient\nvalues, then Groot may be a good solution for you. If you need anything beyond those features, Groot is probably a bad fit.\n\nHere are some examples of good use cases:\n\n* Feature Flags - [rollout](https://github.com/keathley/rollout) is an example of this.\n* Runtime configuration changes\n* User session state\n* Generic caching\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felixir-toniq%2Fgroot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felixir-toniq%2Fgroot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felixir-toniq%2Fgroot/lists"}