An engineer crashed Twitter, Musk: the code is too fragile, rewrite it all!

Organize | Su Mi

Produced | CSDN (ID: CSDNnews)

Many people were very curious. Since Musk took charge of Twitter at the end of October last year, he has made drastic reforms, especially after the number of employees has dropped from 7,500 employees at that time to about 2,000 this year. Why is Twitter’s system still working? Can it run so stably?

Sure enough, driven by the curiosity of too many people, the topic of “Twitter collapsed” hit the headlines of foreign technology websites. And the reason behind it was caused by an engineer’s misconfiguration, which caused the joint reaction.

“Twitter is down”

It happened yesterday morning. After logging in, many Twitter users found that the links in many tweets were invalid. Clicking on the links will no longer jump to the relevant pages. Instead, users will see a strange prompt message, “Your current API plan is not valid. Include access to this endpoint, see https://developer.twitter.com/en/docs/twitter-api for details”.

In addition to not being able to open the link, some people found that all the pictures could not be loaded.

Users also said they were unable to access TweetDeck, a Twitter account management tool.

It is reported that the interruption lasted for several hours, which also caused a large number of users to complain and complain on the Twitter platform. No pictures were loaded, so many people didn’t see the content at the time, and they made complaints about it.

Until 12:43 local time, Twitter’s services were gradually restored.

During the period, Twitter’s official response was long overdue, and only gave a vague explanation, saying that “some parts of Twitter may not work as expected at this time. We made internal changes that had some unintended consequences. We Working on this right now and will share an update when it is fixed.”

It is reported that Twitter has been less than a week away from the last system outage. The last time the system crashed after laying off dozens of middle and high-level personnel .

There is only one engineer behind the development of the paid version of the Twitter API

To investigate the cause of this system interruption, according to Twitter’s error message, it is mainly related to the Twitter API project.

In fact, at the beginning of last month, the Twitter official account announced that starting from February 9th, the free Twitter API will no longer be provided, including v2 and v1.1 versions, and a paid API will be used instead.

The reasons given at that time were:

Over the years, hundreds of millions of people have sent more than a trillion tweets, and billions are added every week.

Twitter data is one of the most powerful datasets in the world. We’re committed to fast and comprehensive access so you can keep building with us.

At the same time, the main reason Twitter wants to open the paid API is to bring the company back to life and achieve profitability. After all, Musk once said that Twitter’s cash flow almost became a negative $3 billion. Therefore, it is necessary to reduce costs and increase efficiency crazily.

It is reasonable for an enterprise to survive and realize revenue. However, according to foreign media Platformer, after several rounds of layoffs within Twitter, only one engineer was assigned to follow up the paid API development project. Separately, on Monday, the engineer made a “bad configuration change that basically broke Twitter’s API,” according to a current employee.

This also had a cascading chain reaction, causing many of Twitter’s internal tools to break down along with its public-facing API.

Musk is angry: the code is completely rewritten

The system crashed, which not only made the engineers burnt out, but also made Musk furious.

Below a screenshot posted by Silicon Valley investor and Twitter investor Marc Andreessen showing Twitter’s API crashing and gaining popularity, Musk angrily wrote, “A small change in the API has a huge impact. The code stack has nothing to do with it.” The rationale is so flimsy. It will eventually need a complete rewrite.”

Some current employees are frustrated, according to Platformer, who believe Twitter’s troubles are at least partly due to technical glitches before Musk took charge of the company.

“Twitter 1.0 has so much technical debt that if you make a change now, everything could break,” said one current employee.

When Musk initially took over the company, although he promised to improve the speed and stability of the website, and fired a group of “insufficient” engineers, there are currently less than 550 full-time engineers left at Twitter, which has led to today’s Bug There was a dilemma where no one rescued the field for a long time.

“That’s what firing 90 percent of the company does,” says a current employee.

More realistically, if the code is rewritten, Musk, as the boss, may also encounter a situation where no one will develop it. Therefore, under his comments, many users volunteered to sign up to help Twitter rewrite the code :

The text and pictures in this article are from CSDN

loading.gif

This article is rewritten from https://www.techug.com/post/an-engineer-crashed-twitter-musk-the-code-is-too-fragile-all-rewritten1a09afbc0d71464f1ee1/
This site is only for collection, and the copyright belongs to the original author.