在使用 IM 应用程序之前我需要了解什么?
我正在考虑使用 Java 堆栈构建 IM 类型的应用程序(至少对于服务器)。我有兴趣查看有关 Skype/AIM/MSN 等应用程序如何工作的任何信息/建议,以及了解任何可能相关的技术/API。 在不泄露这个想法本身的情况下,它可能更类似于 Google Wave,而不是 Skype,但对两者有用的信息都非常受欢迎。
我已经想到的具体点包括:
- 服务器与 P2P...出于记录的原因,我的系统将要求所有通信都通过中央服务器。这就是其他 IM 工具的工作方式吗……尤其是当音频/视频参与其中时?
- 与其他系统的交叉通信。是否有用于此目的的 API?或者所有 IM 提供商都努力保密其协议秘密吗?我正在设计的本质意味着集成可能只会受到限制,但从业务角度来看它绝对是值得的
I'm looking into building an IM-type application using Java stack (for the server at least). I'd be interested to see any information/advice on how applications like Skype/AIM/MSN work, as well as know any technologies/APIs that might be relevant.
Without giving away the idea itself, it's perhaps more akin to Google Wave than Skype, but information useful for either is very welcome.
Specific points I have already thought of include:
- Server Vs P2P... for reasons of logging my system will require all communication to go through a central server. Is this how other IM tools work... especially when audio/video comes into the equation?
- Cross-communication with other systems. Are there APIs for this or do all IM providers work hard to keep their protocol secret? The nature of what I'm designing means integration could probably only be limited, but it definitely seems worthwhile from a business perspective
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
了解 XMPP。有大量 Java 库,并且大多数主要 IM 客户端都支持 XMPP。
Get to know XMPP. There's plenty of Java libraries and most major IM clients support XMPP.
如前所述,使用 XMPP(代表可扩展消息传递和状态协议)。
您或许可以通过使用现有的 XMPP 服务器(例如 Openfire、ejabberd 等)来摆脱困境,而无需自己进行编程。有一个名为 libpurple 的东西,用于使用专有 IM 协议进行连接。
要执行标准 XMPP 无法完成的操作,您可以查看客户端机器人或外部服务器组件 。
As mentioned, use XMPP (which stands for eXtensible Messaging and Presence Protocol).
You can probably get away by using an existing XMPP server (e.g., Openfire, ejabberd, etc) without programming one yourself. There is something called libpurple for connecting using proprietary IM protocols.
For doing stuff that standard XMPP doesn't you can look at client bots or external server components.
构建移动消息应用程序有两种方法: 聊天功能开发:
这是一篇关于粗略估计开发成本细分的文章,开发 WhatsApp 的成本是多少? 开发 3 个月的初始固定成本最低为 260,000 美元,大约有 6 名工程师和一名产品经理在一个地方像硅谷或纽约一样从头开始构建基本的移动聊天功能。更不用说未来运行服务器、维护、可扩展性和功能扩展的成本了。花费金钱和时间构建聊天功能的机会成本是无法分配在核心功能上的资源(除非您正在构建另一个 WhatsApp 或 Facebook Messenger)。
如果您的计划不是重新发明轮子,或者您要节省工程资源并让专家更好地利用,或者只是通过聊天功能进行测试,那么集成第 3 方或开源解决方案通常会更简单且更具成本效益直接地。他们通常提供现成的可定制 UI 库、跨平台 SDK、后端 API 和 Webhooks 集成等。与使用 Google Analytics、Parse/Firebase、Crashlytics、AFNetworking、Facebook API、Socket.io、Stripe、用于短信的 Twilio、Hyphenate.io 等许多公司最初决定构建内部聊天解决方案,但后来意识到,随着客户群的快速增长,他们的解决方案无法按预期扩展。
但是,在开始动手集成聊天功能(无论是第三方集成还是内部解决方案)之前,您可能需要调查以下方面:
另一件需要考虑的事情是整合流行聊天机器人、大数据分析(尤其是客户服务)、加密等的可能性。检查第 3 方 SDK、开源或您的工程团队是否能够提供这些灵活性或布局潜在的跑道。一些移动消息解决方案提供商,例如 Hyphenate.io,拥有丰富的聊天功能集和巨大的扩展灵活性,可供您使用。
最后,回答您的想法,
Hyphenate 为您处理通信或消息传递以及建立视频/语音通话。
**在通信安全方面,您可能需要考虑 TLS/SSL 的 3 个主要组件传输层安全、用于身份验证的 OAuth 2.0 以及端到端加密。 **
There are two ways to build a mobile messaging app: chat features development:
Here’s an article about the rough estimated development cost breakdown, How Much Does It Cost to Develop WhatsApp? It comes to minimal initial fixed cost $260,000 for development for 3 months with about 6 engineers and a product manager in a place like Silicon Valley or NYC to build basic mobile chat features from scratch. Not to mention the cost of running servers, maintenance, scalability, and features expansion in the future. The opportunity cost of spending the dollars and time on building chat features are the resources that cannot allocate on your core features (unless you’re building another WhatsApp or Facebook Messenger).
If your plan is not to reinvent the wheel, or you’re conserving engineering resources and put experts for better use, or simply just testing water with chat features, then it’s often simpler and more cost effective to integrate the 3rd party or open source solutions directly. They often provide ready-to-use customizable UI library, cross platforms SDKs, backend APIs and Webhooks integration, etc. The same idea as using Google Analytics, Parse/Firebase, Crashlytics, AFNetworking, Facebook APIs, Socket.io, Stripe, Twilio for SMS, Hyphenate.io, etc. Many companies decide to build in-house chat solutions initially, but later realize that their solutions do not scale as expected as the customer base grow rapidly.
However, before you start getting hands dirty integrating chat features whether 3rd party integration or in-house solution, you might want to investigate the following areas,
Another thing to consider is the possibility of incorporating trendy chatbots, big data analysis (especially customer service), encryption, etc. Check if 3rd party SDKs, open source, or your engineering team are able to provide those flexibilities or layout the potential runway. Some mobile messaging solutions provider, like Hyphenate.io, have rich chat features set and great flexibility for expansion ready for you to dispose.
Finally, answers to your thoughts,
Hyphenate handles the communication or message delivery for you as well establishing the video/voice calling.
**In terms of communication security, there're 3 major components that you might want to look into TLS/SSL for transport layer security, OAuth 2.0 for authentication, and end-to-end encryption. **