{"id":25569469,"url":"https://github.com/baifendian/harpc","last_synced_at":"2026-01-14T03:40:20.536Z","repository":{"id":38714906,"uuid":"44308903","full_name":"baifendian/harpc","owner":"baifendian","description":"基于Thrift的跨语言、高可用、高性能、轻量级的RPC框架。","archived":false,"fork":false,"pushed_at":"2022-12-15T23:26:52.000Z","size":23700,"stargazers_count":231,"open_issues_count":10,"forks_count":125,"subscribers_count":52,"default_branch":"master","last_synced_at":"2025-07-27T17:55:50.574Z","etag":null,"topics":["cpp","java","python","thrift"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/baifendian.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":"2015-10-15T09:54:00.000Z","updated_at":"2025-06-19T02:17:44.000Z","dependencies_parsed_at":"2023-01-29T05:00:50.937Z","dependency_job_id":null,"html_url":"https://github.com/baifendian/harpc","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/baifendian/harpc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baifendian%2Fharpc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baifendian%2Fharpc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baifendian%2Fharpc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baifendian%2Fharpc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/baifendian","download_url":"https://codeload.github.com/baifendian/harpc/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baifendian%2Fharpc/sbom","scorecard":{"id":223873,"data":{"date":"2025-08-11","repo":{"name":"github.com/baifendian/harpc","commit":"8cc8128a3b42d1bbbc527daa9edf0ec9ab326468"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.6,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/27 approved changesets -- score normalized to 0","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":"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":"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":"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":"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":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: 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":"Binary-Artifacts","score":0,"reason":"binaries present in source code","details":["Warn: binary detected: admin/harpc_admin/__init__.pyc:1","Warn: binary detected: admin/harpc_admin/settings.pyc:1","Warn: binary detected: admin/harpc_admin/urls.pyc:1","Warn: binary detected: admin/harpc_admin/wsgi.pyc:1","Warn: binary detected: admin/manage/__init__.pyc:1","Warn: binary detected: admin/manage/admin.pyc:1","Warn: binary detected: admin/manage/customdecorators.pyc:1","Warn: binary detected: admin/manage/lib/ZKlib/__init__.pyc:1","Warn: binary detected: admin/manage/lib/ZKlib/core.pyc:1","Warn: binary detected: admin/manage/lib/ZKlib/harpc.pyc:1","Warn: binary detected: admin/manage/lib/__init__.pyc:1","Warn: binary detected: admin/manage/lib/harpcutils.pyc:1","Warn: binary detected: admin/manage/lib/zk_harpc.pyc:1","Warn: binary detected: admin/manage/migrations/__init__.pyc:1","Warn: binary detected: admin/manage/models.pyc:1","Warn: binary detected: admin/manage/urls.pyc:1","Warn: binary detected: admin/manage/views.pyc:1","Warn: binary detected: java/harpc/avro/avro-tools-1.7.7.jar:1"],"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":"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":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"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":"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":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 2 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"}},{"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":"Vulnerabilities","score":9,"reason":"1 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: PYSEC-2023-177 / GHSA-x7m3-jprg-wc5g"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-17T03:12:36.106Z","repository_id":38714906,"created_at":"2025-08-17T03:12:36.106Z","updated_at":"2025-08-17T03:12:36.106Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28408854,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T01:52:23.358Z","status":"online","status_checked_at":"2026-01-14T02:00:06.678Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","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":["cpp","java","python","thrift"],"created_at":"2025-02-21T00:02:24.704Z","updated_at":"2026-01-14T03:40:20.528Z","avatar_url":"https://github.com/baifendian.png","language":"JavaScript","funding_links":[],"categories":["开发框架"],"sub_categories":[],"readme":"## harpc是什么\nHARPC（High Availability RPC）是基于Thrift的跨语言、高可用的RPC框架。具备高性能、高可用、轻量级等特点，在[百分点科技](http://www.baifendian.com/)内部服务中广泛使用。\n\n\n使用指南：[HARPC简介](docs/HARPC简介.pdf)  \nQQ讨论群：398091913  \n\u003ca target=\"_blank\" href=\"http://shang.qq.com/wpa/qunwpa?idkey=302796d303355d2fa70bba985aa2e13f554f910ccab428f1437a078d7082fb7c\"\u003e\u003cimg border=\"0\" src=\"http://pub.idqqimg.com/wpa/images/group.png\" alt=\"高可用RPC\" title=\"高可用RPC\"\u003e\u003c/a\u003e\n\n## 功能介绍\n\n* 跨语言通信\n    * 方便的使Java、Python、C++三种程序可以相互通信\n* 负载均衡和容灾处理\n    * 方便的实现任务的分布式处理\n    * 支持服务的水平扩展，自动发现新的服务节点\n    * 能够兼容各种异常情况，如节点的异常down机\n* 可视化管理\n    * 通过服务管理系统可以方便查看服务状态和统计信息\n* 与原生thrift通信\n    * 支持与原生thrift服务进行通信   \n\n## 与业内方案的对比\n\n* 与thrift、avro、hessian相比，harpc支持了高可用，并且更加易用\n* 与dubbo相比，harpc支持了跨语言，并且更轻量级\n* 与ice相比，harpc性能更高，并且更轻量级\n\n## 设计思路\nHARPC的核心思想是高可用，那么在保证高可用的基础上，还需要具备跨语言、高性能、可视化及轻量级等特性。于是，我们在设计之初就选择了基于thrift开发的方案，底层通信使用thrift来保证高性能和跨语言，然后HARPC来保证高可用和可视化，并且尽量保持简单，来达到轻量级的需求。\n\n* 整体结构\n\n![整体结构](imgs/arch_overall.png)\n   \n    * 说明\n        * 四个部分：client(客户端)、server(服务端)、registry（注册中心，目前为zookeeper集群）、admin(服务管理系统)\n        * client和server又包括： your code(用户代码)、harpc(核心框架，包含Java、Python、C++三个版本）、thrift gen（thrift生成的源码文件，用于底层通信）\n\n\n## 如何使用\n\n* [java](java) \n* [python](python)\n* [c++](cpp)\n\n## 测试结论\nharpc的Java、Python、C++版本的性能略有差别，由高到低为：C++版本 ≈ Java版本 \u003e Python版本，下面仅给出Java版本的测试数据和结论。\n\n* Java版本容错性测试\n![java版本容错性测试](imgs/java_fault_tolerant.png)\n\n* Java版本性能测试\n![java版本性能测试](imgs/java_performance.png)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbaifendian%2Fharpc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbaifendian%2Fharpc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbaifendian%2Fharpc/lists"}