{"id":20766202,"url":"https://github.com/navono/g3log_sinks","last_synced_at":"2026-04-28T00:32:48.177Z","repository":{"id":74496585,"uuid":"83102228","full_name":"navono/g3Log_Sinks","owner":"navono","description":"这是g3Log库的sink的扩展","archived":false,"fork":false,"pushed_at":"2017-02-25T03:21:49.000Z","size":489,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-15T06:47:59.407Z","etag":null,"topics":["c","cpp"],"latest_commit_sha":null,"homepage":null,"language":"C","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/navono.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":"2017-02-25T03:10:09.000Z","updated_at":"2017-02-25T03:13:21.000Z","dependencies_parsed_at":null,"dependency_job_id":"235069c4-a2cb-44b8-8cb7-c45cd308d0e9","html_url":"https://github.com/navono/g3Log_Sinks","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/navono/g3Log_Sinks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/navono%2Fg3Log_Sinks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/navono%2Fg3Log_Sinks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/navono%2Fg3Log_Sinks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/navono%2Fg3Log_Sinks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/navono","download_url":"https://codeload.github.com/navono/g3Log_Sinks/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/navono%2Fg3Log_Sinks/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32361477,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T20:07:02.737Z","status":"ssl_error","status_checked_at":"2026-04-27T20:07:00.910Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5: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":["c","cpp"],"created_at":"2024-11-17T11:22:01.254Z","updated_at":"2026-04-28T00:32:48.163Z","avatar_url":"https://github.com/navono.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"这是[__g3log__](https://github.com/KjellKod/g3log.git)的sink的一个socket版本扩展。\n代码整体结构和g3log保持一致。只需将本目录下的文件拷贝到g3log目录下即可。\nsocket使用的[__libuv__](https://github.com/libuv/libuv.git)库。\n此目录下包含的libuv版本为1.11.1\n\n后续计划增加kafka实现\n\n\n# 注意事项\n__1.需要在使用的工程中加入以下库：__\nIphlpapi.lib\nUserenv.lib\nPsapi.lib\nws2_32.lib\n\n__2.g3log源码修改点：__\nlogworker.cpp中加入：\n```cpp\nvoid LogWorker::addSocketLogger(\n   const std::string\u0026 svrIP,\n   const unsigned int port, \n   const std::string\u0026 default_id /*= \"g3log\"*/) {\n   addSink(std::make_unique\u003cg3::socketSink\u003e(svrIP, port, default_id), \u0026socketSink::sendMessage);\n   }\n```\n\n# 使用方法\n类似和增加默认的文件log一样\n```cpp\nworker-\u003eaddSocketLogger(\"127.0.0.1\", 8899);\n```\n其他的log初始化等设置可以参照g3log工程中的示例代码。","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnavono%2Fg3log_sinks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnavono%2Fg3log_sinks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnavono%2Fg3log_sinks/lists"}