{"id":20213710,"url":"https://github.com/go-spring/starter-go-redis","last_synced_at":"2026-01-20T16:36:27.035Z","repository":{"id":57540641,"uuid":"286021824","full_name":"go-spring/starter-go-redis","owner":"go-spring","description":"「仅发布」 go-redis 启动器 ( starter for go-redis )","archived":true,"fork":false,"pushed_at":"2022-10-09T09:39:36.000Z","size":390,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-30T08:01:52.473Z","etag":null,"topics":["go-redis","go-spring","redis"],"latest_commit_sha":null,"homepage":"https://go-spring.com","language":"Go","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/go-spring.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}},"created_at":"2020-08-08T10:28:40.000Z","updated_at":"2023-10-01T09:38:56.000Z","dependencies_parsed_at":"2023-01-19T16:45:32.454Z","dependency_job_id":null,"html_url":"https://github.com/go-spring/starter-go-redis","commit_stats":null,"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-spring%2Fstarter-go-redis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-spring%2Fstarter-go-redis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-spring%2Fstarter-go-redis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/go-spring%2Fstarter-go-redis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/go-spring","download_url":"https://codeload.github.com/go-spring/starter-go-redis/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252833918,"owners_count":21811276,"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":["go-redis","go-spring","redis"],"created_at":"2024-11-14T06:11:05.469Z","updated_at":"2026-01-20T16:36:27.028Z","avatar_url":"https://github.com/go-spring.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# starter-go-redis\n\n[English](README.md) | [中文](README_CN.md)\n\n\u003e The project has been officially released, welcome to use!\n\n`starter-go-redis` provides a Redis client wrapper based on go-redis,\nmaking it easy to integrate and use Redis in Go-Spring applications.\n\n## Installation\n\n```bash\ngo get github.com/go-spring/starter-go-redis\n```\n\n## Quick Start\n\n### 1. Import the `starter-go-redis` Package\n\nRefer to the [example.go](example/example.go) file.\n\n```go\nimport _ \"github.com/go-spring/starter-go-redis\"\n```\n\n### 2. Configure the Redis Instance\n\nAdd Redis configuration in your project’s [configuration file](example/conf/app.properties), for example:\n\n```properties\nspring.go-redis.main.addr=127.0.0.1:6379\n```\n\n### 3. Inject the Redis Instance\n\nRefer to the [example.go](example/example.go) file.\n\n```go\nimport \"github.com/redis/go-redis/v9\"\n\ntype Service struct {\n    Redis *redis.Client `autowire:\"\"`\n}\n```\n\n### 4. Use the Redis Instance\n\nRefer to the [example.go](example/example.go) file.\n\n```go\nstr, err := s.Redis.Get(r.Context(), \"key\").Result()\nstr, err := s.Redis.Set(r.Context(), \"key\", \"value\", 0).Result()\n```\n\n## Advanced Features\n\n* **Supports multiple Redis instances**: You can define multiple Redis instances in the configuration file and reference\n  them by name in your project.\n* **Support Redis extensions**: You can extend Redis functionality by implementing the `Driver` interface — see the\n  example implementation `AnotherRedisDriver`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgo-spring%2Fstarter-go-redis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgo-spring%2Fstarter-go-redis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgo-spring%2Fstarter-go-redis/lists"}