这位挪威博士是如何成为阿里云PolarDB资深架构师的?

简介:挪威博士倾心传授对于软件架构师角色至关重要的经验,希望能指导和帮助各位技术同学实现成为资深技术架构师。

我叫Øystein Grøvlen,在过去的三年中,我一直在阿里巴巴PolarDB团队的优化器和执行器团队担任资深技术专家。我来自挪威,但在2018年来到中国杭州阿里巴巴公司, 一年后,我搬到了加利福尼亚州桑尼维尔的阿里巴巴公司办公室。

My name is Øystein Grøvlen, and for the last 3 years I have been working as a Senior Staff Engineer in the MySQL Optimizer & SQL group of the POLARDB team at Alibaba. I am originally from Norway, but moved to China to work for Alibaba in 2018. After living one year in Hangzhou, I relocated to Alibaba's office in Sunnyvale, California. 

我的软件开发之旅始于作为美国的一名交换生,在那里我在APPLE II电脑上接触到了BASIC语言。我发现我对能够创建自己的程序来解决不同的问题感到非常满足,这激发了我在Norwegian Institute of Technology的学习期间去学习计算机科学,我发现数据库和信息检索特别有趣,因此我决定在该领域攻读博士学位。我与挪威电信的研究部门取得了联系,最终在他们的研究项目ClustRa上工作了一段时间,同时攻读了基于Compensation-Based Query Processing课题的博士学位。

My journey as a software developer started as an exchange student in the US where I was introduced to programming in BASIC on APPLE II computers. I found it very satisfying to be able to create my own programs in order to solve different kind of problems, and this inspired me to study computer science at the Norwegian Institute of Technology. During my studies, I found databases and information retrieval particularly interesting, and I decided to pursue a PhD in that area. I came in contact with the research department at the Norwegian Telecom, and I ended up working part-time on their research project, ClustRa, while working on my PhD on Compensation-Based Query Processing

获得博士学位后,我开始在一家初创公司工作,该公司旨在将ClustRa数据库系统商业化。ClustRa是针对电信运营的高可用数据库系统。Clustra的体系结构与MySQL集群非常相似,你们中的许多人可能听说过。我们的工作重点是事务、分区、复制、故障容错和恢复。那是一段有趣的时光,解决了许多有趣的问题。不幸的是,当网络泡沫破裂时,我们耗尽了资金,但我们很幸运,Sun Microsystems决定收拾残局。在Sun公司,我继续在Clustra上工作了一段时间,然后开始使用Java实现的数据库Cloudscape的开源版本。当Sun后来购买MySQL时,我切换到MySQL上工作,并且获得了在优化器团队中工作的机会。Sun后来被Oracle收购,我在加入阿里巴巴之前,在Sun/Oracle从事了10年MySQL的工作。

After my PhD, I started working at a start-up that was set up to commercialize the ClustRa database system. ClustRa was a highly available database system targeted at Telecom operations. The architecture of Clustra was pretty similar to MySQL Cluster, which many of you may have heard about. The focus of our work was on transactions, partitioning, replication, fail-over, and recovery. It was a fun time, solving a lot of interesting problems. Unfortunately, we ran out of funding when the dot-com bubble burst, but we were lucky that Sun Microsystems decided to pick up the pieces. At Sun, I continued to work on Clustra for while, before starting to work on Derby, the open-source version of the Cloudscape, a database implemented in Java. When Sun later bought MySQL, I switch to work on MySQL, and I got the opportunity to work in the Optimizer team. Sun was later bought by Oracle, and I worked on MySQL at Sun/Oracle for 10 years before joining Alibaba. 

我发现从事查询优化和处理真的很有趣。我最喜欢的部分是研究如何让查询运行得更快。PolarDB基于MySQL代码,因此我可以运用已有的优化器的经验来使PolarDB成为更好的产品。我觉得为PolarDB团队工作特别有意义的是,阿里巴巴愿意为PolarDB投入大量资源。我们有一大群人在改进产品,我认为我在这里工作的这段时间,我们能做的事情是令人惊叹的。我大部分时间都花在支持并行查询处理项目上; 而MySQL只能使用一个线程来执行查询,PolarDB可以将查询执行划分为多个线程并行执行。

I find it really interesting to work on query optimization and query processing. My favorite part is investigating how we can get queries to run faster. POLARDB is based on MySQL code, so I can use my knowledge about the MySQL optimizer to make POLARDB a better product. What I find particularly rewarding about working for the POLARDB team, is that Alibaba is willing to put a lot of resources into POLARDB. We have a large group of people working on improving the product, and I think it is amazing what we have been able to do while I have been here. Most of my time I have spent on the project to support parallel query processing; while MySQL can only use one thread to execute a query, POLARDB can partition the query execution across multiple parallel threads. 

我会被问到是否可以给其他研发人员提供一些建议,指导和帮助他们实现成为资深技术架构师的职业目标。

我认为有许多不同的成功之路,有些人可能会认为,一部分可能是因为幸运地在正确的时间出现在正确的地点。但是,根据我的经验,我想讨论一些我认为对于软件架构师的角色至关重要的方面。

I have been asked to give some advice to other developers on what it takes to make a career as a senior architect. I think there are many different paths to success, and some may claim that part of it may be the luck of being at the right place at the right time. However, based on my experience, I will discuss a few aspects that I feel has been essential to prepare myself for the role of software architect.

深入研究 Make deep dives

