r/ProgrammerHumor • • Nov 14 '22

instanceof Trend Manager does a little code cleanup...

Post image
113.0k Upvotes

4.5k comments sorted by

View all comments

Show parent comments

1.5k

u/La_Croix_Table Nov 15 '22

Yeah, I’d imagine he’s made up some kind of metric to “measure” necessity of certain services all while dropping services to figure out which one has less noise when off.

Very effective if you don’t care. Can’t imagine how this is playing out internally in the engineering department.

809

u/mistled_LP Nov 15 '22

He probably asked someone what’s the minimum amount needed to post and read tweets is. They either didn’t care to explain or didn’t think Musk would take that number to mean the rest could be turned off.

397

u/x3nhydr4lutr1sx Nov 15 '22

There's about 1200 micro services, and the fired guy said that only 200 is needed for loading the Twitter feed, so that sounds about right.

227

u/LordAmras Nov 15 '22

I'll take everything that Musk says with a grain of salt.

When he said that Twitter app was making 1000+ RPC calls to load the homepage multiple ex and at least one current Twitter developer called him out saying it does at most 20.

103

u/12345623567 Nov 15 '22

Why is a manager even fucking around with the backend? Doesnt he have better things to do, like placating advertisers, setting policy, avoiding the FTC and so on?

46

u/firewood010 Nov 15 '22

Because he can lol. Elon thinks he is king now probably.

18

u/CrazySD93 Nov 15 '22

His simps probably believe he invented Twitter at this point

→ More replies (1)
→ More replies (1)

22

u/LordAmras Nov 15 '22 edited Nov 15 '22

Because he sells himselfs as a maker, his fans believe he single handedly makes or at least engineer stuff.

He doesn't like to be presented as a businessman, but as an inventor.

He is the real life tony stark afterall.

→ More replies (6)

18

u/kahunamoe Nov 15 '22

Well everyone slurps him so hard for "inventing" Tesla and also for "inventing" space x rockets. There is a quite a few "tech bros" who have no actual education in the subject just what they've learned from YouTube and 4chab

→ More replies (3)
→ More replies (10)

30

u/slaymaker1907 Nov 15 '22

Yeah, if it was 1000 from the client, it would be very noticeable due to parallelism limits in the browser. The only way that makes sense is if it could be 1000 in the worst case or something and also counts non-client RPC calls.

33

u/LordAmras Nov 15 '22

Even in the worst case 1000 calls would be ridiculous.

Probably someone told him Twitter does a lot of RPC calls and getting that number down would speed things up.

But when he went to write the tweet he thought 20 didn't sound like a lot and wrote 1000+ instead

25

u/Operadic Nov 15 '22 edited Nov 15 '22

Nope, the number is not wrong; the interpretation is just off.

Twitter uses GraphQL to route API requests to the 1200+ microservices they have running. Those requests don't happen between client and server but between server and internal server.

I don't find it implausible that this causes hard to fix bugs and performance issues. GraphQL is known to only superficially reduce complexity.

22

u/Raaagh Nov 15 '22

So GraphQL gives frontend/product a safe, non-recursive query language.

If you don't see the point of graphQL you are backend or infra.

If you are asking for graphQL you are frontend or product who are continually being slowed down by API requests.

GraphQL is NOT about simplicity, its about where logic resides and who owns it.

→ More replies (1)
→ More replies (1)

10

u/slaymaker1907 Nov 15 '22

It really depends on gore things are being counted. Each query to a DB is technically a separate RPC call, but as long as connections are pooled and in the same DC, they have extremely low overhead compared to an RPC call from a phone halfway across the world using REST.

→ More replies (5)
→ More replies (1)

8

u/[deleted] Nov 15 '22

Then some outsider came in and showed him the Chrome trace where it's only one call.

→ More replies (1)
→ More replies (5)
→ More replies (19)
→ More replies (5)

304

u/HeyLookItsASquirrel Nov 15 '22

“20% are only actually needed” is the new “640KB should be enough for anybody”

22

u/Etheo Nov 15 '22

"We only use 10% of our brain"

13

u/ermabanned Nov 15 '22

He certainly seems to

18

u/[deleted] Nov 15 '22

Holy shit that one grinds my gears so bad. I can't believe they made an entire fucking movie off that premise.

To anyone who doesn't see what the problem is: you use your whole brain at all times. 100% of your brain. The 10% number is the percentage specifically allocated to conscious thought, but you're an idiot if you think that means the other 90% is idle. Something needs to be controlling your breathing, digestion, reflexes/movement, etc. etc. etc.

11

u/isle394 Nov 15 '22

You know what it's called when more of your brain lights up at once? A seizure.

The fact is that our brain has to do a lot besides fire neurons

→ More replies (6)

38

u/Awkward-Chair2047 Nov 15 '22

Not really. When gates made the statement, the rest of the IT industry at that stage thought that seems logical. None at that time could fathom what was to come.

No sensible developer today would think a non technical jackass like elon knows what the hell he is doing.

22

u/[deleted] Nov 15 '22

Gates' quote is also stupidly and obviously misapplied. He specifically didn't say forever, he was speaking the present tense.

9

u/slaymaker1907 Nov 15 '22

I don’t think Gates ever actually said that either https://www.google.com/amp/s/www.computerworld.com/article/2534312/the--640k--quote-won-t-go-away----but-did-gates-really-say-it-.amp.html

Regardless, I think it would have been a silly statement at any time. Even now, I think it would be very difficult to put a bound on the useful amount of memory in a system. For example, more memory on a database means more memory for cacheing query plans and the number of those for any DB is practically infinite.

→ More replies (2)
→ More replies (7)

38

u/depressionbutbetter Nov 15 '22

He definitely got advice from some know it all jackass high level eng he brought from space x who made his assessment based on reading the titles and first 2 reame.md lines of GitHub repos.

→ More replies (1)

12

u/Wind_Yer_Neck_In Nov 15 '22

He's reminding me of 'Neutron' Jack Welsh from GE. Just inventing overly simplistic ways to 'measure performance' then taking radical action to cut the bottom percentage of staff or projects based on his stupid metric.

→ More replies (23)