Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blog: How Not to Break a Search Engine #3446

Merged
merged 10 commits into from
Jun 25, 2021
Prev Previous commit
Next Next commit
tagline
  • Loading branch information
rvantonder committed Jun 24, 2021
commit a039a3cef922b6ea0f3605a6affed617ec7abab4
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
title: "How not to break a search engine or: What I learned about unglamorous engineering"
rebeccadee marked this conversation as resolved.
Show resolved Hide resolved
description: "When we switched to a new search query parser in September 2020, you'd never know that
rebeccadee marked this conversation as resolved.
Show resolved Hide resolved
anything had changed. This is an account of the invisible, rigorous testing
that happened behind the scenes to make this seamless transition possible."
anything had changed. This is an account of the invisible, rigorous testing that
happened behind the scenes to ensure a seamless transition."
author: Rijnard van Tonder
authorUrl: https://twitter.com/rvtond
publishDate: 2021-06-24T10:00-07:00
Expand All @@ -29,9 +29,9 @@ for code:

<img src="https://storage.googleapis.com/sourcegraph-assets/about.sourcegraph.com/blog/2021/search-bar.png" style="width: 660px" alt="Code search input bar">

When the switch activated the new parser in September 2020, you'd never know that
anything had changed. This is an account of the invisible, rigorous testing
that happened behind the scenes to make this seamless switch possible.
When the switch activated the new parser in September 2020, you'd never know
that anything had changed. This is an account of the invisible, rigorous
testing to ensure a seamless transition.

The motivation for the change was to introduce standard boolean operators like
`and`, `or`, and `not` in queries. Sourcegraph had supported some of these
Expand Down Expand Up @@ -235,15 +235,15 @@ broke in order to get there. In hindsight, did I go overboard on some parts and
would I have done things differently? In short, no. New functionality was
rolled out iteratively and quickly in phases that users could freely try along
the way. I also enabled new implementations on our dogfood instance as things
matured. The core implementation probably took only two or three months, but
crossing the point of no return and removing the fallback was a slow and
thorough process. If I sensed that excessive testing was stunting progress and
delaying the planned timeline, I might feel differently, but I never got that
sense. And to be clear, I did more than rewriting and testing parsers in that
six-month time frame, but that's off-topic. Our current state isn't perfect,
there's more to tweak — but when the previous code was finally dropped, it
wasn't one of those typical anxiety-inducing rushes to hit a deadline. It felt
good and it felt right.
matured. The core implementation and testing probably took only one or two
months, but crossing the point of no return and removing the fallback was a
slow and thorough process. If I sensed that excessive testing was stunting
progress and delaying the planned timeline, I might feel differently, but I
never got that sense. And to be clear, I did more than rewriting and testing
parsers in that six-month time frame, but that's off-topic. Our current state
isn't perfect, there's more to tweak — but when the previous code was finally
dropped, it wasn't one of those typical anxiety-inducing rushes to hit a
deadline. It felt good and it felt right.

## In closing: Unglamorous engineering and you
rvantonder marked this conversation as resolved.
Show resolved Hide resolved

Expand Down