惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

C
Check Point Blog
O
OpenAI News
WordPress大学
WordPress大学
Jina AI
Jina AI
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
酷 壳 – CoolShell
酷 壳 – CoolShell
月光博客
月光博客
阮一峰的网络日志
阮一峰的网络日志
量子位
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园_首页
IT之家
IT之家
Last Week in AI
Last Week in AI
Vercel News
Vercel News
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
B
Blog
MongoDB | Blog
MongoDB | Blog
小众软件
小众软件
P
Proofpoint News Feed
Application and Cybersecurity Blog
Application and Cybersecurity Blog
MyScale Blog
MyScale Blog
Schneier on Security
Schneier on Security
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
N
News and Events Feed by Topic
Google Online Security Blog
Google Online Security Blog
N
News | PayPal Newsroom
Hacker News - Newest:
Hacker News - Newest: "LLM"
Google DeepMind News
Google DeepMind News
aimingoo的专栏
aimingoo的专栏
Apple Machine Learning Research
Apple Machine Learning Research
宝玉的分享
宝玉的分享
The GitHub Blog
The GitHub Blog
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
Recent Announcements
Recent Announcements
L
LINUX DO - 最新话题
TaoSecurity Blog
TaoSecurity Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
F
Fortinet All Blogs
罗磊的独立博客
Forbes - Security
Forbes - Security
人人都是产品经理
人人都是产品经理
J
Java Code Geeks
H
Heimdal Security Blog
Help Net Security
Help Net Security
V
V2EX
Security Latest
Security Latest
W
WeLiveSecurity
Attack and Defense Labs
Attack and Defense Labs
H
Help Net Security

Ivan on Containers, Kubernetes, and Server-Side

A grounded take on agentic coding for production environments Server-Side Playgrounds Reimagined: Build, Boot, and Network Your Own Virtual Labs [not a] Kubernetes 101 - Pods, Deployments, and Services As an Attempt To Automate Age-Old Infra Patterns JavaScript or TypeScript? How To Benefit From the Dichotomy Building a Firecracker-Powered Course Platform To Learn Docker and Kubernetes How To Publish a Port of a Running Container What Actually Happens When You Publish a Container Port A Visual Guide to SSH Tunnels: Local and Remote Port Forwarding Debugging Containers Like a Pro Docker: How To Debug Distroless And Slim Containers How To Extract Container Image Filesystem Using Docker | iximiuz Labs In Pursuit of Better Container Images: Alpine, Distroless, Apko, Chisel, DockerSlim, oh my! How To Start Programming In Go: Advice For Fellow DevOps Engineers Kubernetes Ephemeral Containers and kubectl debug Command How To Develop Kubernetes CLIs Like a Pro Docker Container Commands Explained: Understand, Don't Memorize | iximiuz Labs Learning Docker with Docker - Toying With DinD For Fun And Profit How To Extend Kubernetes API - Kubernetes vs. Django The Influence of Plumbing on Programming How To Call Kubernetes API from Go - Types and Common Machinery How To Call Kubernetes API using Simple HTTP Client Kubernetes API Basics - Resources, Kinds, and Objects OpenFaaS - Run Containerized Functions On Your Own Terms Learning Containers From The Bottom Up Docker Containers vs. Kubernetes Pods - Taking a Deeper Look | iximiuz Labs Learn-by-Doing Platforms for Dev, DevOps, and SRE Folks How HTTP Keep-Alive can cause TCP race condition How to Work with Container Images Using ctr | iximiuz Labs Multiple Containers, Same Port, no Reverse Proxy... Exploring Go net/http Package - On How Not To Set Socket Options Disposable Local Development Environments with Vagrant, Docker, and Arkade DevOps, SRE, and Platform Engineering My Choice of Programming Languages Prometheus Is Not a TSDB How to learn PromQL with Prometheus Playground Prometheus Cheat Sheet - Basics (Metrics, Labels, Time Series, Scraping) Rust - Writing Parsers With nom Parser Combinator Framework pq - parse and query log files as time series Prometheus Cheat Sheet - Moving Average, Max, Min, etc (Aggregation Over Time) Prometheus Cheat Sheet - How to Join Multiple Metrics (Vector Matching) The Need For Slimmer Containers Understanding Rust Privacy and Visibility Model Bridge vs. Switch: Takeaways from a Real Data Center Tour | iximiuz Labs From LAN to VXLAN: Networking Basics for Non-Network Engineers | iximiuz Labs KiND - How I Wasted a Day Loading Local Docker Images Go, HTTP handlers, panic, and deadlocks Exploring Kubernetes Operator Pattern Making Sense Out Of Cloud Native Buzz Service Discovery in Kubernetes: Combining the Best of Two Worlds API Developers Never REST How Container Networking Works: Building a Bridge Network From Scratch | iximiuz Labs Traefik: canary deployments with weighted load balancing Service Proxy, Pod, Sidecar, oh my! You Need Containers To Build Images You Don't Need an Image To Run a Container Not Every Container Has an Operating System Inside Working with container images in Go Master Go While Learning Containers Implementing Container Runtime Shim: Interactive Containers How to use Flask with gevent (uWSGI and Gunicorn editions) My 10 Years of Programming Experience Implementing Container Runtime Shim: First Code Implementing Container Runtime Shim: runc Kubernetes Repository On Flame Dealing with process termination in Linux (with Rust examples) conman - [the] Container Manager: Inception Journey From Containerization To Orchestration And Beyond Linux PTY - How docker attach and docker exec Commands Work Inside Illustrated introduction to Linux iptables From Docker Container to Bootable Linux Disk Image Пишем свой веб-сервер на Python: протокол HTTP 9001 способ создать веб-сервер на Python Explaining async/await in 200 lines of code Explaining event loop in 100 lines of code Save the day with gevent Пишем свой веб-сервер на Python: процессы, потоки и асинхронный I/O Truly optional scalar types in protobuf3 (with Go examples) Node.js Writable streams distilled Node.js Readable streams distilled How to on starting processes (mostly in Linux) Дайджест интересных ссылок – Июль 2016 Пишем свой веб-сервер на Python: сокеты Наследование в JavaScript Мастерить!
On Software Design... and Good Writing
Ivan Velichko · 2023-08-18 · via Ivan on Containers, Kubernetes, and Server-Side

