Live data from Hacker News

Mars – A cross-platform network component developed by WeChat

github.com

11–20 of 26 posts

Re: Mars – A cross-platform network component developed by WeChat

#11
post #7
post #5

Earlier quoted context omitted.

The language barrier has been their main issue, they'd definitely would love to collaborate more with teams outside of China I know. They have an astonishing amount of dev resources as well, they wrote an entire cloud platform (they're at maybe 10% of AWS) from scratch, in C.

> entire cloud platform (they're at maybe 10% of AWS) from scratch, in C Impressive. Any link to this? I'd love to take a look.

In C++ actually.

Few years back Tencent had three internal teams making Wechat, the GuangZhou based Foxmail team won. Wechat IM protocol is basically a modified version of Microsoft Exchange.

Re: Mars – A cross-platform network component developed by WeChat

#12

This looks like a cross between OkHTTP and a jobqueue (like https://github.com/WhisperSystems/jobmanager or https://github.com/yigit/android-priority-jobqueue ). But I think this is the first cross platform framework that does this.

Can you explain what is the definition of cross platform here, I mean in which part of it is "cross-platform"? Is Realm also consider a cross-platform database solution for mobile?

Re: Mars – A cross-platform network component developed by WeChat

#13

This looks like a cross between OkHTTP and a jobqueue (like https://github.com/WhisperSystems/jobmanager or https://github.com/yigit/android-priority-jobqueue ). But I think this is the first cross platform framework that does this.

Can you explain what is the definition of cross platform here, I mean in which part of it is "cross-platform"? Is Realm also consider a cross-platform database solution for mobile?

The library itself claims to be cross platform. It has libraries available for iOS/Android/windows mobile.

I'm not sure about Realm..But I was talking in context of the job manager and network libraries.

But I suppose you could SQLite as cross platform.

Re: Mars – A cross-platform network component developed by WeChat

#14
post #9
post #4

Earlier quoted context omitted.

an AFNetworking/OkHttp alternative written in C++ and use socket instead of HTTP

So id could be used to avoid proxy capturing your requests?

i think it's more about performance. Wechat ha HUGE amount of users in China, an low level socket connection would get better performance than a standard HTTP request

Re: Mars – A cross-platform network component developed by WeChat

#15

Pardon my ignorance, but I tried reading through the page and could not figure out what this is or does. Can someone point me to a quick summary or overview?

It has a lot of overlaps with other network frameworks such as OkHttp, AFNetworking, cronet, etc., but I think it main contributions are these two components:

Xlog: in memory mmap log for fast logging and also supports encryption. Xlog log enables them to log everything fast and "safely" even in production build to quickly identify bugs.

STN: short and long TCP connection manager, which is optimized for various networks in China.

Plus other network utilities to make development easier.

Re: Mars – A cross-platform network component developed by WeChat

#16
I hope this contains the code that makes Wechat connections work so well on the often intermediate/slow/bad connections in China. Because then most companies can learn something from it (looking at Skype, Slack etc here which are horrible with bad connections).

Re: Mars – A cross-platform network component developed by WeChat

#17

I hope this contains the code that makes Wechat connections work so well on the often intermediate/slow/bad connections in China. Because then most companies can learn something from it (looking at Skype, Slack etc here which are horrible with bad connections).

Im surprised no one brings up how bad Slack's infrastructure or backend design is. It's my slowest app from launch to signed in and can see the latest message.

In the old days MSN messenger was faster.

Re: Mars – A cross-platform network component developed by WeChat

#18

I hope this contains the code that makes Wechat connections work so well on the often intermediate/slow/bad connections in China. Because then most companies can learn something from it (looking at Skype, Slack etc here which are horrible with bad connections).

Im surprised no one brings up how bad Slack's infrastructure or backend design is. It's my slowest app from launch to signed in and can see the latest message. In the old days MSN messenger was faster.

So it's not just me! I have issues with Slack quite regularly, from messages simply not appearing on web (usually iOS works fine) to the app not being able to reconnect without a hard refresh. Add to that the slow 'boot-up' and memory usage and all in all the experience is quite disappointing, especially for such a loved product where good connectivity should be a core requirement.

Re: Mars – A cross-platform network component developed by WeChat

#19
post #10
post #7

Earlier quoted context omitted.

> entire cloud platform (they're at maybe 10% of AWS) from scratch, in C Impressive. Any link to this? I'd love to take a look.

Their public cloud is http://qcloud.com/ , I don't think everything they've written on the backend is public however.

It has nothing to do with WeChat. qcloud is developed by TEG (Tech. Engineering Group), and the cloud service for WeChat is developed by WXG (Weixin Group).

Re: Mars – A cross-platform network component developed by WeChat

#20

I hope this contains the code that makes Wechat connections work so well on the often intermediate/slow/bad connections in China. Because then most companies can learn something from it (looking at Skype, Slack etc here which are horrible with bad connections).

Im surprised no one brings up how bad Slack's infrastructure or backend design is. It's my slowest app from launch to signed in and can see the latest message. In the old days MSN messenger was faster.

It makes Slack unusable for me from my house and in China...
Post reply on HN