当前位置:网站首页>Some views on libco
Some views on libco
2022-07-01 00:42:00 【51CTO】
I don't know when to start , I often think about a problem , That is, what is a good code ? Let's take a look at this description :
‘Good code’ is code that works, is bug free, and is readable and maintainable. Some organizations have coding ‘standards’ that all developers are supposed to adhere to, but everyone has different ideas about what’s best, or what is too many or too few rules. There are also various theories and metrics, such as McCabe Complexity metrics. It should be kept in mind that excessive use of standards and rules can stifle productivity and creativity. ‘Peer reviews’, ‘buddy checks’ code analysis tools, etc. can be used to check for problems and enforce standards.
Good code is that the code works normally 、bug Very few 、 And it has readability and maintainability . Some enterprises have their own coding specifications that all developers must abide by , But everyone has their own standards for what code is the best 、 Or there are too many or too few coding rules . There are many principles and Standards , for example ,McCable Complexity measure . Indeed, using too many coding standards and rules can reduce productivity and creativity .“ Peer review ” or “ Colleague inspection ” Code analysis tools, etc , Can be used to check problems or adhere to standards .
Yes , This passage answered my question , But in my opinion, this is still one-sided . My view on this issue is : Code that solves practical problems is good code . Whether it's redis,nginx Are benchmarks in this regard , They are all created by the author to solve practical problems due to his dissatisfaction with the current situation , And it does solve the problem . Not to say how difficult these two projects are , Find a willing college student , In the case of willing to study , I'm sure he can understand the codes of those two masterpieces . In this respect , In my submission libco It's a good project , Because it really perfectly undertakes the transformation of wechat background from semi synchronous and semi asynchronous to asynchronous , And the implementation of the code is commendable , The exquisite design of many places is really beyond the ordinary people's ability to complete .
But I think from the perspective of an open source project libco Not a good project . Because its official documents can almost be understood as 0, That is, nothing . I even suspect that libco The night before it was open source TX Our engineers are deleting comments line by line . Maybe the whole libco The comments of don't add up to a hundred lines . Secondly, actually libco Our community is at least github It's not very active , I mentioned a few issue, Handed in a few patch,issue Your answer is not what you asked ,patch I haven't received any reply after so long . You can see that the earliest update was half a year ago .
Of course, these are understandable , After all, the company may not pay more for doing this .
Reference resources :
- post 《 How to write code is good code 》
边栏推荐
- Redis based distributed lock
- Solving the weird problem that the query conditions affect the value of query fields in MySQL query
- Rust book materials - yazhijia Library
- When is it appropriate to replace a virtual machine with a virtual machine?
- 2022-2028 global capsule shell industry research and trend analysis report
- [UML] UML class diagram
- Manage edge browser settings (ie mode, homepage binding, etc.) through group policy in the enterprise
- On the application of cluster analysis in work
- Introduction to ES6 promise, new features of ES7 and es8 async and await
- 2022-2028 global weight loss ginger tea industry research and trend analysis report
猜你喜欢
![[designmode] factory pattern](/img/62/9be808b3e1c2139d564caa307fcd30.png)
[designmode] factory pattern

Random ball size, random motion collision

Deployment of mini version message queue based on redis6.0

【日常记录】——对BigDecimal除法运算时遇到的Bug

2022-2028 global mobile scanning radiology room industry survey and trend analysis report

HDU 2488 A Knight's Journey(DFS)

2022-2028 global retro glass industry research and trend analysis report

优质的水泵 SolidWorks模型素材推荐,不容错过

20220215-ctf-misc-buuctf-ningen--binwalk analysis --dd command separation --archpr brute force cracking

2022-2028 global carbon fiber room scraper system industry research and trend analysis report
随机推荐
Manage edge browser settings (ie mode, homepage binding, etc.) through group policy in the enterprise
Explain kubernetes backup and recovery tools velero | learn more about carina series phase III
Double linked list: initialize insert delete traversal
The principle of journal node
Inventory the six second level capabilities of Huawei cloud gaussdb (for redis)
Length of the longest integrable subarray
CTF tool (1) -- archpr -- including installation / use process
MySQL index test
Oracle-表的创建与管理
Yboj mesh sequence [Lagrange interpolation]
[designmode] factory pattern
2022-2028 global rotary transmission system industry research and trend analysis report
Redis - understand the master-slave replication mechanism
2022-2028 global mobile scanning radiology room industry survey and trend analysis report
From January 11, 2007 to January 11, 2022, I have been in SAP Chengdu Research Institute for 15 years
Rust controls Dajiang programmable UAV Tello
Ditto set global paste only text shortcuts
C # Generate PPK files in Putty format (passthrough support)
Never use redis expired monitoring to implement scheduled tasks!
给按钮的边框和文字设置不同的背景色