{"id":19723612,"url":"https://github.com/nitrogen/mutagen","last_synced_at":"2026-06-09T18:31:32.578Z","repository":{"id":194539331,"uuid":"691264577","full_name":"nitrogen/mutagen","owner":"nitrogen","description":"Erlang mutex server (originally built for Nitrogen, but usable anywhere)","archived":false,"fork":false,"pushed_at":"2023-09-13T20:50:46.000Z","size":9,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-11-20T19:24:45.741Z","etag":null,"topics":["erlang","mutex"],"latest_commit_sha":null,"homepage":"","language":"Erlang","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/nitrogen.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}},"created_at":"2023-09-13T20:33:24.000Z","updated_at":"2023-09-14T12:16:38.000Z","dependencies_parsed_at":"2023-09-14T00:24:18.177Z","dependency_job_id":null,"html_url":"https://github.com/nitrogen/mutagen","commit_stats":null,"previous_names":["nitrogen/mutagen"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nitrogen/mutagen","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitrogen%2Fmutagen","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitrogen%2Fmutagen/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitrogen%2Fmutagen/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitrogen%2Fmutagen/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nitrogen","download_url":"https://codeload.github.com/nitrogen/mutagen/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nitrogen%2Fmutagen/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34121021,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-09T02:00:06.510Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["erlang","mutex"],"created_at":"2024-11-11T23:22:53.363Z","updated_at":"2026-06-09T18:31:32.558Z","avatar_url":"https://github.com/nitrogen.png","language":"Erlang","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Mutagen\n\nMutagen is a simple mutex server for the [Nitrogen Web\nFramework](http://nitrogenproject.com).  It was previously part of [Nitro\nCache](https://github.com/nitrogen/nitro_cache) but has been pulled out and\ngeneralized in case a more generalized mutex system is needed for Erlang and/or\nNitrogen users.\n\n## Add to your rebar.config\n\n```erlang\n{deps, [\n\tmutagen\n]}.\n```\n\n## Make sure you start it\n\nEither:\n\n* Add it to the `applications` list in your `.app.src` file, or\n* Start it manually with `application:ensure_all_started(mutagen).`\n\n## Usage\n\nMutagen has a few very simple functions, once the server is running.\n\n* `lock(Key) -\u003e fail | success`:  Attempt to lock the mutex `Key`. If the mutex\n  is successfully locked, the call will return `success`.  If the mutex is\n  already locked, the mutex will return `fail`.\n\n* `lock(Key, Timeout) -\u003e fail | success`: Attempt the lock mutex `Key`,\n  however, if the mutex is currently already locked, the call will stall and\n  wait up to `Timeout` milliseconds before giving up and returning `fail`.\n\n* `wait(Key) -\u003e free`: Only return when the mutex identified by `Key` is free.\n  This does not then lock the mutex, it merely returns when it's available.\n\n* `wait(Key, Timeout) -\u003e free | not_free`: Only returns `free` when the mutex\n  identified by `Key` is free, or if the mutex is not free after `Timeout`\n  milliseconds, return `not_free`.\n\n* `status() -\u003e StatusInfo`:  Returns a proplist of information related to the\n  number of mutexes that are currently locked, the number of processes queued\n  to lock an already locked mutex, and the number of processes waiting for the\n  mutex to be free.\n\n## About\n\nApache 2.0 License\n\nCopyright 2023 Jesse Gumm\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnitrogen%2Fmutagen","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnitrogen%2Fmutagen","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnitrogen%2Fmutagen/lists"}