A softer transition is often preferable to a hard turn off. By way of instance, we disabled prior to shutting Etsy Wholesale off the ability for buyers to create new orders just one month. That gave sellers an opportunity to support the orders that remained on-platform, preventing a.
By 1000s of error logs per Day for wholesale, to less than 100 (finally we got this to zero)

To reduce danger, our intention was to maintain our commits small, but when attempting to delete so much code at once, it’s difficult to maintain your entire commits small. Deploying and testing was 50% of our team’s time. Our team made about 413 commits over five weeks, deleting 275,000 lines of code. That averages out to 630 lines of code deleted each commit, which have been deployed one at a time.
For Etsy Wholesale and Etsy Manufacturing, we had to remove the code piece-by-piece because it was closely integrated with other features on the website. One advantage of our continuous integration system is that we can try things out, neglect, and revert without negatively impacting our customers. This proved valuable as when we tried deleting the code massive commit, a few unit tests for the Etsy codebase started neglecting. We realized that time had been shaped over by dependencies involving the code. We made a decision to delete the code smaller, more easy to test, chunks.

We think of compliance when building new items, but it’s also important to keep in mind compliance requirements when you delete code. We need signoffs and reviews when we modifications to such documents. Because we did multiple commits, we had to do 44 SOX testimonials. This added to Every piece of deletion a few hours on average and approvals are required by each review by multiple individuals we did.   We considered in how to make retention decisions about products, how to make data readily available for export, and the way it impacts our terms and policies, user privacy and data protection.

Code Deletion Methodology:

 

During the process of sunsetting, we didn’t believe how busy different teams would be heading into the holiday season. This slowed down the process of getting code reviews approved. This became crucial because we had been removing and modifying chunks of code maintained by other teams.

Set Up Redirects

A little instance of dependencies creeping in where you least expect them.
Deleting so much code can be a difficult procedure. We had to revert changes from production five or more occasions, which, for the most part was straightforward. One of those five reverts was complicated by means of a data corruption issue impacting a small population of vendors, which required a couple of days of work to write, test, and run a script to resolve the issue.
When the communication had been done through mails, in-product announcements, and posts in the user forums, we started focusing on the execution. Prior to the day of every sunset, we utilized our attribute flagging infrastructure to construct a switch to disable access to the port for both Manufacturing and Wholesale. Feature flags are an essential part of the continuous installation process at Etsy. Feature flags reinforce the advantages of small changes and constant delivery.

Once we verified that all three products were no longer getting visitors, we kicked off the toughest aspect of this technology process: deleting all the code. We attempted to stage it in two parts, as tightly and loosely incorporated products.
After the Etsy Wholesale platform was switched off, we created data export files for each vendor and buyer with information about every order they received or placed throughout the five years that the platform was active. Storing and generating these files enabled the wholesale codebase to wash up without anxiety the portions of it would be required for exporting information.

Most of Us know how exciting it is to build new products, the thrill of a Heap of new ideas waiting to be tested, new Clients to reach, knotty Issues to Resolve, and Fantasies of upward-sloping Charts.   However, what happens when it is aligned with the trajectory of the company. While the group goes on to the next new enterprise often, infrastructure, code, and the product become a lower priority. In 2018, Etsy sunset Etsy Studio Etsy Wholesale, and Etsy Manufacturing.

We highly advocate sifting through attribute flags,  but a hard DNS redirect might be required in certain circumstances. The sunset of Etsy Studio was complicated by the fact that in the middle of this project, etsy.com has been migrated from on-premise hosting to the cloud. To decrease risk and complexity for the massive cloud migration project, Etsy Studio had to be closed off before the migration began. On the day prior to the cloud migration, a DNS redirect was made to forward any request on etsystudio.com to a unique page on etsy.com that clarified that Etsy Studio was being shut down. Once the DNS switch went , Etsy Studio closed off entirely.

  • Code Deletion: 275,000
  • Evaluation Coverage: We caused a small fall in test coverage metrics since the Etsy Studio project was well above average, while Etsy Wholesale and Etsy Manufacturing were just marginally below average.
  • System Complexity: Across 8+ Etsy systems: list management, listing page, payments, search indexes, authentication, member discussions, analytics, member services and also our International header user interface,
  • Operational hours: Saved 152 member service Hours per month and about 320 technology Hours per month

We measured success with these metrics:
There were also several other big projects in flight while we had been trying to delete code across our code base which slowed us down. 1 example I already mentioned was cloud migration: we couldnEtsy Studio using a config flag shuts off and we needed to work about it.

The origins that three goods had in our systems demonstrated the challenges in building and maintaining a standalone product alongside our core market. The many branching pieces of logic that snuck in made it difficult to reuse lots of existing code. By minding 275,000 lines of code, we were able to Decrease technology debt and eliminate roadblocks for engineers.   
On the afternoon of the sunset, all we needed to do was deploy a one line configuration switch and the item was shut off since there was a feature flag that controlled access to such products.

In this blog post, we’ll explore how we sunset these products at Etsy. This procedure involves a plethora of stakeholders including marketing, product, customer service, finance and several other groups, but the focus of the blog article is really on engineering and the real execution of the sunset.