我认为学习一个软件系统是如何工作的唯一方法就是深入代码进行研究。不要假设你理解代码是如何工作的,而是要通过跟踪执行过程或使用调试逐步执行代码来验证它。

I think the only way to learn how a software system works, is to deep dive into the code. Do not just assume that you understand how the code is working, verify it by tracing the execution or stepping through the code with a debugger. 

我遇到了很多开发人员,当遇到错误时,不去对代码的工作原理有很好的了解,而是尝试不断反复试错来走捷径。他们可能会成功地修复这个BUG,但是他们对代码是如何工作的知之甚少。很多时候,这种方法还导致了似乎可以解决BUG的修复,但是潜在的问题可能仍然存在。不要只是满足于所有测试成功,要通过跟踪/调试验证它是否按预期运行。第一次可能需要更长的时间完成工作,但是当你在同一领域被分配另一项任务时,你就会非常受益。

I have met quite a few developers that when faced with a bug, instead of getting a good understanding of how the code works, try to take short-cuts based on trial and error. They may succeed in fixing the bug, but they have learned very little about how the code works. Many times this approach also leads to bug fixes that seems to solve the problem, but the underlying problem may still exist. Do not just be satisfied when all your tests succeed, verify by trace/debugger that it runs as expected! It may take a bit longer to get the job done the first time, but you will get the reward later when you are assigned another task in the same area.

Optimizer Trace is a great tool to learn about the MySQL Query Optimizer

通过示例学习 Learn by example

每个人是不同的。我发现通过执行一些特定示例来学习新代码更容易,然后推广这种方法。有些人可能仅通过阅读就成功地理解了代码,但是我想我的心智还没有达到这个水平。

People are different. I find it easier to learn new code by following the execution of some specific examples, and then generalize from that. Other people may be successful in understanding the code just from reading it, but I guess my mental capacity is not at that level.

我在ClustRa的第一个任务之一是让事务回滚成功。这个任务的大部分代码已经完成了,但是仍然有一小部分缺失了。通过仔细跟踪事务的执行情况,我花了很长时间才发现缺失的部分并使其正常工作。我认为,如果我仅通过阅读代码来识别缺少的部分,那将花费我更长的时间。

One of my first tasks at ClustRa was to make transaction rollback work. Much of the code was already prepared for the task, but there was still some missing pieces. By carefully tracing the execution of a transaction, it did not take me long to identify the missing pieces and make it work. I think it would have taken me much longer if I were to identify what was missing just by reading the code.

不要害怕问 Be not afraid to ask

当你偶然被一个问题绊住时,不要害怕问你的同事。分享你对问题的理解,并征求他们的意见。大多数开发人员非常乐意分享他们所知道的。但是,在提出问题之前,请确保你已经付出了一些努力来理解问题。否则,你的同事可能会觉得你只是想让他们做你的工作。

When you stumbled on a problem, do not be afraid to ask your co-workers. Share your understanding of the problem and ask for their advice. Most developers are more than happy to share what they know. However, make sure you have put some effort into understanding the problem before you ask. Otherwise, your co-workers may feel you are just trying to make them do your job.

分享你的智慧 Share your wisdom

与你的同事分享你的知识。欢迎他们提出问题; 在这个过程中,你经常会学到一些东西。

Share your knowledge with your co-workers. Welcome their questions; you will often learn something yourself in the process。

另外,在技术文章中记录你的工作内容,并寻求机会在公开场合分享。这是让其他团队或公司以外的人了解你和你的工作的好方法。

Also, write about your work in articles and blog posts, and seek for opportunities to talk about it in public. This is a good way to make people outside your team or company aware of you and your work. 

了解你的用户 Understand your users

我发现许多开发人员在理解用户需求方面投入的努力太少了。通常开发人员更喜欢要么快速直接的解决方案,要么在技术上更 “有趣”,而不是解决实际问题。问问自己:“这将如何使用?”,“选择的交互对用户实用吗?”,等等。

I feel many developers put too little effort into understanding the needs of their users. Often the developer prefer solutions that are either more straight-foward to implement, or more technically "interesting", over solving the real problem. Ask yourself: "How will this be used?", "Will the chosen interface be practical to the users?", and so on.

在开始设计之前,最好指定一些客户场景,来描述将如何使用此新功能以及它将解决什么问题。

Before starting the design, it is a good idea to specify a few uses cases that describes how this new feature will be used, and what problem it will solve.

保持耐心 Stay around

成为技术、产品或代码库的专家需要时间。我花了很多年才认为自己是MySQL查询优化器的专家。虽然拥有丰富的经验当然很好,但我认为如果你经常换工作或技术,你将错过获得深刻见解的机会,而这是自己成为专家的必要之路。换句话说,要有耐心,并为自己设定长期目标!

It takes time to become an expert on a technology, a product, or a code base. It took me several years before I could consider myself an expert on the MySQL query optimizer. While it is certainly good to have a wide experience, I think that if you change jobs or technologies too often, you will miss the opportunity to get the deep insights that will be necessary to establish yourself as an expert. In other words, be patient, and set long-term goals for yourself! 

相关阅读:

删库跑路?别怕!PolarDB-X 轻松拯救误删数据的你

阿里13篇论文入选数据库顶会 PolarDB创新技术架构获认可

上海ACE同城会演讲实录|云原生分布式数据库PolarDB-X

PolarDB-X 是如何用15M内存跑1G的TPCH

顶会点赞!PolarDB Serverless实现了哪些突破?

云原生分布式数据库PolarDB技术深度解密

版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。

你可能感兴趣的