{"id":15821304,"url":"https://github.com/flexoid/go-utils","last_synced_at":"2025-04-01T06:37:55.630Z","repository":{"id":140080637,"uuid":"165538510","full_name":"flexoid/go-utils","owner":"flexoid","description":"Golang utils and helpers","archived":false,"fork":false,"pushed_at":"2019-01-13T18:51:32.000Z","size":2,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-10-12T07:47:18.994Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/flexoid.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-01-13T18:15:43.000Z","updated_at":"2019-01-13T18:51:34.000Z","dependencies_parsed_at":null,"dependency_job_id":"327a5994-86ff-45df-a519-49279b67385c","html_url":"https://github.com/flexoid/go-utils","commit_stats":{"total_commits":1,"total_committers":1,"mean_commits":1.0,"dds":0.0,"last_synced_commit":"65743e0971d8dec30730944b3925576de465ff6f"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexoid%2Fgo-utils","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexoid%2Fgo-utils/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexoid%2Fgo-utils/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexoid%2Fgo-utils/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/flexoid","download_url":"https://codeload.github.com/flexoid/go-utils/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246598151,"owners_count":20802973,"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":[],"created_at":"2024-10-05T07:21:31.856Z","updated_at":"2025-04-01T06:37:55.611Z","avatar_url":"https://github.com/flexoid.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![GoDoc](https://godoc.org/github.com/flexoid/go-utils?status.svg)](https://godoc.org/github.com/flexoid/go-utils)\n\nThe collection of helper functions, utils and code snippets that can be useful\nfor my golang projects.\n\n# Content\n\n## `go-utils/logging`\n\n[logging.RequestLogger](https://godoc.org/github.com/flexoid/go-utils/logging#RequestLogger)\n\nA middleware function that logs request start and request end with zerolog.\nA logger instance is taken from the request context.\n\n```\n2019-01-13T18:46:34.488192Z |INFO| Request started req_id=bgtof2ml0s1adiaerc70\n2019-01-13T18:46:35.035226Z |INFO| Request completed bytes=3326 elapsed_ms=547.028988 http_method=GET remote_addr=[::1]:61052 req_id=bgtof2ml0s1adiaerc70 status_code=200 uri=http://localhost:4000/api/users/123 user_agent=HTTPie/0.9.9\n```\n\n```\n{\"level\":\"info\",\"req_id\":\"bgtoflul0s1afn7goou0\",\"time\":\"2019-01-13T18:47:51.118414Z\",\"message\":\"Request started\"}\n{\"level\":\"info\",\"req_id\":\"bgtoflul0s1afn7goou0\",\"status_code\":200,\"http_method\":\"GET\",\"uri\":\"http://localhost:4000/api/users/123\",\"remote_addr\":\"[::1]:61079\",\"user_agent\":\"HTTPie/0.9.9\",\"bytes\":3326,\"elapsed_ms\":477.652781,\"time\":\"2019-01-13T18:47:51.596075Z\",\"message\":\"Request completed\"}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflexoid%2Fgo-utils","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflexoid%2Fgo-utils","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflexoid%2Fgo-utils/lists"}