News for hackers. Stuff that matters.
Re:Elon: Code is brittle. Need a complete rewrite by touringa on Monday March 06, 2023 @06:36PM (#35049435)
Re:Elon: Code is brittle. Need a complete rewrite by DonsDiscountGas on Monday March 06, 2023 @06:37PM (#35049456)
Beat me to it
Re:Elon: Code is brittle. Need a complete rewrite by Zigurd on Monday March 06, 2023 @06:50PM (#35049564)
"Second system syndrome" is what came to my mind. But I'm wicked old.
Re:Elon: Code is brittle. Need a complete rewrite by lamontcg on Monday March 06, 2023 @07:56PM (#35050082)
Actually its not going to be that.

That's when you've got something small that works and the rewrite is a bloated mess of every feature you could dream of.

This is the case where you've got an accumulation of over a decade of technical debt and Chesterton's Fences and someone who has no idea why the code is the way that it is inherits it and decides to rewrite it, and not knowing which constraints are necessary and which aren't they throw away most of them and find out the hard way that the problem isn't actually that simple.

It is almost the inverse of the second system syndrome.

But it is abundantly clear that Elon doesn't even know how to have this conversation.

Re:Elon: Code is brittle. Need a complete rewrite by Zigurd on Monday March 06, 2023 @08:47PM (#35050461)
In a sane acquisition a list of issues would have some out in technical dd. Not that Elon would have listened to anyone doing technical dd.
Re:Elon: Code is brittle. Need a complete rewrite by bmitc on Monday March 06, 2023 @08:22PM (#35050270)
It can be a legitimate strategy. Hard rules in software rarely work.
Re:Elon: Code is brittle. Need a complete rewrite by drks91 on Monday March 06, 2023 @08:27PM (#35050308)
Any successful example?
Re:Elon: Code is brittle. Need a complete rewrite by twelve40 on Monday March 06, 2023 @08:41PM (#35050419)
many years ago I worked on the windows firewall team at microsoft. it was common practice to get to a certain milestone of a project, then purposely ditch the code and start from scratch. I haven't seen this practice since then, but that part of windows was one of the least hated-on at the time.
Re:Elon: Code is brittle. Need a complete rewrite by bmitc on Monday March 06, 2023 @08:33PM (#35050357)
I've done it myself several times, but of course on projects small enough for a single developer. I also think the approach of rewriting bits and pieces over time works. You can identify pieces of the old code base that has well-defined behavior and can be split off with a well-defined interface between the new and old code. This has the added benefit of both needing to understand the old codebase and what you'd ideally want from a new codebase.
Re:Elon: Code is brittle. Need a complete rewrite by ojkelly on Monday March 06, 2023 @09:08PM (#35050623)
This is one of the foundational concepts behind microservices.

A service small enough that a team or engineer can rewrite it in a cycle/sprint.

When it’s bigger than that, you have the compounding effects of other systems that interact with each other.

Re:Elon: Code is brittle. Need a complete rewrite by object-a on Monday March 06, 2023 @09:57PM (#35050994)
For microservices, the "rewrite" fallacy usually takes the form of:

"Why are there so many small services running? Surely we can shut down / delete/ merge together a bunch of them to clean things up"

I'm pretty sure Elon has also hit this fallacy during his tenure at Twitter.

Re:Elon: Code is brittle. Need a complete rewrite by Jcowell on Tuesday March 07, 2023 @09:20AM (#35055611)
> "Why are there so many small services running? Surely we can shut down / delete/ merge together a bunch of them to clean things up"

It’s such a Weird fallacy since I feel like the entire point of Microservces is that there’s an inherit reason they’re microservices in the first place.

If you don’t know why, you investigate why. It feels far easier to make a monolith than a microservice.

Re:Elon: Code is brittle. Need a complete rewrite by bmitc on Tuesday March 07, 2023 @12:41AM (#35051991)
As a second thought, I think the move from .NET Framework to .NET 5+ could be considered a rewrite, and that has been rather successful on many fronts.
Re:Elon: Code is brittle. Need a complete rewrite by rogue7 on Tuesday March 07, 2023 @07:29AM (#35054574)
Facebook has done it with their iOS Messenger app

https://engineering.fb.com/2020/03/02/data-infrastructure/me...

Re:Elon: Code is brittle. Need a complete rewrite by loandbehold on Monday March 06, 2023 @08:28PM (#35050312)
Browser is lot more complex than Twitter.
Re:Elon: Code is brittle. Need a complete rewrite by object-a on Monday March 06, 2023 @09:53PM (#35050968)
I am extremely skeptical that Netscape 4 is a lot more complex than modern day Twitter.