{"id":14008049,"url":"https://github.com/DGKSK8LIFE/redisql","last_synced_at":"2025-07-24T03:31:41.873Z","repository":{"id":46581240,"uuid":"378488739","full_name":"DGKSK8LIFE/redisql","owner":"DGKSK8LIFE","description":"SQL to Redis caching made easy","archived":false,"fork":false,"pushed_at":"2021-11-29T00:23:38.000Z","size":916,"stargazers_count":63,"open_issues_count":6,"forks_count":14,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-07T09:42:53.045Z","etag":null,"topics":["go","golang","hacktoberfest","hacktoberfest2021","mysql","postgres","redis","sql"],"latest_commit_sha":null,"homepage":"https://dev.to/tarekali/how-i-solved-mysql-to-redis-caching-with-go-3lf7","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/DGKSK8LIFE.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-06-19T19:20:09.000Z","updated_at":"2025-04-01T05:52:45.000Z","dependencies_parsed_at":"2022-09-17T11:01:04.565Z","dependency_job_id":null,"html_url":"https://github.com/DGKSK8LIFE/redisql","commit_stats":null,"previous_names":["dgksk8life/redis-sql"],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/DGKSK8LIFE/redisql","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DGKSK8LIFE%2Fredisql","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DGKSK8LIFE%2Fredisql/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DGKSK8LIFE%2Fredisql/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DGKSK8LIFE%2Fredisql/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DGKSK8LIFE","download_url":"https://codeload.github.com/DGKSK8LIFE/redisql/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DGKSK8LIFE%2Fredisql/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266789207,"owners_count":23984248,"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","status":"online","status_checked_at":"2025-07-24T02:00:09.469Z","response_time":99,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"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":["go","golang","hacktoberfest","hacktoberfest2021","mysql","postgres","redis","sql"],"created_at":"2024-08-10T11:01:11.155Z","updated_at":"2025-07-24T03:31:41.588Z","avatar_url":"https://github.com/DGKSK8LIFE.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\t\u003cimg src=\"./banner.png\" width=\"100%\"/\u003e \n\u003c/div\u003e\n\n\u003cdiv align=\"center\"\u003e\n\t\u003ca href=\"https://pkg.go.dev/github.com/DGKSK8LIFE/redisql\"\u003e\n\t\t\u003cimg src=\"http://godoc.org/github.com/DGKSK8LIFE/redisql?status.svg\"/\u003e\n\t\u003c/a\u003e\n\t\u003ca href=\"https://discord.gg/RfZU9dp9ts\"\u003e\n\t\t\u003cimg src=\"https://img.shields.io/discord/884452044566577182?color=738ADB\u0026label=discord\u0026style=flat-square\" /\u003e\n\t\u003c/a\u003e\n\u003c/div\u003e\n\n---\n\n## Example Usage\n\n## CLI\n\n### Installation and Configuration: \n\n```bash\ngo install github.com/DGKSK8LIFE/redisql/redisql\n```\n\nCreate a YAML file with the following structure:\n\n```yaml\nsqltype:\nsqluser: \nsqlpassword: \nsqldatabase:\nsqlhost:\nsqlport:\nsqltable:\nredisaddr:\nredispass:\nlog_level:\nlog_filenane:\n```\n(`log_level` and `log_filename` are optional. Default logging is none and default output is `stdout`)\n\nLogging Levels: \n- `0` - no logging at all\n- `1` - summary of actions being performed by redisql \n- `2` - all actions (including individual keys and their values being performed by redisql\n\n### Usage:\n\n```bash\n# copy to redis string\nredisql copy -type=string -config=pathtofile.yml \n\n# copy to redis list\nredisql copy -type=list -config=pathtofile.yml\n\n# copy to redis hash\nredisql copy -type=hash -config=pathtofile.yml\n```\n\n## Library\n\n### Installation:\n\n```bash\ngo get github.com/DGKSK8LIFE/redisql\n```\n### Usage:\n\n```go\npackage main\n\nimport (\n    \"github.com/DGKSK8LIFE/redisql\"\n)\n\nfunc main() {\n\tconfig := redisql.Config{\n\t\tSQLType:     \"mysql\",\n\t\tSQLUser:     \"root\",\n\t\tSQLPassword: \"password\",\n\t\tSQLDatabase: \"users\",\n\t\tSQLHost:     \"localhost\",\n\t\tSQLPort:     \"3306\",\n\t\tSQLTable:    \"user\",\n\t\tRedisAddr:   \"localhost:6379\",\n\t\tRedisPass:   \"\",\n\t}\n\terr := config.CopyToString()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}\n```\n\n### Other Methods:\n\n```go\n// copy to redis list\nconfig.CopyToList()\n\n// copy to redis hash\nconfig.CopyToHash()\n```\n\n## Contributing \n\nCheck out [CONTRIBUTING](CONTRIBUTING.md)\n\n## Current Functionality and Limitations\n\n- [x] Copying of entire SQL tables to Redis via CLI and Go Module \n- [x] Support for most commonly used Redis data types (strings, lists, hashes)\n- [X] Support for Postgres and MySQL\n- [x] Advanced logging with levels and optional file output\n- [ ] Autosync\n- [ ] Dockerization\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDGKSK8LIFE%2Fredisql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FDGKSK8LIFE%2Fredisql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDGKSK8LIFE%2Fredisql/lists"}