Rust in China
Live captioning by White Coat Captioning
BRIAN: Thank you. This is a talk about what's going on in China, at least with respect to Rust. Here we have a link to the presentation materials. You might want to go check out that link. We have far more content than we will fit into this talk and we are going to go really fast. If you want to follow up on any of the material, there's lots of links that you can click on.
My name is Brian, I have been doing Rust since 2010. I used to work at Mozilla where I was on the core team before there was a core team and right now I work at PingCAP, a Chinese company that builds a distributed database in Rust. And go.
AIMEE: Hi, I'm Aimee again. Our team is building the permissionless blockchain network. Also I created a blockchain monthly newsletter earlier this year and we are also organised RustCon Asia this year in April and it's the first Rust conference in China.
BRIAN: Thanks, Aimee. Okay, so here is the thesis of this talk. Rust is not a success in China. It's a huge bummer. That's not to say that Rust is a failure in China, but the adoption is pretty low, lower than you might expect, and awareness is also low among engineers. All right, here is what we are going to talk about a bit. We are going to show you some of the production users, of which there are some that you will know in China and some of what they are doing and some of the interesting contributions they are making to the Rust community. We will talk about the obstacles that Rust is facing toward adoption in China. Then we will highlight some of the accomplishments of the Rust community in China and finally a little bit about the future of Rust and some of the potential solutions to Rust's obstacles in China.
During this talk I will probably make some generalisations of the form like: China being like this, we'd be like this. I know that's kind of risky and horrible. I don't like a generalisation but it's a useful rhetorical device. I hope I don't offend anybody.
This patronising slide is to reinforce and remind you how important the Chinese market is. China is huge. There are a lot of people in China. This is a vacation slide, me and Alex from the core team. We visited China in 2017. The guy in the middle there is a guy named Tenex from PingCAP, the company that I work for now, and that company was also the first Rust production user in China. Not really a vacation; that was work.
Okay, now Aimee is going to tell you a little bit about what is going on in the world of Chinese Rust production users.
AIMEE: As you can see from the logos here, Alibaba, Baidu, very big companies in China, they have different projects. One interesting project in Alibaba is they generate target image-focused advertisements but also they are doing secure computing research and that is they use Rust as a cloud service layer. There are a lot of - some other very popular apps like bilibili, a video platform, PingCAP database company, and also the two Chinese characters, in China they use Rust for the search engine and also some other blockchain companies; imToken, on the very left, that's a blockchain wallet and that is where I was working at and SparkPool is the biggest mining pool. Most projects are open source. You can check the GitHub for all the stuff here. And Nervos, where I work at, they have a virtual machine and CKB is a base layer of the blockchain. Muta is another framework for building other blockchains and PingCAP, where Brian works, they have a lot of web hosts with the distributed secure database, and that's all from my side.
BRIAN: Okay, so Aimee showed you that slide of prominent Rust production users in China. I want to emphasise that that is all of the Rust production users in China, and we kind of scoured the Internet for them last night. Some of those are really prominent companies, and it's really exciting that they are using Rust, but they are mostly using them - the big companies on that slide are mostly using them in a fairly small way, but at least there's that awareness in those companies. Those big companies like Alibaba are going to drive it.
Unfortunately, I can't really talk about this without at least acknowledging the Great Firewall. You've probably heard of the Great Firewall. It impacts everything in China. Your life is digital these days and the Great Firewall just reaches into that digital life in every conceivable way. You've surely heard about the Great Firewall and what it does, but unless you've actually been in mainland China you probably don't really feel it in your bones, what the GFW does to you. I can't really tell you what the GFW actually is because it's a very complex thing but essentially there is an Internet in China and it works great. And there is the Internet that we all know outside of China, and it is utterly broken. Almost every service that I use personally, as soon as I enter China, just stops working.
The big impact that this has - it has many impacts on Rust engineers in China, but the really big, horrible one that it has is that the Rust Toolset does not work in China. Rustup and cargo, the things that you take for granted and everybody loves, that makes Rust so easy to use, they literally don't work in China. If you go to the website and follow the instructions that we give everybody - like, this is how you use Rust - it honestly is not going to work for your newbie Rust user that is excitedly trying to onboard themselves to Rust. What's probably going to happen is that either rustup is going to fail to download a toolchain from the Rust distribution servers or that cargo will fail to download packages from crates.io. Obviously this is a really, really horrible story and your first experience with Rust is going to be a disaster if you are in China.
Fortunately, the Rust community in China is doing the best they can and the University of Science and Technology of China has a user group there that has created mirrors for crates.io and mirrors for rustup, so if you know what to do and you know the right people and they hand you the secret documents then you can figure out how to use Rust in China, but in a lot of ways the Rust community in China is like a secret society. You can't go to the Rust website and figure out how to be inducted into the Rust community. You've got to have somebody tell you how to use Rust and where to find the other people that use Rust, and another reason why the community is like a secret society is because of the way communities are organised and communicate in China. Again, like the GFW, you have probably heard of WeChat which is the social media app in China, but it's much more than that, it's basically the tool that runs your life in China. You use it for instant messaging, for group chats, to make almost all your payments in China and you even use it to order your food at the restaurant. Everything happens through WeChat and this has two really big, negative consequences for organising a community in China. The first is that WeChat groups are private and invitation only, so again you go to the Rust website and as a Chinese user you try to figure out: where do I go get help? You probably see that you are ushered towards Discord or something like that and maybe you go there and it doesn't work. Certainly you go to Discord and don't find anybody that speaks Chinese. What you really need to do to get help is again to find somebody else who is already part of the Rust community and have them tell you the secret that: oh, you need to be invited to this WeChat group and then you can get help.
The second way that WeChat really negatively impacts adoption in China is that WeChat groups are limited to 500 people, so in a real practical sense this means that the Chinese community for Rust is made of 500 people. In practice, we have attentive moderators and when one room fills up they will create Rust group 2, 3, 4, but this just creates disjointed Rust communities of people and it's a huge problem. I would like to say something about engineering culture, but my ideas there are vague and I don't really have a lot of time, but again I will be around, you can ask me questions later. I am going to move on.
It feels like something went wrong in China with Rust adoption and that we could have done better. I can say more about this, but in the interests of time I need to move on to the next part where we talk about the good things that are happening in Rust. So Aimee is going to talk a little bit about what the Rust community is doing that is so great.
AIMEE: Thank you again. There are many problems already like officialdom or whatever can also bar the local Chinese team, but it's fun. We also have a local amenity who are doing a lot of effort to make the community grow. I would like to highlight Alex Zhang and Mike Tang. Alex even wrote a book about Rust programming, Mike runs almost all the Rust groups in China and they also run rust.cc which is all about the programming language and they use that forum to share all the things with the community. They also organise a team who translate Rust language official website to Chinese. Thanks for all the members here and we also organised the RustCon Asia this year, the first in China, we had one day of keynote talks and two full days of workshops with about 300 attendees there. It was a great time and we are also asking for support for the next conference. Brian.
BRIAN: Thank you, Aimee. I want to emphasise that Aimee organised that entire conference this year, and it really went well. [Applause]
Okay, so in the last minute here I want to talk a little bit about some of those problems and the solutions and what we expect to see in the future. Like I said, it's tempting to believe that somebody over here screwed up when we see the low adoption and awareness of Rust in China, but the more that I talk to engineers and I experience the Rust community in China, the more I realise that every individual local community is unique and has its own unique problems, and it's kind of impossible for me to come in and say: well, you shouldn't be using WeChat because the fact of the matter is WeChat is where the people are in China and you've going to where the people are, so WeChat, for example, poses a lot of problems to community building but also you've got to be on WeChat because that's where people expect you to be. So it's really up to the Chinese Rust community to figure out those kind of communication and organisational issues. I expect that Rust adoption in China will continue to be led by a few companies and, as we see, the companies like Alibaba and Baidu use Rust more and more they will sort of build confidence in the engineers in China that Rust is a language worth learning and worth adopting.
I really would love for somebody to step up and fix cargo and rustup and this is the one big technical thing that is really on the team to fix. This involves infrastructure issues, it involves legal issues, and somebody really has to do hard work to make that happen, but in order for people to use your product, the product has got to work. All right, I think I'm going to wrap up now. Again, link is on the slides. We have much more that we can possibly talk about Rust in China. If you want to talk to us, come and find us in the hallway track. We will take no questions right now because we are running late. Please enjoy your lunch. [Applause]