Sick Gaming
Why Open Source Matters to Alibaba - Printable Version

+- Sick Gaming (https://www.sickgaming.net)
+-- Forum: Computers (https://www.sickgaming.net/forum-86.html)
+--- Forum: Linux, FreeBSD, and Unix types (https://www.sickgaming.net/forum-88.html)
+--- Thread: Why Open Source Matters to Alibaba (/thread-85356.html)



Why Open Source Matters to Alibaba - xSicKxBot - 06-24-2018

Why Open Source Matters to Alibaba

<div style="margin: 5px 5% 10px 5%;"><img src="http://www.sickgaming.net/blog/wp-content/uploads/2018/06/why-open-source-matters-to-alibaba.png" width="1446" height="784" title="" alt="" /></div><div><div><img src="http://www.sickgaming.net/blog/wp-content/uploads/2018/06/why-open-source-matters-to-alibaba.png" class="ff-og-image-inserted" /></div>
<p><span><span>Alibaba has more than 150 open source projects and is a long-time contributor to many others, </span><span> </span><span>Wei Cao, a Senior Staff Engineer at Alibaba, says that sharing knowledge and receiving feedback from the community helps Alibaba refine their projects. We spoke with Wei Cao — who is the head of Alibaba Cloud Database Department and leads </span><span>the R&amp;D of Alibaba RDS,POLARDB </span><span>products — to learn more about the company’s open source focus and about some of the database-related projects they contribute to.</span></span></p>
<p><strong><span><span>Linux.com: Why is open source so important for Alibaba?</span></span></strong></p>
<p><span><strong><span>Wei Cao: </span></strong><span>At present, Alibaba has more than 150 open source projects. We work on the open source projects with the aim to contribute to the industry and solve real-life problems. We share our experiences with the rest of the open source enthusiasts.</span></span></p>
<p>As a long-time contributor to various other open source projects, Alibaba and Alibaba Cloud have fostered a culture that encourages our teams to voluntarily contribute to various open source projects, either by sharing experiences or helping others to solve problems. Sharing and contributing to the community altogether is in the DNA of Alibaba’s culture.</p>
<p><span><span>When we first started to use open sources projects like MySQL, Redis, PostgreSQL, we received a lot of help from the community. Now we would like to give back to the same communities by sharing our accumulated knowledge and receive feedback from the community so that we can refine our projects. </span></span></p>
<p><span><span>We believe this truly represents the essence of open source development, where everyone can build on each other’s knowledge. We are dedicated to making our technology inclusive through continuously contributing to bug-fixing and patch optimization of different open source projects.</span></span></p>
<p><strong><span><span>Linux.com: Can you tell us what kind of culture is within Alibaba to encourage its developers to consume and contribute to Open Source project?</span></span></strong></p>
<p><span><strong><span>Wei Cao: </span></strong><span>Alibaba has always had a culture of integrity, partnership, sharing and mutual assistance. At the same time, we always believe that more people participating in the community can promote the industry better and also make us more profitable. Therefore, our staff members are willing to pay close attention to open source projects in the community. They keep using open source projects and accumulating experience to give feedback on projects and jointly promote the development of the industry.</span></span></p>
<p><strong><span><span>Linux.com: Can you tell us what kind of open source projects you are using in your company?</span></span></strong></p>
<p><span><span><strong>Wei Cao:</strong> </span><span>Our database products use many open source projects such as MySQL, Redis, PostgreSQL, etc. Our teams have done feature and performance enhancement and optimization, depending on various use-cases. We have done compression for IoT and security improvements for financial industries.</span></span></p>
<p><strong><span><span>Linux.com: Can you tell us about the open source projects that you have created?</span></span></strong></p>
<p><span><span><strong>Wei Cao:</strong> </span><span>We will be releasing a new open source project, called Mongo-Shake, at the LC3 Conference. Based on MongoDB’s oplog, Mongo-Shake is a universal platform for services.</span></span></p>
<p><span><span>It reads the Oplog operation logs of a MongoDB cluster and replicates MongoDB data, and subsequently implements specific requirements through operation logs. Logs can provide a lot of scene-based applications. </span></span></p>
<p><span><span>Through the operation logs, we provide log data subscriptions to consume PUB/SUB functions and can be flexibly connected to adapt to different scenarios (such as log subscription, data center synchronization, Cache asynchronous elimination, etc.) through SDK, Kafka, MetaQ, etc. Cluster data synchronization is a core application scenario. Synchronization is achieved through playback after grabbing oplogs. Its Application Scenario includes:</span></span></p>
<ul>
<li>
<p><span><span>Asynchronous replication of MongoDB data between clusters eliminates the need for double write costs.</span></span></p>
</li>
<li>
<p><span><span>Mirror backup of MongoDB cluster data. (Not support in this open source version)</span></span></p>
</li>
<li>
<p><span><span>Log offline analysis.</span></span></p>
</li>
<li>
<p><span><span>Log subscription.</span></span></p>
</li>
<li>
<p><span><span>Cache synchronization.</span></span></p>
</li>
<li>
<p><span><span>Through the results of the log analysis, it is known which caches can be eliminated and which caches can be preloaded to prompt the cache to be updated.</span></span></p>
</li>
<li>
<p><span><span>Monitor base on log.</span></span></p>
</li>
</ul>
<p><strong><span><span>Linux.com: Can you tell us about the major open source projects you contribute to?</span></span></strong></p>
<p><span><strong><span>Wei Cao: </span></strong><span>We have contributed many database-related open source projects. </span><span>In addition, we have released open source </span><span>projects, like </span><span>AliSQL and </span><span>ApsaraCache, which are widely used in Alibaba.</span></span></p>
<p><span><strong><span>AliSQL: </span></strong><span>AliSQL is a MySQL branch, developed by Alibaba Cloud database team, and is servicing Alibaba’s business and Alibaba Cloud’s RDS. </span><span>AliSQL version is verified to run many Alibaba workloads and is  widely used within Alibaba cloud. The latest AliSQL also merged many useful </span></span></p>
<p><span><span>AliSQL</span><span> does a lot of enhancement in the features and performance based on MySQL. It has more than 300 patches, We have added many monitor indicators, features, and optimized it for different user cases. enhancements from the other branches like Percona, MariaDB, WebScaleSQL, and also contains a lot of patches with Alibaba’s experiences. </span></span></p>
<p><span><span>In general test cases, AliSQL has 70% performance improvement over official MySQL version, according to R&amp;D team’s sysbench benchmarks. In comparison with MySQL, AliSQL offers: </span></span></p>
<ul>
<li>
<p><span><span>Better support for TokuDB, more monitoring and performance optimization.</span></span></p>
</li>
<li>
<p><span><span>CPU time statistics for SQL queries.</span></span></p>
</li>
<li>
<p><span><span>Sequence support.</span></span></p>
</li>
<li>
<p><span><span>Add Column Dynamically .</span></span></p>
</li>
<li>
<p><span><span>ThreadPool support. And a lot of Bugfix and performance improvements.</span></span></p>
</li>
</ul>
<p><span><span>The founder of MySQL/MariaDB, Michael Widenius “Monty” has praised Alibaba for open sourcing AliSQL. We got a lot of help from the open source community in the early development of AliSQL. </span></span></p>
<p><span><span>Now open source AliSQL is the best contribution we have made to this community. We hope to continue our open source journey in future. Full cooperation with the open source community can make the MySQL/MariaDB ecosystem more robust.</span></span></p>
<p><span><strong><span>ApsaraCache: </span></strong><span>ApsaraCache is based on the Redis 4.0, with additional features and performance enhancements. In comparison to Redis, ApsaraCache’s performance is independent of data size. It’s related to scenarios. It also has better performance in cases such as short connections, full memory recovery, and time-consuming instruction execution. </span></span></p>
<p><strong><span><span>Multi protocol support</span></span></strong></p>
<p><span><span>ApsaraCache supports both Redis and Memcached protocol with no client code need to be modified. ApsaraCache supports Memcached protocol and users can persist data by using ApsaraCache in Memcached mode just like Redis.</span></span></p>
<p><span><span>Reusing Redis architecture, we have developed new features of Memcache such as support for persistence, disaster tolerance, backup recovery, slow log audit, information statistics and other functions. </span></span></p>
<p><strong><span><span>Ready for production</span></span></strong></p>
<p><span><span>ApsaraCache has proven to be very stable and efficient during 4 years of technical grinding and tens of thousands of practical testing of production environment. </span></span></p>
<p><span><span>The major improvements in ApsaraCache are:</span></span></p>
<ul>
<li>
<p><span><span>Disaster depth reinforcement refactors the kernel synchronization mechanism to solve the problem of full synchronization of native kernel caused by copy interrupt under weak network condition.</span></span></p>
</li>
<li>
<p><span><span>Compatible with the Memcached protocol, it supports dual copy of Memcached and offers more reliable Memcached service.</span></span></p>
</li>
<li>
<p><span><span>In short connection scenario, ApsaraCache makes 30% performance increase compared with the vanilla version.</span></span></p>
</li>
<li>
<p><span><span>ApsaraCache’s function of thermal upgrade can complete the thermal update of an instance within 3ms and solve the problem of frequent kernel upgrading on users.</span></span></p>
</li>
<li>
<p><span><span>AOF reinforcement, and solve the problem of Host stability caused by frequent AOF Rewrite.</span></span></p>
</li>
<li>
<p><span><span>ApsaraCache health detection mechanism.</span></span></p>
</li>
</ul>
<p><em><span><span>This article was sponsored by Alibaba and written by Linux.com.</span></span></em></p>
</div>