{"id":36484706,"url":"https://github.com/illiafox/grpc-lake","last_synced_at":"2026-01-12T01:44:48.058Z","repository":{"id":56854893,"uuid":"524927947","full_name":"illiafox/grpc-lake","owner":"illiafox","description":"Dead simple item lake with metrics, tracing and caching","archived":false,"fork":false,"pushed_at":"2022-10-18T12:14:58.000Z","size":251,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-01T09:33:17.392Z","etag":null,"topics":["golang","grpc","mongodb","rabbitmq","redis","sentry-io"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/illiafox.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-08-15T09:32:17.000Z","updated_at":"2023-07-29T20:55:17.000Z","dependencies_parsed_at":"2022-09-21T13:01:26.532Z","dependency_job_id":null,"html_url":"https://github.com/illiafox/grpc-lake","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/illiafox/grpc-lake","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/illiafox%2Fgrpc-lake","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/illiafox%2Fgrpc-lake/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/illiafox%2Fgrpc-lake/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/illiafox%2Fgrpc-lake/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/illiafox","download_url":"https://codeload.github.com/illiafox/grpc-lake/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/illiafox%2Fgrpc-lake/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28331253,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-12T00:36:25.062Z","status":"ssl_error","status_checked_at":"2026-01-12T00:36:15.229Z","response_time":60,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["golang","grpc","mongodb","rabbitmq","redis","sentry-io"],"created_at":"2026-01-12T01:44:47.405Z","updated_at":"2026-01-12T01:44:48.045Z","avatar_url":"https://github.com/illiafox.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"![scheme](api/scheme.png)\n\n\n### ⚠️ The project is under development, all versions until `1.0.0` are considered as not backward compatible.\n\n[![Go](https://github.com/illiafox/grpc-lake/actions/workflows/go.yml/badge.svg)](https://github.com/illiafox/grpc-lake/actions/workflows/go.yml)\n[![Docker Image CI](https://github.com/illiafox/grpc-lake/actions/workflows/docker-image.yml/badge.svg)](https://github.com/illiafox/grpc-lake/actions/workflows/docker-image.yml)\n[![golangci-lint](https://github.com/illiafox/grpc-lake/actions/workflows/golangci-lint.yml/badge.svg)](https://github.com/illiafox/grpc-lake/actions/workflows/golangci-lint.yml)\n\n### Requirements\n\n* **Redis:** `7.0`\n* **MongoDB:** `5.0`\n* **ClickHouse:** `22.6.8`\n* **RabbitMQ:** `3.10.7`\n* **Go:** `1.19`\n* **Sentry** (optional)\n\n---\n\n## Deployment\n\n```shell\nmake compose # docker-compose up\n```\n\n### Endpoints\n\n* `8080` - **gRPC**\n* `8082` - **HTTP** `/metrics`, `/debug/pprof`, `/healthcheck`\n* `6379` - **Redis** without password\n* `27017` - **MongoDB** `server:pass`\n* `15672` `5672` - **RabbitMQ** `guest:guest`\n* `8123` `9000` `9009` - **ClickHouse** `default:default`\n\n---\n\n### Protobuf files\n\n#### [Service](api/item_service/service/v1/item.proto) `service/v1/item.proto`\n\n#### [Model](api/item_service/model/v1/item.proto) `model/v1/item.proto`\n\n---\n\n### Config\n\nCopy [`.env.example`](.env.example) to `.env` and change values if needed.\nCredentials are rewritten by docker-compose. \n\nIf you want to enable **Sentry**, set `SENTRY_DSN` value.\n\nSome useful options:\n\n* `CACHE_EXPIRE=1m` Cache expiration time\n\n* `REDIS_POOL_TIMEOUT=5s`  Pool connection timeout\n* `REDIS_POOL_SIZE=-1` Pool size, `-1` means default (**10** * [`runtime.GOMAXPROCS`](https://pkg.go.dev/runtime#GOMAXPROCS))\n* `REDIS_IDLE_SIZE=-1` Idle pool connections, `-1` means default (`REDIS_POOL_SIZE` / **4**)\n\n* `RABBITMQ_XXX` - All **RabbitMQ** options (both exchange and queue)\n\n\n---\n\n### Tests\n\n* [x] Mocks\n* [x] Unit tests\n* [ ] Integration - soon\n\n``` shell\nmake test\n```\n\n### Sentry\nAll internal errors are sent to **Sentry**. If `SENTRY_DSN` is not set, they will be ignored.\n\nTracing rate is tuned by the `SENTRY_TRACING_RATE` value (default `1.0` -\u003e all traces will be sent).\n\n### Clickhouse\n```sql\nTABLE events\n(\n    timestamp DATETIME,\n    item_id   String,\n    action    String\n)\n```\n\n### Logs\n\n``` shell\n# Terminal (stdout)\n05/09 07:39:33 +0000 | INFO | app/listen.go:30 | gRPC server started {\"port\": 8080}\n05/09 07:39:33 +0000 | INFO | app/listen.go:42 | HTTP server started {\"port\": 8082}\n```\n\n``` shell\n# File (default log.txt)\n{\"level\":\"info\",\"ts\":\"Mon, 05 Sep 2022 07:39:33 UTC\",\"caller\":\"app/listen.go:30\",\"msg\":\"gRPC server started\",\"port\":8080}\n{\"level\":\"info\",\"ts\":\"Mon, 05 Sep 2022 07:39:33 UTC\",\"caller\":\"app/listen.go:42\",\"msg\":\"HTTP server started\",\"port\":8082}\n```\n\n---\n\n### Todo:\n\n* [x] Collect events logs\n* [x] Sentry\n* [ ] Add integration tests\n* [ ] Yaml config\n\n\n### Contributors\n\n* [**@ShiroNoHaga**](https://github.com/ShiroNoHaga) .env.example idea\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Filliafox%2Fgrpc-lake","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Filliafox%2Fgrpc-lake","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Filliafox%2Fgrpc-lake/lists"}