Today, I came across a true gem: Akin's Laws of Spacecraft Design. Originally written for the aerospace engineering domain. I find many parts of it relevant for software engineers as well. Below, I share my thoughts on the Laws that resonate most with my experience as a software designer and tech blogger.

As it often happens, I discovered it through Matt Rickard's newsletter.

What DALL-E thinks the image for this blog post should look like.

What DALL-E thinks the image for this blog post should look like.

Level up your server-side game — join 20,000 engineers getting insightful learning materials straight to their inbox.

1. Engineering is done with numbers. Analysis without numbers is only an opinion.

For the better part of my career (spanning over a decade), I was producing system designs that most of the time weren't data driven. Only during my extensive preparation for passing a FAANG interview, I learned about the idea of "back-of-the-envelope calculations" and using math in general to define system requirements. Now, I almost never approach a problem without a clear understanding of the expected data volume, the load, and the required resources first, even when it means the design phase will be preceded by a non-trivial amount of exploration work including building ad-hoc tools and prototypes. And I'm still surprised by how often the numbers produced by such exploratory work prove my gut feeling on what an optimal design might look like wrong.

4. Your best design efforts will inevitably wind up being useless in the final design. Learn to live with the disappointment.

This happens to me more often than not. The hardest part was to learn to throw away this engineering "gems" and move on with the development. In my experience, it's less about regretting not including the closest to the heart parts into the final result and more about making the timely decision to cut them out when they stop meeting the new requirements or don't fit the evolving system well anymore.

8. In nature, the optimum is almost always in the middle somewhere. Distrust assertions that the optimum is at an extreme point.

I call it the "rule of balance" and it's quite universal. If a certain subsystem, or module, or even a single file is ten times bigger than average in the project, there is something wrong with the program's design. You may not feel the pain just yet, but eventually this imbalance will strike back. That's why I try to design "balanced" systems - it spreads the cost and the mental load evenly which in particular prevents the complexity from localizing and gaining a critical mass keeping it manageable. The same is true about writing - every sentence, every paragraph, every part of an essay should be more or less equally sized and loaded with an equal amount of information.

10. When in doubt, estimate. In an emergency, guess. But be sure to go back and clean up the mess when the real numbers come along.

Akin to Law No. 1. When requirements or constraints are too vague or you're experimenting, or urgently putting out a fire, or maybe just don't have a good idea how something that has to be done could be done in the right way, it's fine to "guess" and draft something seemingly functional but not quite meeting the quality and/or correctness bar. However, when things stabilize or after gaining more clarity on the requirements and constraints, a phase of "cleaning up" the mess is a must. For me, this rule is not just about keeping the tech debt at bay, it's also a vital technique to unblock the development in situations where otherwise you might find yourself stuck in analysis paralysis.

