News for hackers. Stuff that matters.
Re:Ask HN: How to Learn Software Architecture? by armchairhacker on Monday April 04, 2022 @08:33PM (#30913819)
You mean like good design?

I think the best way is unfortunately just experience. Design patterns are just that, patterns, and you learn and sort of internalize them when you work on real projects.

You can also look at open-source projects with good architectures like LLVM, lichess, etc. (there are other threads with a list of these).

The most important thing to understand IMO is that there’s no one-size-fits-all architecture, and a great architecture vs a “better” architecture isn’t that different and not worth wasting too much time. A small project will burnout using Google’s practices and a Google-sized project will fall apart using small-company practices. If you plan on making your own app, definitely sketch out an idea of the architecture before you start building it, but don’t spend too much time or worry too much because it’s more important that you actually start.

Re:Ask HN: How to Learn Software Architecture? by _vdpp on Monday April 04, 2022 @09:32PM (#30914261)
A professor told me “The key to good design is experience. The key to experience is bad design.”
Re:Ask HN: How to Learn Software Architecture? by auspex on Monday April 04, 2022 @10:28PM (#30914677)
I think if you:

1) Don’t use global variables 2) Use interfaces liberally 3) Assume implementations will need to change

This gets you a lot of the way there.

Re:Ask HN: How to Learn Software Architecture? by Jensson on Monday April 04, 2022 @11:41PM (#30915075)
Those are guidelines for writing code, not for doing software architecture.
Re:Ask HN: How to Learn Software Architecture? by xupybd on Tuesday April 05, 2022 @12:16AM (#30915242)
Very true but poor code can undo good architecture.

A good plan is to keep the code as tidy as you can.