{"id":13413024,"url":"https://github.com/reugn/async","last_synced_at":"2025-04-05T16:10:21.262Z","repository":{"id":38012736,"uuid":"230590571","full_name":"reugn/async","owner":"reugn","description":"Synchronization and asynchronous computation package for Go","archived":false,"fork":false,"pushed_at":"2024-09-07T15:16:55.000Z","size":118,"stargazers_count":215,"open_issues_count":0,"forks_count":11,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-09-08T16:47:47.741Z","etag":null,"topics":["async","asynchronous","asynchronous-api","barrier","concurrency","concurrent-map","future","generics","go","lock","mutex","promise","synchronization","zero-dependency"],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/reugn/async","language":"Go","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/reugn.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}},"created_at":"2019-12-28T09:48:40.000Z","updated_at":"2024-09-07T14:57:41.000Z","dependencies_parsed_at":"2023-01-21T22:01:51.540Z","dependency_job_id":"d06adff7-45d4-456c-8797-513914c8b0d5","html_url":"https://github.com/reugn/async","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reugn%2Fasync","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reugn%2Fasync/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reugn%2Fasync/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reugn%2Fasync/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/reugn","download_url":"https://codeload.github.com/reugn/async/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247361695,"owners_count":20926643,"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":["async","asynchronous","asynchronous-api","barrier","concurrency","concurrent-map","future","generics","go","lock","mutex","promise","synchronization","zero-dependency"],"created_at":"2024-07-30T20:01:32.465Z","updated_at":"2025-04-05T16:10:21.237Z","avatar_url":"https://github.com/reugn.png","language":"Go","readme":"\u003cdiv align=\"center\" style=\"margin:0 !important;\"\u003e\u003cimg src=\"./docs/images/async.png\" /\u003e\u003c/div\u003e\n\u003cdiv align=\"center\"\u003e\n  \u003ca href=\"https://github.com/reugn/async/actions/workflows/build.yml\"\u003e\u003cimg src=\"https://github.com/reugn/async/actions/workflows/build.yml/badge.svg\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://pkg.go.dev/github.com/reugn/async\"\u003e\u003cimg src=\"https://pkg.go.dev/badge/github.com/reugn/async\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://goreportcard.com/report/github.com/reugn/async\"\u003e\u003cimg src=\"https://goreportcard.com/badge/github.com/reugn/async\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://codecov.io/gh/reugn/async\"\u003e\u003cimg src=\"https://codecov.io/gh/reugn/async/branch/master/graph/badge.svg\"\u003e\u003c/a\u003e\n\u003c/div\u003e\n\u003cbr/\u003e\nAsync is a synchronization and asynchronous computation package for Go.\n\n## Overview\n* **ConcurrentMap** - Implements the generic `async.Map` interface in a thread-safe manner by delegating load/store operations to the underlying `sync.Map`.\n* **ShardedMap** - Implements the generic `async.Map` interface in a thread-safe manner, delegating load/store operations to one of the underlying `async.SynchronizedMap`s (shards), using a key hash to calculate the shard number.\n* **Future** - A placeholder object for a value that may not yet exist.\n* **Promise** - While futures are defined as a type of read-only placeholder object created for a result which doesn’t yet exist, a promise can be thought of as a writable, single-assignment container, which completes a future.\n* **Executor** - A worker pool for executing asynchronous tasks, where each submission returns a Future instance representing the result of the task.\n* **Task** - A data type for controlling possibly lazy and asynchronous computations.\n* **Once** - An object similar to sync.Once having the Do method taking `f func() (T, error)` and returning `(T, error)`.\n* **Value** - An object similar to atomic.Value, but without the consistent type constraint.\n* **WaitGroupContext** - A WaitGroup with the `context.Context` support for graceful unblocking.\n* **ReentrantLock** - A mutex that allows goroutines to enter into the lock on a resource more than once.\n* **PriorityLock** - A non-reentrant mutex that allows for the specification of lock acquisition priority.\n\n## Examples\nCan be found in the examples directory/tests.\n\n## License\nLicensed under the MIT License.\n","funding_links":[],"categories":["Goroutines","Go","Goroutines `goroutines的管理和使用`","Relational Databases"],"sub_categories":["Search and Analytic Databases","检索及分析资料库","Advanced Console UIs","SQL 查询语句构建库"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freugn%2Fasync","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Freugn%2Fasync","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freugn%2Fasync/lists"}