{"id":18893395,"url":"https://github.com/xtaci/chat","last_synced_at":"2025-04-15T00:31:46.523Z","repository":{"id":33971452,"uuid":"37710779","full_name":"xtaci/chat","owner":"xtaci","description":"pub/sub based chat server","archived":false,"fork":false,"pushed_at":"2017-04-27T12:14:06.000Z","size":1479,"stargazers_count":28,"open_issues_count":2,"forks_count":18,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-03-28T12:51:13.315Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xtaci.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-06-19T08:28:49.000Z","updated_at":"2024-11-07T08:05:31.000Z","dependencies_parsed_at":"2022-07-13T21:43:45.956Z","dependency_job_id":null,"html_url":"https://github.com/xtaci/chat","commit_stats":null,"previous_names":["gonet2/chat"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xtaci%2Fchat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xtaci%2Fchat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xtaci%2Fchat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xtaci%2Fchat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xtaci","download_url":"https://codeload.github.com/xtaci/chat/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248984326,"owners_count":21193727,"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-11-08T08:13:30.333Z","updated_at":"2025-04-15T00:31:43.969Z","avatar_url":"https://github.com/xtaci.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# chat(聊天）\n[![Build Status](https://travis-ci.org/xtaci/chat.svg)](https://travis-ci.org/xtaci/chat)\n\n## 设计理念\n\n     EndPoint:  消息收发点（对应到一个玩家的聊天，或者一个联盟聊天） \n     PubSub: 对任意EndPoint进行发布，订阅\n\n聊天服务器并不关心一个EndPoint对应的是一个玩家，还是一个联盟，只需要一个独立的id(snowflake-id)。       \n通常在玩家注册的时候，会创建一个EndPoint，创建一个联盟的时候，也会创建一个EndPoint。     \n玩家登陆后，会订阅到自己的私人EndPoint和所属联盟的EndPoint，以便接受实时聊天消息。      \nCHAT会保留一定数量的消息在内存中（默认128条），这个消息队列会定期持久化到本地磁盘，以便重启时候加载。       \n持久化采用boltdb，零配置, 数据存储在 VOLUME /data。        \n\n基于PubSub的聊天服务器，优点在于可以通过多个途径**同时**访问到同一个EndPoint, 例如：      \n1. 游戏内     \n2. 游戏提供的离线聊天工具     \n3. 提供给XMPP网关       \n\n## 使用\n参考测试用例以及chat.proto文件\n\n## 安装\n参考Dockerfile\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxtaci%2Fchat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxtaci%2Fchat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxtaci%2Fchat/lists"}