by jiggawatts · 3y ago · 0 comments
They developed their own custom database, a shitty key value store that didn’t even have transactions because “Oracle doesn’t scale and it’s too expensive”. They couldn’t make reporting work so they copied the data hourly to Oracle anyway. (It turned out that Oracle does scale.)
They also invented their own RPC protocol, had their own threading library, used an obscure build system, an even more obscure SCM, etc…
Nothing was standard. It was all bespoke, webscale, and in-house.
When I started there as a junior they had me fix bugs in their code. Instead, I would simply delete thousands of lines of spaghetti and replace it with a call to a standard library. It was like spitting into a volcano to put out the fires of hell itself. There was no hope.
They burned $10M and made $250K revenue and collapsed.
Their competition used Oracle, ordinary tooling, and made tens of millions in profit.
And you know what? It worked amazingly well. I'm not just talking about scale, but also about how much any single developer seemed to be able to do. Their tools and APIs were tastefully designed, tailored to their own needs and fit together remarkably well. I remember that they were consistently building things with just one or a handful of people that would have taken multiple teams at other organizations I've seen.
Looking back, that was a remarkably productive engineering environment because of how much they were willing to do themselves. The key insight is that building something for yourself is qualitatively different from building something for external consumption or using something general-purpose that already exists. You naturally tailor the code and tools to what you need, which is much easier than building something for what you think other people might need—and, surprisingly often, easier than bending a different tool to your own ends.
But, perhaps more importantly, you develop a shared mental model of the system you're developing and how it fits in with everything else that you are doing. That shared mental model is, ultimately, worth far more than the code by itself... but it isn't legible to management, so it's hard to foster and preserve without a strong engineering culture backing it up.
The other lesson I took away from that experience (and others!) is that the high-level questions people focus on ("buy vs build", "monorepo vs polyrepo"... etc) are nowhere near determinative. Whether or not any given approach works out comes down far more to the little details and nuances of what you're doing and how you're doing it, as well as a healthy dollop of circumstances beyond your immediate control.
At the end of the day, if everything else was the same, but the startup you're talking about was using perfectly standard and popular tools, would you expect the outcome to be any different? I've seen far too many Enterprise-grade trash-fires to believe that. If the core dynamics that led to a mess don't change, you can have a "not invented here" mess or an "Enterprise Best Practices" mess or a "buy everything, build nothing" mess—but there's no simple strategic direction that won't get you some kind of mess.
And they're in a market where a tiny competitive edge can reap large rewards.
They're rather the exception that proves the rule.
I'm sure all their competitors do the same for the same reasons. But for companies that view software primarily as a cost centre, I can see it going horribly wrong.
Trading firms tend to build a lot of their own tech, but Jane Street is special in that they build almost everything in house. Ocaml is practically their own language. No other competitor comes close to this level of owning the entire ecosystem, including programming tools.
> shared mental model of the system you're developing and how it fits in with everything else that you are doing. That shared mental model is, ultimately, worth far more than the code by itself... but it isn't legible to management, so it's hard to foster and preserve without a really strong engineering culture backing it up.
Sounds awesome, did they have engineering leaders with long tenure?
They're big on FP and OCaml and do a lot of open source work around OCaml, and have done for years.
Speaks to consistent leadership.
In a manner of speaking, yes.
I imagine it's the quality of the team that matters, not the factors that go into whether or not to build bespoke in-house.
Jane Street is operating in a market where there are few off-the-shelf tools, the tools are your competitive edge, and hence it makes sense to design your own. Similar-but-different tools won't work, at all.
The place I worked at were doing the same thing everybody else was. They were making a pre-digital business digital, just like everybody else in the 2000 dot com boom. All the same off-the-shelf solutions applied. The secret sauce was the niche market, legal loopholes, and first-mover advantage.
The custom DB vs Oracle thing is a great example. The startup saved no money by developing a custom system, because they had to license Oracle anyway. They gained no scalability advantage, because Oracle scaled to their required level just fine. There's no edge there to be gained over the competition. Worse still, they wasted 3+ years developing their own system, which gave their competition a head start.
My (100% outsider's) impression is that the focus, culture and teams at Goldman Sachs are totally different now thanks to market and regulatory changes, and that it is not a good place to work in a primarily technical sort of role any more.
I'd guess this is also an area where the Dunning–Kruger effect and misaligned developer incentives are involved. Inexperienced teams are more likely to take on reinventing the wheel. When you're starry eyed it can sound fun, plus its a great opportunity to do some resume building.
But as folks become more experienced, they can end up salty and disheartened. If you've been around the block a few times writing your own database might no longer sound so exciting. Plus life has become comfortable, you've mastered the tools and aren't really all that interested in taking risks so it's easier to just recommend IBM or Oracle.
Both scenarios aren't really all that great.
Maybe Jane Street and their ilk are just better at rewarding risk while simultaneously providing strong mentorship opportunities (I see the intern projects).
> they were consistently building things with just one or a handful of people that would have taken multiple teams at other organizations I've seen.
> you develop a shared mental model of the system you're developing
How much of this was due using OCaml?
Despite some language-specific quirks, trying Elm has almost convinced me that dynamic typing is a mistake for any parts of a project which don't need to be used from a REPL context.
In particular, I've found that having an expressive type system makes it easier to develop and communicate this kind of mental model, as well as to maintain a close mapping between the concepts you use to understand the system and the code itself. I'm convinced that this is a powerful approach that can be incredibly effective and is hard to reproduce in "normal" languages, but it's hard to state this too confidently since it is entirely based on my own qualitative experience with programming.
Do you have any recommendations or warnings regarding general languages which reach in the opposite direction? Reason[1] and F#[2] are both examples: they attach pre-existing ecosystems and compile-for-$PLATFORM tools to OCaml-like typing.
OCaml itself is also intriguing. However, I'm concerned that suggesting it for non-personal projects will go over poorly. The "GPL" in its standard library's LGPL license may scare people despite both the linking exception and Jane Street's MIT alternative.
This is the most important thing I've learned working for 15 years in tiny SV startups as well as the most successful company in the history of capitalism.
The main problem is you can't really teach what all those little details and nuances are (the tao that can be told...). You have to live it and experience it. Over time, you meet people who Get It (the founder of the aforementioned called them "A players"), and people who don't.
All you can do is focus on doing great work with the people who Get It, cutting those who clearly won't/don't, and investing mentorship in young people who seem like they're on a path to it.
The worst companies I have ever worked for didn’t have the skills to do it.
So yet again it depends on the quality of your developers. Not how you do things.