{"id":10742954,"url":"https://github.com/dailymuse/gzap","last_synced_at":"2026-01-14T19:10:55.407Z","repository":{"id":57510436,"uuid":"110159946","full_name":"dailymuse/gzap","owner":"dailymuse","description":"⚡ Graylog integrated Zap  logger","archived":false,"fork":false,"pushed_at":"2020-12-16T03:05:37.000Z","size":326,"stargazers_count":11,"open_issues_count":0,"forks_count":5,"subscribers_count":33,"default_branch":"main","last_synced_at":"2026-01-12T15:05:57.618Z","etag":null,"topics":["gelf","golang","graylog","logger","ops","zap"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dailymuse.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":"2017-11-09T19:56:41.000Z","updated_at":"2024-10-03T05:13:07.000Z","dependencies_parsed_at":"2022-09-26T20:00:31.975Z","dependency_job_id":null,"html_url":"https://github.com/dailymuse/gzap","commit_stats":null,"previous_names":["dailymuse/gml"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/dailymuse/gzap","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dailymuse%2Fgzap","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dailymuse%2Fgzap/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dailymuse%2Fgzap/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dailymuse%2Fgzap/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dailymuse","download_url":"https://codeload.github.com/dailymuse/gzap/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dailymuse%2Fgzap/sbom","scorecard":{"id":317149,"data":{"date":"2025-08-11","repo":{"name":"github.com/dailymuse/gzap","commit":"5d21e9045448d4dbee16d61ad6af2e9bc33ebbab"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.2,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Code-Review","score":5,"reason":"Found 6/11 approved changesets -- score normalized to 5","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: BSD 3-Clause \"New\" or \"Revised\" License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 28 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-18T00:28:18.947Z","repository_id":57510436,"created_at":"2025-08-18T00:28:18.947Z","updated_at":"2025-08-18T00:28:18.947Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28431606,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T18:57:19.464Z","status":"ssl_error","status_checked_at":"2026-01-14T18:52:48.501Z","response_time":107,"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":["gelf","golang","graylog","logger","ops","zap"],"created_at":"2024-06-05T06:02:42.654Z","updated_at":"2026-01-14T19:10:55.386Z","avatar_url":"https://github.com/dailymuse.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"# gzap - Graylog Integrated Zap Logger\n\n[![GoDoc](https://godoc.org/github.com/dailymuse/gzap?status.svg)](https://godoc.org/github.com/dailymuse/gzap) [![CircleCI](https://circleci.com/gh/dailymuse/gzap.svg?style=svg)](https://circleci.com/gh/dailymuse/gzap) [![Go Report Card](https://goreportcard.com/badge/github.com/dailymuse/gzap)](https://goreportcard.com/report/github.com/dailymuse/gzap)\n\nGzap provide fast structured leveled logging using [zap](https://github.com/uber-go/zap), and a TCP/UDP Graylog logsink (TLS supported). Both [zap](https://github.com/uber-go/zap) and [Graylog](https://github.com/Devatoria/go-graylog) librarys are versioned locked within the applications so no other external dependencies required. \n\n### Getting Stated\n\nTo use gzap, first import it:\n\n```go\nimport \"gopkg.in/dailymuse/gzap.v1\"\n```\n\n\u003e The Graylog logsink is only enabled for Production and Staging environments. So you'll need to set a `GRAYLOG_ENV` environment variable with either of the following correlating states.\n\nGRAYLOG_ENV | Environment  | Graylog enabled?\n--- | --- | ---\n0 | Test (no-op logger) | ❌\n1 | Dev | ❌\n2 | Staging | ✅\n3 | Production | ✅\n\n\n### Environment Variables\n\nTo properly use `gzap` you'll need to set your configurations via Environment variables. The following are configurable Envs:\n\nEnv Name | Description\n--- | --- |\nGRAYLOG_ENV | A number 0 - 3 describing the Graylog loggin environment you wish to use (Refrence table above)\nGRAYLOG_HOST | Hostname that your graylog is currently listening on `example.graylog.com`\nENABLE_DATADOG_JSON_FORMATTER | set to \"true\" to enable json formatted logs.\n\n\n### Internal API\nThe logger that is publicly exposed is the zap [Logger](https://godoc.org/go.uber.org/zap#Logger). You can reference what log levels are available for use [here](https://godoc.org/go.uber.org/zap#Logger)). Below are a few examples:\n\n```\nfunc (log *Logger) DPanic(msg string, fields ...zapcore.Field)\nfunc (log *Logger) Debug(msg string, fields ...zapcore.Field)\nfunc (log *Logger) Error(msg string, fields ...zapcore.Field)\nfunc (log *Logger) Fatal(msg string, fields ...zapcore.Field)\nfunc (log *Logger) Info(msg string, fields ...zapcore.Field)\nfunc (log *Logger) Panic(msg string, fields ...zapcore.Field)\nfunc (log *Logger) Warn(msg string, fields ...zapcore.Field)\n```\n\nAll zap [fields](https://godoc.org/go.uber.org/zap/zapcore#Field) needed for logging are also exposed by gzap.\n\n```go\ngzap.Logger.Error(\"this is an example Error log\",\n        gzap.String(\"variable\", \"some-variable-here\"),\n)\n```\n\nFor any other information please take a look at the gzap [Godoc](https://godoc.org/github.com/dailymuse/gzap).\n\n### Example Usage\n\n```go\npackage main\n\nimport (\n    \"time\"\n\n    \"gopkg.in/dailymuse/gzap.v1\"\n)\n\nfunc main() {\n    // Instantiate a global logger.\n    if err := gzap.InitLogger(); err != nil {\n        panic(err)\n    }\n\n    // Example Info log.\n    gzap.Logger.Info(\"this is an example Info log\",\n        gzap.String(\"process name\", \"some-fake-name\"),\n        gzap.Int64(\"expectedDocs\", int64(255)),\n        gzap.Int64(\"docsUploaded\", int64(100)),\n    )\n\n    // Example Error log.\n    gzap.Logger.Error(\"this is an example Error log\",\n        gzap.Error(errors.New(\"example error\")),\n        gzap.String(\"index name\", \"my-full-index-name\"),\n        gzap.Float64(\"time elapsed\", float64(1002)),\n    )\n\n    // Example Debug log.\n    gzap.Logger.Debug(\"this is an example Debug log\",\n        gzap.String(\"variable\", \"some-variable-here\"),\n    )\n}\n```\n\n### Important info\n\n#### Contributing\n\nIn order to contribute you'll need to have a valid go environment setup.\n\n\u003e If you need to install go, see installation instructions [here](https://golang.org/doc/install#install).\n\n##### Tests Logs are a no-op\n\nTests that run application code containing logs will not print those logs by default. The Test logger is a no-op to reduce noise during testing.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdailymuse%2Fgzap","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdailymuse%2Fgzap","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdailymuse%2Fgzap/lists"}