diff --git a/.github/workflows/create-branch-on-tag.yml b/.github/workflows/create-branch-on-tag.bak similarity index 100% rename from .github/workflows/create-branch-on-tag.yml rename to .github/workflows/create-branch-on-tag.bak diff --git a/.github/workflows/docker-buildx.yml b/.github/workflows/docker-buildx.bak similarity index 100% rename from .github/workflows/docker-buildx.yml rename to .github/workflows/docker-buildx.bak diff --git a/.github/workflows/e2e-test.yml b/.github/workflows/e2e-test.bak similarity index 99% rename from .github/workflows/e2e-test.yml rename to .github/workflows/e2e-test.bak index 62df69ed5..6231697c2 100644 --- a/.github/workflows/e2e-test.yml +++ b/.github/workflows/e2e-test.bak @@ -80,7 +80,6 @@ jobs: - name: Module Operations run: | - sudo go mod tidy echo "===========> Verifying go-gitlint is installed" if [ ! -f ./_output/tools/go-gitlint ]; then export GOBIN=$(pwd)/_output/tools @@ -89,7 +88,6 @@ jobs: echo "===========> go-gitlint is installed in /home/ubuntu/DF/open-im-server/_output/tools/go-gitlint" fi - - name: Build, Start(make build && make start) run: | sudo ./scripts/install/install.sh -i diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.bak similarity index 100% rename from .github/workflows/golangci-lint.yml rename to .github/workflows/golangci-lint.bak diff --git a/.github/workflows/openimci.yml b/.github/workflows/openimci.yml index 033868a2e..83d495a0e 100644 --- a/.github/workflows/openimci.yml +++ b/.github/workflows/openimci.yml @@ -36,6 +36,7 @@ on: - "CONTRIBUTING/**" - "**.md" - "docs/**" + workflow_dispatch: jobs: diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.bak similarity index 100% rename from .github/workflows/pull-request.yml rename to .github/workflows/pull-request.bak diff --git a/README.md b/README.md index 175db3326..d0c397a28 100644 --- a/README.md +++ b/README.md @@ -51,137 +51,89 @@