11. Sometimes, the fastest way to get to the end is to throw everything out and start over.

Keep this rule in mind, this might be the only way out of the mess introduced by following Law No. 10.

13. Design is based on requirements. There's no justification for designing something one bit "better" than the requirements dictate.

This is my favorite. Don't remember where I read it first, but I've been following this mantra for years. In my extended form: the program's functionality should be driven by use cases; the program's design should be driven by its functionality; the code structure should be driven by testability. It's very unlikely you'll be able to design something really future-proof. Unless you're designing it for the second time, but then the system is doomed because of other reasons.

14. (Edison's Law) "Better" is the enemy of "good".

Probably a remedy for the Second System effect (see above). This and Gall's Law (not in Akin's list): "A complex system that works is invariably found to have evolved from a simple system that worked. A complex system designed from scratch never works and cannot be patched up to make it work. You have to start over with a working simple system."

18. Past experience is excellent for providing a reality check. Too much reality can doom an otherwise worthwhile design, though.

It's vital to be pragmatic, but you also have to be an optimist and sometimes even a believer to succeed as a system designer.

20. A bad design with a good presentation is doomed eventually. A good design with a bad presentation is doomed immediately.

Surprisingly or not, if you want to influence fellow engineers, you have to be a good storyteller. Mastering only the hard skills won't be enough.

29. (von Tiesenhausen's Law of Program Management) To get an accurate estimate of final program requirements, multiply the initial time estimates by pi, and slide the decimal point on the cost estimates one place to the right.

The first time I've heard about this technique was more than ten years ago. Initially, I thought it's a joke. Working in the industry for a few years taught me it's no joke at all, but for way too long after that realization I was ashamed to use this estimation technique in my day job. Now I fully embrace it, and so should you.

30. (von Tiesenhausen's Law of Engineering Design) If you want to have a maximum effect on the design of a new engineering system, learn to draw. Engineers always wind up designing the vehicle to look like the initial artist's concept.

If there is a single skill more important than storytelling, it's drawing. I believe this blog gained most of its readership through its engaging, "never boring" technical diagrams. And to be honest, I do consider diagramming part of storytelling.

40. (McBryan's Law) You can't make it better until you make it work.

Reinforces Laws No. 13-14.

41. There's never enough time to do it right, but somehow, there's always enough time to do it over.

Reinforces Law No. 29.

43. You really understand something the third time you see it (or the first time you teach it.)

One of the main benefits of writing for me - that's how I learn (more) things and internalize them "for real".

On Writing

While writing this post, I ran into a derivative work called Akin's Laws of Article Writing - I've told you, writing is how you learn 😉

2. To write a perfect article takes an infinite amount of effort. This is why it's a good idea to write them to work when some things are wrong.

That's why I don't usually write mere How-To's. They don't age well when the underlying tech changes, and it always happens faster than you expect. When writing a technical blog post, in addition to covering the main subject, I aim to showcase my thought process and the tricks I employ to explore it. When the "hard" part of the blog post becomes obsolete, the "soft" part keeps its value for a few more years.

4. Your best writing efforts will inevitably wind up being useless in the final design. Learn to live with the disappointment.

How often do you see write-ups compiled of sections that don't really belong together (like this one 🙈)? Even if your historical excurse to containerization tech is superb, it doesn't go well with the rest of the tutorial on building container images - it's two different topics, go split them into separate articles. Or just throw the secondary part away (the latter is harder to accept though, I know).

9. Not having all the information you need is never a satisfactory excuse for not starting the writing.

Often, much of what ends up in my blog posts is actually discovered during the writing process not before it.

10. When in doubt, compose. In an emergency, scribble. But be sure to go back and clean up the mess when the facts come along.

Morgan Housel, one of my favorite contemporary authors, writes: "Whoever says the most stuff in the fewest words wins." And Julian Shapiro once complemented this in a now-deleted Twitter thread on good writing: "Draft to messily generate ideas and then rewrite, rewrite, rewrite..."

20. A bad article with a good presentation is doomed eventually. A good article with a bad presentation is doomed immediately.

As an author, it's crucial to master both the art of writing (content) and the mechanics of distribution (media). If only ten people read your perfect writing, it's a semi-wasted effort. You still gain from writing even when it happens for an audience of one, but the returns would be much higher with a successful social media game. One particularly important skill to master is titles - a good title is responsible for 80% of the future article performance on Reddit, Twitter, or Hacker News.

The list ends here. Draw your own conclusions.

Level up your server-side game — join 20,000 engineers getting insightful learning materials straight to their inbox: