Pushing a Feature On My First Day

October 04, 2013


One of my main reasons for joining Wealthfront was its engineering culture. After meeting the team as well as perusing the engineering blogs, I was excited to start working here.

So how did the first day fare?

Well I was setup with all of the major projects, finished work on a small feature for trading, attended a full day of engineering meetings, and pushed to production.

System Design

The best part about engineering here is the organization. I’ve been here for a few weeks now, and while I can’t claim to have a detailed understanding of the whole system, I do have a good sense of how it is designed. Everything is organized as a collection of services that are hosted on different machines. The services are then designed as a bunch of queries. What could have been a complicated system of the backend, trading engine, frontend, and the data platform among other projects is made simple and easy to learn because of this design.

For a newbie, the best place to start is the internal web page for the deployment manager. Along with status and recent commits for our integral projects, it also includes a list of services as well as information about their status. It’s easy to understand the basic skeleton of the Wealthfront engineering design from this one page.



Not only is the deployment manager a good explanation of the whole system, it also enables automatic and continuous releases. The deployment manager runs commands, or rather queries, depending on what hashtag you specify in your commits. One of these is automated releases, so instead of starting a building on Jenkins and deploying it to production for a release, I just need to specify #release in my commit and everything is handled for me as long as I have a well tested green build to verify my code. Likewise releasing a red build is made difficult so that we don’t release untested or failed code. The infrastructure is designed so that ideal behavior is promoted as well as practiced.

Test Driven Development

Another important aspect of Wealthfront engineering is that there is no QA (Quality Assurance…and not Question/Answer 😉 That’s because we believe quality is everyone’s responsibility. Having another group perform tests would implicitly imply that we don’t need to write well tested code, as well as mitigate our control over its behaviour. Hence, as cliched as it sounds, everything is tested thoroughly here. And by everything I don’t just mean the functionality of the code but rather how well it’s written. Before each commit, we run a series of tests to check if the code is ready for production. Some of the metrics tested are bad code snippets, forbidden calls, and verifying all queries are tested. Testing is done using JUnit and jMock, which is easy to use given the many examples in our codebase…even if you’re not familiar with it. And thus I was able to write this piece of code on my first day:

The above code mocks one of our services, CBUS, and our internal reporting class, ReportPublisher, and expects it to call the invoke and send methods, respectively. The expected arguments for those methods are specified using the matchers defined in the Expectations class as well as some of our own custom matchers using Hamcrest. JMock is exactly as the name states: a mockery of classes. Thus, we need to specify the methods, as well as the method arguments, we expect will be called. (For those interested in learning more about jMock, I’ve found the jMock cheat sheet a good reference point.)

Final Thoughts

Going back to my first day, while I didn’t work on a significant feature it did give me a good idea of the workflow as well as let me wet my feet in the codebase. Another win for me: working on the trading engine helped me a gain a nugget of information about the complicated world of finance, of which I had little to no understanding before Wealthfront.

In the time since, I’ve gotten exposure to the whole stack here by developing a feature end-to-end (backend, API server, as well as the front-end), done some ops work and helped launch Wealthfront.org. The best part is that there’s still a lot more to do and learn here, and I’m looking forward to it all.

P.S. The learning here isn’t all technical. If you need to learn parking, come join us and we’ll teach you Wealthfront parking…which I’ve found to be more difficult than parallel parking!