-## :busts_in_silhouette: Community +## :busts_in_silhouette: Join Our Community -+ 💬 [Follow our Twitter account](https://twitter.com/founder_im63606) -+ 👫 [Join our Reddit](https://www.reddit.com/r/OpenIMessaging) -+ 🚀 [Join our Slack community](https://join.slack.com/t/openimsdk/shared_invite/zt-22720d66b-o_FvKxMTGXtcnnnHiMqe9Q) -+ :eyes: [Join our wechat (微信群)](https://openim-1253691595.cos.ap-nanjing.myqcloud.com/WechatIMG20.jpeg) -+ 📚 [OpenIM Community](https://github.com/OpenIMSDK/community) -+ 💕 [OpenIM Interest Group](https://github.com/Openim-sigs) ++ 💬 [Follow us on Twitter](https://twitter.com/founder_im63606) ++ 🚀 [Join our Slack](https://join.slack.com/t/openimsdk/shared_invite/zt-2hljfom5u-9ZuzP3NfEKW~BJKbpLm0Hw) ++ :eyes: [Join our WeChat Group](https://openim-1253691595.cos.ap-nanjing.myqcloud.com/WechatIMG20.jpeg) ## Ⓜ️ About OpenIM -OpenIM is a service platform specifically designed for integrating chat, audio-video calls, notifications, and AI chatbots into applications. It provides a range of powerful APIs and Webhooks, enabling developers to easily incorporate these interactive features into their applications. OpenIM is not a standalone chat application, but rather serves as a platform to support other applications in achieving rich communication functionalities. The following diagram illustrates the interaction between AppServer, AppClient, OpenIMServer, and OpenIMSDK to explain in detail. +Unlike standalone chat applications such as Telegram, Signal, and Rocket.Chat, OpenIM offers an open-source instant messaging solution designed specifically for developers rather than as a directly installable standalone chat app. Comprising OpenIM SDK and OpenIM Server, it provides developers with a complete set of tools and services to integrate instant messaging functions into their applications, including message sending and receiving, user management, and group management. Overall, OpenIM aims to provide developers with the necessary tools and framework to implement efficient instant messaging solutions in their applications. ![App-OpenIM Relationship](./docs/images/oepnim-design.png) -## 🚀 About OpenIMSDK +## 🚀 Introduction to OpenIMSDK -**OpenIMSDK** is an IM SDK designed for **OpenIMServer**, created specifically for embedding in client applications. Its main features and modules are as follows: +**OpenIMSDK**, designed for **OpenIMServer**, is an IM SDK created specifically for integration into client applications. It supports various functionalities and modules: + 🌟 Main Features: - - - 📦 Local storage - - 🔔 Listener callbacks - - 🛡️ API wrapping - - 🌐 Connection management + - 📦 Local Storage + - 🔔 Listener Callbacks + - 🛡️ API Wrapping + - 🌐 Connection Management + 📚 Main Modules: - 1. 🚀 Initialization and Login 2. 👤 User Management - 3. 👫 Friend Management + 3. 👫 Friends Management 4. 🤖 Group Functions - 5. 💬 Conversation Handling - -It is built using Golang and supports cross-platform deployment, ensuring a consistent access experience across all platforms. - -👉 **[Explore GO SDK](https://github.com/openimsdk/openim-sdk-core)** - -## 🌐 About OpenIMServer + 5. 💬 Session Handling -+ **OpenIMServer** has the following characteristics: - - 🌐 Microservice architecture: Supports cluster mode, including a gateway and multiple rpc services. - - 🚀 Diverse deployment methods: Supports deployment via source code, Kubernetes, or Docker. - - Support for massive user base: Super large groups with hundreds of thousands of users, tens of millions of users, and billions of messages. +Built with Golang and supports cross-platform deployment to ensure a consistent integration experience across all platforms. -### Enhanced Business Functionality: +👉 **[Explore the GO SDK](https://github.com/openimsdk/openim-sdk-core)** -+ **REST API**: OpenIMServer offers REST APIs for business systems, aimed at empowering businesses with more functionalities, such as creating groups and sending push messages through backend interfaces. -+ **Webhooks**: OpenIMServer provides callback capabilities to extend more business forms. A callback means that OpenIMServer sends a request to the business server before or after a certain event, like callbacks before or after sending a message. +## 🌐 Introduction to OpenIMServer -👉 **[Learn more](https://docs.openim.io/guides/introduction/product)** ++ **OpenIMServer** features include: + - 🌐 Microservices Architecture: Supports cluster mode, including a gateway and multiple rpc services. + - 🚀 Diverse Deployment Options: Supports source code, Kubernetes, or Docker deployment. + - Massive User Support: Supports large-scale groups with hundreds of thousands, millions of users, and billions of messages. -## :building_construction: Overall Architecture +### Enhanced Business Functions: -Delve into the heart of Open-IM-Server's functionality with our architecture diagram. ++ **REST API**: Provides a REST API for business systems to enhance functionality, such as group creation and message pushing through backend interfaces. -![Overall Architecture](./docs/images/architecture-layers.png) ++ **Webhooks**: Expands business forms through callbacks, sending requests to business servers before or after certain events. + ![Overall Architecture](./docs/images/architecture-layers.png) ## :rocket: Quick Start -We support many platforms. Here are the addresses for quick experience on the web side: +Experience online for iOS/Android/H5/PC/Web: -👉 **[OpenIM online web demo](https://web-enterprise.rentsoft.cn/)** +👉 **[OpenIM Online Demo](https://www.openim.io/en/commercial)** -🤲 To facilitate user experience, we offer various deployment solutions. You can choose your deployment method from the list below: +To facilitate user experience, we offer various deployment solutions. You can choose your preferred deployment method from the list below: + **[Source Code Deployment Guide](https://docs.openim.io/guides/gettingStarted/imSourceCodeDeployment)** + **[Docker Deployment Guide](https://docs.openim.io/guides/gettingStarted/dockerCompose)** -+ **[Kubernetes Deployment Guide](https://docs.openim.io/guides/gettingStarted/k8s-deployment)** -+ **[Mac Developer Deployment Guide](https://docs.openim.io/guides/gettingstarted/mac-deployment-guide)** - -## :hammer_and_wrench: To Start Developing OpenIM - -[![Open in Dev Container](https://img.shields.io/static/v1?label=Dev%20Container&message=Open&color=blue&logo=visualstudiocode)](https://vscode.dev/github/openimsdk/open-im-server) - -[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/openimsdk/open-im-server) - -OpenIM Our goal is to build a top-level open source community. We have a set of standards, in the [Community repository](https://github.com/OpenIMSDK/community). -If you'd like to contribute to this Open-IM-Server repository, please read our [contributor documentation](https://github.com/openimsdk/open-im-server/blob/main/CONTRIBUTING.md). +## System Support -Before you start, please make sure your changes are in demand. The best for that is to create a [new discussion](https://github.com/openimsdk/open-im-server/discussions/new/choose) OR [Slack Communication](https://join.slack.com/t/openimsdk/shared_invite/zt-22720d66b-o_FvKxMTGXtcnnnHiMqe9Q), or if you find an issue, [report it](https://github.com/openimsdk/open-im-server/issues/new/choose) first. +Supports Linux, Windows, Mac systems, and ARM and AMD CPU architectures. -- [OpenIM API Reference](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/api.md) -- [OpenIM Bash Logging](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/bash-log.md) -- [OpenIM CI/CD Actions](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/cicd-actions.md) -- [OpenIM Code Conventions](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/code-conventions.md) -- [OpenIM Commit Guidelines](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/commit.md) -- [OpenIM Development Guide](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/development.md) -- [OpenIM Directory Structure](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/directory.md) -- [OpenIM Environment Setup](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/environment.md) -- [OpenIM Error Code Reference](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/error-code.md) -- [OpenIM Git Workflow](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/git-workflow.md) -- [OpenIM Git Cherry Pick Guide](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/gitcherry-pick.md) -- [OpenIM GitHub Workflow](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/github-workflow.md) -- [OpenIM Go Code Standards](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/go-code.md) -- [OpenIM Image Guidelines](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/images.md) -- [OpenIM Initial Configuration](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/init-config.md) -- [OpenIM Docker Installation Guide](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/install-docker.md) -- [OpenIM OpenIM Linux System Installation](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/install-openim-linux-system.md) -- [OpenIM Linux Development Guide](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/linux-development.md) -- [OpenIM Local Actions Guide](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/local-actions.md) -- [OpenIM Logging Conventions](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/logging.md) -- [OpenIM Offline Deployment](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/offline-deployment.md) -- [OpenIM Protoc Tools](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/protoc-tools.md) -- [OpenIM Testing Guide](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/test.md) -- [OpenIM Utility Go](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/util-go.md) -- [OpenIM Makefile Utilities](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/util-makefile.md) -- [OpenIM Script Utilities](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/util-scripts.md) -- [OpenIM Versioning](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/version.md) -- [Manage backend and monitor deployment](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/prometheus-grafana.md) -- [Mac Developer Deployment Guide for OpenIM](https://github.com/openimsdk/open-im-server/tree/main/docs/contrib/mac-developer-deployment-guide.md) +## :link: Links -## :calendar: Community Meetings + + **[Developer Manual](https://docs.openim.io/)** + + **[Changelog](https://github.com/openimsdk/open-im-server/blob/main/CHANGELOG.md)** -We want anyone to get involved in our community and contributing code, we offer gifts and rewards, and we welcome you to join us every Thursday night. +## :writing_hand: How to Contribute -Our conference is in the [OpenIM Slack](https://join.slack.com/t/openimsdk/shared_invite/zt-22720d66b-o_FvKxMTGXtcnnnHiMqe9Q) 🎯, then you can search the Open-IM-Server pipeline to join +We welcome contributions of any kind! Please make sure to read our [Contributor Documentation](https://github.com/openimsdk/open-im-server/blob/main/CONTRIBUTING.md) before submitting a Pull Request. -We take notes of each [biweekly meeting](https://github.com/orgs/OpenIMSDK/discussions/categories/meeting) in [GitHub discussions](https://github.com/openimsdk/open-im-server/discussions/categories/meeting), Our historical meeting notes, as well as replays of the meetings are available at [Google Docs :bookmark_tabs:](https://docs.google.com/document/d/1nx8MDpuG74NASx081JcCpxPgDITNTpIIos0DS6Vr9GU/edit?usp=sharing). + + **[Report a Bug](https://github.com/openimsdk/open-im-server/issues/new?assignees=&labels=bug&template=bug_report.md&title=)** + + **[Suggest a Feature](https://github.com/openimsdk/open-im-server/issues/new?assignees=&labels=enhancement&template=feature_request.md&title=)** + + **[Submit a Pull Request](https://github.com/openimsdk/open-im-server/pulls)** -## :eyes: Who Are Using OpenIM +Thank you for contributing to building a powerful instant messaging solution! -Check out our [user case studies](https://github.com/OpenIMSDK/community/blob/main/ADOPTERS.md) page for a list of the project users. Don't hesitate to leave a [📝comment](https://github.com/openimsdk/open-im-server/issues/379) and share your use case. +## :closed_book: License -## :page_facing_up: License +OpenIMSDK is available under the Apache License 2.0. See the [LICENSE file](https://github.com/openimsdk/open-im-server/blob/main/LICENSE) for more information. -OpenIM is licensed under the Apache 2.0 license. See [LICENSE](https://github.com/openimsdk/open-im-server/tree/main/LICENSE) for the full license text. -The OpenIM logo, including its variations and animated versions, displayed in this repository [OpenIM](https://github.com/openimsdk/open-im-server) under the [assets/logo](./assets/logo) and [assets/logo-gif](assets/logo-gif) directories, are protected by copyright laws. ## 🔮 Thanks to our contributors! diff --git a/README_zh_CN.md b/README_zh_CN.md index f42031165..65aac9ebc 100644 --- a/README_zh_CN.md +++ b/README_zh_CN.md @@ -51,31 +51,29 @@

-## 🟢 扫描微信进群交流 - +## :busts_in_silhouette: 加入我们的社区 ++ 💬 [关注我们的 Twitter](https://twitter.com/founder_im63606) ++ 🚀 [加入我们的 Slack](https://join.slack.com/t/openimsdk/shared_invite/zt-2hljfom5u-9ZuzP3NfEKW~BJKbpLm0Hw) ++ :eyes: [加入我们的微信群](https://openim-1253691595.cos.ap-nanjing.myqcloud.com/WechatIMG20.jpeg) ## Ⓜ️ 关于 OpenIM -OpenIM 是一个专门设计用于在应用程序中集成聊天、音视频通话、通知以及AI聊天机器人等通信功能的服务平台。它通过提供一系列强大的API和Webhooks,使开发者可以轻松地在他们的应用中加入这些交互特性。OpenIM 本身并不是一个独立运行的聊天应用,而是作为一个平台,为其他应用提供支持,实现丰富的通信功能。下图展示 AppServer、AppClient、OpenIMServer 和 OpenIMSDK 之间的交互关系来具体说明。 - - +与Telegram、Signal、Rocket.Chat等独立聊天应用不同,OpenIM提供了专为开发者设计的开源即时通讯解决方案,而不是直接安装使用的独立聊天应用。OpenIM由OpenIM SDK和OpenIM Server两大部分组成,为开发者提供了一整套集成即时通讯功能的工具和服务,包括消息发送接收、用户管理和群组管理等。总体来说,OpenIM旨在为开发者提供必要的工具和框架,帮助他们在自己的应用中实现高效的即时通讯解决方案。 ![App-OpenIM 关系](./docs/images/oepnim-design.png) -## 🚀 关于 OpenIMSDK +## 🚀 OpenIMSDK 介绍 -**OpenIMSDK** 是为 **OpenIMServer** 设计的IM SDK,专为嵌入客户端应用而生。其主要功能及模块如下: +**OpenIMSDK** 是为 **OpenIMServer** 设计的IM SDK,专为集成到客户端应用而生。它支持多种功能和模块: + 🌟 主要功能: - - 📦 本地存储 - 🔔 监听器回调 - 🛡️ API封装 - 🌐 连接管理 - ## 📚 主要模块: - ++ 📚 主要模块: 1. 🚀 初始化及登录 2. 👤 用户管理 3. 👫 好友管理 @@ -86,81 +84,52 @@ OpenIM 是一个专门设计用于在应用程序中集成聊天、音视频通 👉 **[探索 GO SDK](https://github.com/openimsdk/openim-sdk-core)** -## 🌐 关于 OpenIMServer +## 🌐 OpenIMServer 介绍 -+ **OpenIMServer** 具有以下特点: ++ **OpenIMServer** 的特点包括: - 🌐 微服务架构:支持集群模式,包括网关(gateway)和多个rpc服务。 - - 🚀 部署方式多样:支持源代码、kubernetes或docker部署。 - - 海量用户支持:十万超级大群,千万用户,及百亿消息 + - 🚀 多样的部署方式:支持源代码、Kubernetes或Docker部署。 + - 海量用户支持:支持十万级超大群组,千万级用户和百亿级消息。 ### 增强的业务功能: -+ **REST API**:OpenIMServer 提供了REST API供业务系统使用,旨在赋予业务更多功能,例如通过后台接口建立群组、发送推送消息等。 -+ **Webhooks**:OpenIMServer提供了回调能力以扩展更多的业务形态,所谓回调,即OpenIMServer会在某一事件发生之前或者之后,向业务服务器发送请求,如发送消息之前或之后的回调。 ++ **REST API**:为业务系统提供REST API,增加群组创建、消息推送等后台接口功能。 + ++ **Webhooks**:通过事件前后的回调,向业务服务器发送请求,扩展更多的业务形态。 -👉 **[了解更多](https://docs.openim.io/guides/introduction/product)** + ![整体架构](./docs/images/architecture-layers.png) -## :rocket: 快速开始 + + +## :rocket: 快速入门 在线体验iOS/Android/H5/PC/Web: -👉 **[OpenIM online demo](https://www.openim.io/zh/commercial)** +👉 **[OpenIM在线演示](https://www.openim.io/en/commercial)** -🤲 为了方便用户体验,我们提供了多种部署解决方案,您可以根据下面的列表选择自己的部署方法: +为了便于用户体验,我们提供了多种部署解决方案,您可以根据以下列表选择适合您的部署方式: + **[源代码部署指南](https://docs.openim.io/guides/gettingStarted/imSourceCodeDeployment)** + **[Docker 部署指南](https://docs.openim.io/guides/gettingStarted/dockerCompose)** -+ **[Kubernetes 部署指南](https://docs.openim.io/guides/gettingStarted/k8s-deployment)** - -## :hammer_and_wrench: 开始开发 OpenIM - -OpenIM 我们的目标是建立一个顶级的开源社区。我们有一套标准,在[社区仓库](https://github.com/OpenIMSDK/community)中。 - -如果你想为这个 Open-IM-Server 仓库做贡献,请阅读我们的[贡献者文档](https://github.com/openimsdk/open-im-server/blob/main/CONTRIBUTING.md)。 - -在开始之前,请确保你的更改是有需求的。最好的方法是创建一个[新的讨论](https://github.com/openimsdk/open-im-server/discussions/new/choose) 或 [Slack 通信](https://join.slack.com/t/openimsdk/shared_invite/zt-22720d66b-o_FvKxMTGXtcnnnHiMqe9Q),或者如果你发现一个问题,首先[报告它](https://github.com/openimsdk/open-im-server/issues/new/choose)。 -+ [代码标准](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/go-code.md) +## 系统支持 -+ [Docker 镜像标准](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/images.md) +支持 Linux、Windows、Mac 系统以及 ARM 和 AMD CPU 架构。 -+ [目录标准](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/directory.md) +## :link: 相关链接 -+ [提交标准](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/commit.md) - -+ [版本控制标准](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/version.md) - -+ [接口标准](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/interface.md) - -+ [OpenIM配置和环境变量设置](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/environment.md) - -> **Note** -> 针对中国的用户,阅读我们的 [Docker 镜像标准](https://github.com/openimsdk/open-im-server/blob/main/docs/contrib/images.md) 以便使用国内 aliyun 的镜像地址。OpenIM 也有针对中国的 gitee 同步仓库,你可以在 [gitee.com](https://gitee.com/openimsdk) 上找到它。 - -## :link: 链接 - - + **[完整文档](https://doc.rentsoft.cn/)** + + **[开发手册](https://docs.openim.io/)** + **[更新日志](https://github.com/openimsdk/open-im-server/blob/main/CHANGELOG.md)** - + **[FAQ](https://github.com/openimsdk/open-im-server/blob/main/FAQ.md)** - + **[代码示例](https://github.com/openimsdk/open-im-server/blob/main/examples)** - -## :handshake: 社区 - - + **[GitHub Discussions](https://github.com/openimsdk/open-im-server/discussions)** - + **[Slack 通信](https://join.slack.com/t/openimsdk/shared_invite/zt-22720d66b-o_FvKxMTGXtcnnnHiMqe9Q)** - + **[GitHub Issues](https://github.com/openimsdk/open-im-server/issues)** - - 您可以加入这些平台,讨论问题,提出建议,或分享您的成功故事! -## :writing_hand: 贡献 +## :writing_hand: 如何贡献 - 我们欢迎任何形式的贡献!请确保在提交 Pull Request 之前阅读我们的[贡献者文档](https://github.com/openimsdk/open-im-server/blob/main/CONTRIBUTING.md)。 +我们欢迎任何形式的贡献!在提交 Pull Request 之前,请确保阅读我们的[贡献者文档](https://github.com/openimsdk/open-im-server/blob/main/CONTRIBUTING.md) + **[报告 Bug](https://github.com/openimsdk/open-im-server/issues/new?assignees=&labels=bug&template=bug_report.md&title=)** + **[提出新特性](https://github.com/openimsdk/open-im-server/issues/new?assignees=&labels=enhancement&template=feature_request.md&title=)** + **[提交 Pull Request](https://github.com/openimsdk/open-im-server/pulls)** - 感谢您的贡献,我们一起打造一个强大的即时通信解决方案! +感谢您的贡献,一起来打造强大的即时通讯解决方案! ## :closed_book: 许可证 diff --git a/config/kafka.yml b/config/kafka.yml index b1773c80a..d412e1be0 100644 --- a/config/kafka.yml +++ b/config/kafka.yml @@ -1,18 +1,36 @@ +# Username for authentication username: '' +# Password for authentication password: '' +# Producer acknowledgment settings producerAck: "" +# Compression type to use (e.g., none, gzip, snappy) compressType: "none" +# List of Kafka broker addresses address: [ localhost:19094 ] +# Kafka topic for Redis integration toRedisTopic: "toRedis" +# Kafka topic for MongoDB integration toMongoTopic: "toMongo" +# Kafka topic for push notifications toPushTopic: "toPush" +# Consumer group ID for Redis topic toRedisGroupID: redis +# Consumer group ID for MongoDB topic toMongoGroupID: mongo +# Consumer group ID for push notifications topic toPushGroupID: push +# TLS (Transport Layer Security) configuration tls: + # Enable or disable TLS enableTLS: false + # CA certificate file path caCrt: "" + # Client certificate file path clientCrt: "" + # Client key file path clientKey: "" + # Client key password clientKeyPwd: "" + # Whether to skip TLS verification (not recommended for production) insecureSkipVerify: false diff --git a/config/minio.yml b/config/minio.yml index 0a80bb845..11a9ace35 100644 --- a/config/minio.yml +++ b/config/minio.yml @@ -1,7 +1,16 @@ +# Name of the bucket in MinIO bucket: "openim" +# Access key ID for MinIO authentication accessKeyID: "root" +# Secret access key for MinIO authentication secretAccessKey: "openIM123" +# Session token for MinIO authentication (optional) sessionToken: '' -internalAddress: "minio:9000" +# Internal address of the MinIO server +internalAddress: "localhost:10005" +# External address of the MinIO server, accessible from outside. Supports both HTTP and HTTPS using a domain name externalAddress: "http://external_ip:10005" -publicRead: false \ No newline at end of file +# Flag to enable or disable public read access to the bucket +publicRead: false + + diff --git a/config/mongodb.yml b/config/mongodb.yml index 12f1f66a5..98f5694e4 100644 --- a/config/mongodb.yml +++ b/config/mongodb.yml @@ -1,7 +1,14 @@ +# URI for database connection, leave empty if using address and credential settings directly uri: '' +# List of MongoDB server addresses address: [ localhost:37017 ] +# Name of the database database: openim_v3 +# Username for database authentication username: openIM +# Password for database authentication password: openIM123 +# Maximum number of connections in the connection pool maxPoolSize: 100 -maxRetry: 10 \ No newline at end of file +# Maximum number of retry attempts for a failed database connection +maxRetry: 10 diff --git a/config/notification.yml b/config/notification.yml index 1afb44e46..278376c24 100644 --- a/config/notification.yml +++ b/config/notification.yml @@ -17,32 +17,23 @@ # The options field 'isNotification' indicates if it's a notification. groupCreated: isSendMsg: true - # Reliability level of the message sending. # Set to 1 to send only when online, 2 for guaranteed delivery. reliabilityLevel: 1 - # This setting is effective only when 'isSendMsg' is true. # It controls whether to count unread messages. unreadCount: false - # Configuration for offline push notifications. offlinePush: # Enables or disables offline push notifications. enable: false - # Title for the notification when a group is created. title: "create group title" - # Description for the notification. desc: "create group desc" - # Additional information for the notification. ext: "create group ext" -# Content type is not added here. -# Content should use a JSON structure conforming to the protobuf format. - groupInfoSet: isSendMsg: false reliabilityLevel: 1 diff --git a/config/openim-msggateway.yml b/config/openim-msggateway.yml index ad6e180cc..0c92d8327 100644 --- a/config/openim-msggateway.yml +++ b/config/openim-msggateway.yml @@ -1,19 +1,30 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10140 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20112 ] +# IP address that the RPC/WebSocket service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 longConnSvr: + # WebSocket listening ports, must match the number of rpc.ports ports: [ 10001 ] + # Maximum number of WebSocket connections websocketMaxConnNum: 100000 + # Maximum length of the entire WebSocket message packet websocketMaxMsgLen: 4096 + # WebSocket connection handshake timeout in seconds websocketTimeout: 10 +# 1: For Android, iOS, Windows, Mac, and web platforms, only one instance can be online at a time multiLoginPolicy: 1 + diff --git a/config/openim-msgtransfer.yml b/config/openim-msgtransfer.yml index 9cb1598b5..07a7dc1ab 100644 --- a/config/openim-msgtransfer.yml +++ b/config/openim-msgtransfer.yml @@ -1,3 +1,6 @@ prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; each port corresponds to an instance of monitoring. Ensure these are managed accordingly + # Because four instances have been launched, four ports need to be specified ports: [ 20108, 20109, 20110, 20111 ] diff --git a/config/openim-push.yml b/config/openim-push.yml index 35e1b2c07..a1abfcf88 100644 --- a/config/openim-push.yml +++ b/config/openim-push.yml @@ -1,14 +1,20 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # IP address that the RPC service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10170 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20107 ] maxConcurrentWorkers: 3 -enable: getui +#"Use geTui for offline push notifications, or choose fcm or jpns; corresponding configuration settings must be specified." +enable: "geTui" geTui: pushUrl: "https://restapi.getui.com/v2/$appId" masterSecret: '' @@ -24,6 +30,7 @@ jpns: pushURL: '' pushIntent: '' +# iOS system push sound and badge count iosPush: pushSound: "xxx" badgeCount: true diff --git a/config/openim-rpc-auth.yml b/config/openim-rpc-auth.yml index a77b5457e..2d861cd5a 100644 --- a/config/openim-rpc-auth.yml +++ b/config/openim-rpc-auth.yml @@ -1,13 +1,18 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # IP address that the RPC service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10160 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20106 ] tokenPolicy: - #token有效期,单位(天) + # Token validity period, in days expire: 90 diff --git a/config/openim-rpc-conversation.yml b/config/openim-rpc-conversation.yml index e2d9b6a53..a094bfac1 100644 --- a/config/openim-rpc-conversation.yml +++ b/config/openim-rpc-conversation.yml @@ -1,11 +1,13 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # IP address that the RPC service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10180 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20105 ] - - - diff --git a/config/openim-rpc-friend.yml b/config/openim-rpc-friend.yml index 109e3f658..7b829f971 100644 --- a/config/openim-rpc-friend.yml +++ b/config/openim-rpc-friend.yml @@ -1,8 +1,13 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # IP address that the RPC service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10120 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20104 ] diff --git a/config/openim-rpc-group.yml b/config/openim-rpc-group.yml index a70d6f96e..78b44030e 100644 --- a/config/openim-rpc-group.yml +++ b/config/openim-rpc-group.yml @@ -1,9 +1,13 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # IP address that the RPC service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10150 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20103 ] - diff --git a/config/openim-rpc-msg.yml b/config/openim-rpc-msg.yml index de5e2324d..17ce26e9b 100644 --- a/config/openim-rpc-msg.yml +++ b/config/openim-rpc-msg.yml @@ -1,13 +1,19 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # IP address that the RPC service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10130 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20102 ] -#发消息是否需要好友验证 + +# Does sending messages require friend verification friendVerify: false diff --git a/config/openim-rpc-third.yml b/config/openim-rpc-third.yml index e3a847bf2..bb41c93ae 100644 --- a/config/openim-rpc-third.yml +++ b/config/openim-rpc-third.yml @@ -1,13 +1,20 @@ rpc: + # The IP address where this RPC service registers itself; if left blank, it defaults to the internal network IP registerIP: '' + # IP address that the RPC service listens on; setting to 0.0.0.0 listens on both internal and external IPs. If left blank, it automatically uses the internal network IP listenIP: 0.0.0.0 + # List of ports that the RPC service listens on; configuring multiple ports will launch multiple instances. These must match the number of configured prometheus ports ports: [ 10190 ] prometheus: + # Enable or disable Prometheus monitoring enable: true + # List of ports that Prometheus listens on; these must match the number of rpc.ports to ensure correct monitoring setup ports: [ 20101 ] + object: + # Use MinIO as object storage, or set to "cos", "oss", "kodo", "aws", while also configuring the corresponding settings enable: "minio" cos: bucketURL: https://temp-1252357374.cos.ap-chengdu.myqcloud.com diff --git a/docs/CODEOWNERS b/docs/CODEOWNERS index d1119eb61..68e459f9d 100644 --- a/docs/CODEOWNERS +++ b/docs/CODEOWNERS @@ -2,28 +2,28 @@ # Each line is a file pattern followed by one or more owners. # README files -README.md @openimsdk/openim @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiamcool @withchao +README.md @openimsdk/openim @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @withchao # Contributing guidelines -CONTRIBUTING.md @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiamcool @withchao +CONTRIBUTING.md @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @withchao # License files -LICENSE @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiamcool @withchao +LICENSE @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @withchao # Makefile -Makefile @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiamcool @withchao +Makefile @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @withchao # These owners will be the default owners for everything in # the repo. Unless a later match takes precedence, -# @cubxxw and @openimsdk/bot will be requested for +# and @openimsdk/bot will be requested for # review when someone opens a pull request. -* @openimsdk/openim @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiamcool @withchao +* @openimsdk/openim @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @withchao # Order is important; the last matching pattern takes the most # precedence. When someone opens a pull request that only # modifies JS files, only @js-owner and not the global # owner(s) will be requested for a review. -*.js @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiamcool @withchao +*.js @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @withchao # You can also use email addresses if you prefer. They'll be # used to look up users just like we do for commit author @@ -35,7 +35,7 @@ Makefile @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiam # be identified in the format @org/team-name. Teams must have # explicit write access to the repository. In this example, # the OpenIMSDK team in the github organization owns all .txt files. -*.txt @cubxxw @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @rfyiamcool @withchao +*.txt @openimsdk/bot @Bloomingg @FGadvancer @skiffer-git @withchao # The `docs/*` pattern will match files like # `docs/getting-started.md` but not further nested files like @@ -44,13 +44,13 @@ docs/* 3293172751nss@gmail.com @openimsdk/bot @skiffer-git # In this example, @octocat owns any file in an apps directory # anywhere in your repository. -api/ @openimsdk/openim @cubxxw @skiffer-git +api/ @openimsdk/openim @skiffer-git # This is a comment. # Each line is a file pattern followed by one or more owners. # CHANGELOG file -CHANGELOG/* @cubxxw @skiffer-git +CHANGELOG/* @skiffer-git # _output directory _output/* @skiffer-git @@ -67,21 +67,21 @@ config/* @skiffer-git # internal directory internal/ @openimsdk/openim @skiffer-git @FGadvancer -tools @openimsdk/openim @openimsdk/bot @cubxxw @skiffer-git @FGadvancer +tools @openimsdk/openim @openimsdk/bot @skiffer-git @FGadvancer # logs directory logs/* @skiffer-git @FGadvancer # pkg directory -pkg/a2r @openimsdk/openim @skiffer-git @cubxxw @openimsdk/bot +pkg/a2r @openimsdk/openim @skiffer-git @openimsdk/bot # scripts directory -scripts/template/* @openimsdk/openim @cubxxw @skiffer-git @FGadvancer -scripts/enterprise/* @openimsdk/openim @FGadvancer @cubxxw @skiffer-git @openimsdk/bot -scripts/githooks/* @openimsdk/openim @cubxxw @skiffer-git @FGadvancer -scripts/lib/* @openimsdk/openim @FGadvancer @cubxxw @skiffer-git @openimsdk/bot -scripts/make-rules/* @openimsdk/openim @FGadvancer @cubxxw @skiffer-git @openimsdk/bot +scripts/template/* @openimsdk/openim @skiffer-git @FGadvancer +scripts/enterprise/* @openimsdk/openim @FGadvancer @skiffer-git @openimsdk/bot +scripts/githooks/* @openimsdk/openim @skiffer-git @FGadvancer +scripts/lib/* @openimsdk/openim @FGadvancer @skiffer-git @openimsdk/bot +scripts/make-rules/* @openimsdk/openim @FGadvancer @skiffer-git @openimsdk/bot # test directory -test/mongo @FGadvancer @cubxxw @skiffer-git @openimsdk/bot -test/mysql @FGadvancer @cubxxw @skiffer-git @openimsdk/bot +test/mongo @FGadvancer @skiffer-git @openimsdk/bot +test/mysql @FGadvancer @skiffer-git @openimsdk/bot diff --git a/go.mod b/go.mod index 6b23243b6..cfe2d1df3 100644 --- a/go.mod +++ b/go.mod @@ -2,8 +2,6 @@ module github.com/openimsdk/open-im-server/v3 go 1.21.2 -toolchain go1.21.9 - require ( firebase.google.com/go v3.13.0+incompatible github.com/dtm-labs/rockscache v0.1.1 diff --git a/internal/push/offlinepush/offlinepusher.go b/internal/push/offlinepush/offlinepusher.go index 0706be64a..d4fcae434 100644 --- a/internal/push/offlinepush/offlinepusher.go +++ b/internal/push/offlinepush/offlinepusher.go @@ -26,7 +26,7 @@ import ( ) const ( - geTUI = "getui" + geTUI = "geTui" firebase = "fcm" jPush = "jpush" ) diff --git a/internal/push/push_handler.go b/internal/push/push_handler.go index e09b0b2ec..3a9a696f6 100644 --- a/internal/push/push_handler.go +++ b/internal/push/push_handler.go @@ -259,7 +259,7 @@ func (c *ConsumerHandler) groupMessagesHandler(ctx context.Context, groupID stri *pushToUserIDs = append(*pushToUserIDs, kickedUsers...) case constant.GroupDismissedNotification: - if msgprocessor.IsNotification(msgprocessor.GetConversationIDByMsg(msg)) { // 消息先到,通知后到 + if msgprocessor.IsNotification(msgprocessor.GetConversationIDByMsg(msg)) { var tips sdkws.GroupDismissedTips if unmarshalNotificationElem(msg.Content, &tips) != nil { return err diff --git a/start-config.yml b/start-config.yml index cd9663c98..a9c412b33 100644 --- a/start-config.yml +++ b/start-config.yml @@ -4,7 +4,7 @@ serviceBinaries: openim-rpc-user: 1 openim-msggateway: 1 openim-push: 1 - openim-msgtransfer: 1 + openim-msgtransfer: 4 openim-rpc-conversation: 1 openim-rpc-auth: 1 openim-rpc-group: 1 @@ -12,8 +12,6 @@ serviceBinaries: openim-rpc-msg: 1 openim-rpc-third: 1 toolBinaries: - - ncpu - check-free-memory - - versionchecker - check-component maxFileDescriptors: 10000