In this episode of To Be Continuous, Edith and Paul are joined by Sean Byrnes, CEO of Outlier.ai, and Nadia Eghbal. The group discusses open source economics, and examines several potential evolutions of adding money to the open source equation. This is episode #17 in the To Be Continuous podcast series all about continuous delivery and software development.
In this episode of To Be Continuous, Paul and Edith host Sam Stokes, cofounder of Rapportive, to discuss empathy in software development, the tendency for micro services to become mini services, and the act of constantly updating software in a constantly updating world. This is episode #9 in the To Be Continuous podcast series all about continuous delivery and software development.
This episode of To Be Continuous, brought to you by Heavybit and hosted by Paul Biggar of CircleCI and Edith Harbaugh of LaunchDarkly. To learn more about Heavybit, visit heavybit.com. While you’re there, check out their library, home to great educational talks from other developer company founders and industry leaders.
Paul: Alright, Sam, so what’s your favorite thing about continuous delivery?
Sam: I like to think about it terms of shortening feedback loops. A lot of things that startups do can basically be looked at as doing something and then waiting to get some feedback on it, and then deciding whether to do more of that thing or to do a different thing.
And continuous delivery is, people talk about sort of reducing the batch size and also about shipping stuff faster and clearly having some kind of automation. And continuous delivery is going to help you with both of those things.
Paul: So is this specifically on the, sort of on the journey of a small startup towards product market fit? Is that kind of the sense you’re thinking of it as?
Sam: I see it as applying to teams of different sizes. So for sure in a small startup you’ve got you need to iterate fast, you’ve got all these product ideas. But I think even if you’re a small team in a big company as I was recently working on, and still have a lot of the same pressures you have, product managers who want to try new ideas, you have customers who are sending in feedback all the time—some of which you want to listen to, some of which you want to tune out.
It’s sort of, in some ways, a lot like being in a startup. At least, ideally it would be. And a lot of the problems you can run into are basically about not being able to close those loops quickly enough.
Edith: Sam you’re someone who knows a lot about loops, so now might be a good time to introduce yourself.
Sam: Sure, my name is Sam Stokes. Until recently I was working as a staff software engineer at LinkedIn. And right now I am, I guess a freelance software consultant, thereabout.
Paul: I feel there’s a little bit of history missing there.
Sam: Alright. Going back in time a little bit. So I was a co-founder of a startup called Rapportive. That was a plugin for Gmail that when somebody emailed you, would show you a social profile of that person in the right-hand side next to their email.
So that you could get some insight into who you were talking to and put some more humanity into your communications with people—that’s sort of the way we saw it.
Paul: That’s still the only plugin to Gmail that I use.
Edith: I use it, too, and it’s for exactly that reason, ’cause I do a lot of customer development, and it helps so much to do, to empathize. To see that this—
Paul: Right, right, yeah is a real person.
Edith: You know, to see their face and you feel a connection.
Paul: It’s interesting just with kind of customer communication. One of the tools that we use is Intercom. And once I started using Intercom it was the same sort of feeling I got the first time I used Rapportive, that like I feel that there’s a human at the other end of this and I feel I know who that human is and it just changes how you communicate with the people.
Sam: It’s really motivating to hear and to see other examples as well. We really felt like email and sort of a lot of business communication in general can be sort of cold and formulaic.
Yeah, just bringing that human element, even just seeing a face. I haven’t used Intercom but I’m guessing they have some similar ideas.
Paul: Similar, when you send out messages or reply to someone it does the person’s face there.
Sam: Right, we had a sort of plugin API in the, it was a sort of private beta version of our product and one of the things people used it for, so this would let you plug into the sidebar, people would plug it into their customer database and so they could see something like, they’d get an email from a customer it shows them how long they’ve been a customer, how much they’ve spent in their store—
Paul: Right, right.
Sam: What version of the app they’re running, that sort of thing.
Edith: Was your original idea to do that sort of empathy or was that something that just you iterated into?
Sam: The empathy was where we started. There were lots of ideas about taking all the information from all these different sources, you know public sources like, truly public sources like Google, quasi public sources like a Facebook profile if you’re friends with them on Facebook, and then private sources like stuff in your company database.
All stuff that you would be able to search for if you could be bothered to go and do the searching but doesn’t necessarily bring itself to you while you’re talking to that person. And yeah, it was very much, what should you know when you’re talking to this person in order to make them feel like they’re interacting with a real person and an empathetic one.
Paul: So I remember when you launched Rapportive it was like, or it felt to me like it was, an instant hit and maybe that was just the overnight success that comes after years of trying. I had a doco and what was the kind of software delivery process of that?
Sam: Hmm, that’s a great question. I guess there’s two parts to that really. So how did it get there and what was our process that allowed us to survive it? So I guess how did we get there, it was a certain amount of luck in that process as there probably always is. We built our prototype and it was a pretty minimal prototype.
You know, it had the functionality that was like this awful demo website up. The only reason there was a website up was we were trying to raise a seed round at the time, we were applying to OIC. Y Combinator requires that you have a demo site that’s public. They don’t like it to be password-protected. And so we had this thing up where you could install it and we had like 20 users. One of our friends decided that he was going to email a friend of his at one of the blogs, I think it was ReadWriteWeb and say, you know, hey you should check this out.
And his friend checked it out and it turned out that one of the demographics that really liked the product that we built was journalists because they get a lot of emails from people they don’t know and they want to sort of know an extra nugget. I guess that was one of our takeaways was like, if your startup is really useful for journalists, that’s a great way to get some early press.
Edith: That’s what worked for TripIt because journalists travel a lot. So TripIt just got all this free press basically ’cause journalists used it, loved it, and blogged about it. Unfortunately, journalists do not do continuous delivery so much.
Sam: So how do we survive that? ‘Cause what happened in that 24-hour segment was that we went from 20 users up to 20,000.
Sam: So I guess one part of it was our CEO had made the original platform choice. His name’s Rahul Vohra, he has a computer science degree, he’s an awesome technologist, but his focus is not generally on writing the software. He’d been writing the prototype, and he was like, ‘I need the quickest thing that I can get to get this market, so I’ll put it on Heroku.’
Which turned out to be a life-saving decision because when the 1,000 X traffic spike arrived we just added some more dynos. So that was how we didn’t burn down. What did we do after that? I guess in terms of software process we were pretty young as a company, so it was pretty much hack away, read all the tweets. But there was a lot of, what you might call customer development more than software development at the time. So we pretty quickly decided that we were going to try and respond to every single tweet and every single email and so on to like try and live this idea of a good customer experience.
And I think that helped to sort of amplify the viral effect of that press spike because people were sort of retweeting the things we were saying and getting a generally good feeling about us.
And so a lot of those tweets were like, ‘Oh I wish I did this,’ or ‘I wish I did that,’ or ‘I wish you could see Twitter profiles in there.’ So it was a little bit of sort of customer support-driven development. Which obviously doesn’t scale but it can be a pretty good way to build some goodwill early on.
And I think a lot of our users were sort of quite passionate about using us, ’cause they felt like they got that personalized attention.
Paul: So did the, when you scaled the dynos did it just work?
Sam: It worked perfectly until we hit the rate limit for the API that we were getting all our data from.
Paul: The LinkedIn API?
Sam: At the time we were using a service called RapLeaf.
Paul: Oh yeah, yeah, I remember them.
Sam: It wasn’t their main product, but they provided an API which … So basically the thing that Rapportive does, which is take an email address and produce social profiles about that email address. At the time that was entirely just UI wrapped around RapLeaf. We ended up building sort of our own version of that.
And so we’d been using their API on a sort of demo basis. Because again, 20 users. Yeah, we immediately had to learn about things like request queues, so that our app wasn’t just falling over waiting for their API, and then frantically Biz Dev-ing to try and increase our rate limit, while at the same time figuring out the best ways to get around the rate limit without upsetting the Biz Dev deal. Yeah, we didn’t really have much of a sort of continuous delivery process at the time.
But I guess not as many people were talking about it—this was 2010. I think the first blog post had come out from Iron View and so on, but I think it wasn’t as, you know, there weren’t full startups supporting it. What we did have was the Heroku deployment model, which was basically like within five seconds of writing the code you can deploy it to production.
Which if you squint at it, kind of is continuous delivery because you’re saying, all of the bits of your deployment that you have are automated. We didn’t really have many tests at the time, so the tests we had were automated ’cause there weren’t any. Our deployment was absolutely, you do it get push, you don’t have to like move any servers around or anything like that.
Paul: Seems like the testing model around, or the continuous delivery model around a Gmail plugin is probably going to be a fairly difficult process anyway.
Sam: We never really had a good answer to, you know, what happens when Gmail changes their UI. The surprising part was it didn’t happen that often. We thought it would be breaking every week and we’d need all kinds of canary accounts and end-to-end testing to monitor that kind of thing. In the end, it happened rarely enough and we noticed quickly enough that we could usually just fix it on the spot. So even when we got better at testing and that sort of cycle of things.
Paul: We had a problem or I guess solution with GitHub. So GitHub used to be super flaky around two, two and a half years ago, when they were still on Rackspace. And whenever something would go wrong with GitHub we would find out immediately. All of our, all the developments would start failing and so before they knew that there was a problem, we knew there was a problem.
And we would often like, declare on Twitter, oh we think GitHub’s having a bit of an issue and two minutes later their status would tweet us and then we would retweet their tweet.
Edith: So they were using you for their free testing.
Paul: Well, our customers at least.
Edith: No I mean you were acting as their tester and telling them that—
Paul: Well, I mean it was very, you know, automated on our but we didn’t have necessarily automated fixes at the start. It kind of happened every, you know, two or three months and they would swear this is the last time and—
Edith: It’s always the last time.
Paul: And in the end it happened like six or eight times and by that time we had built a thing that allowed, you know, certain fixes, but it wouldn’t be quite, you know, fully automated process that you would expect if it was happening all the time ’cause it always seemed like it was gonna be the last time.
Sam: And it’s probably always happening for a slightly different reason or in a slightly different way. It’s actually, it’s an interesting question to me in the subject of continuous delivery in general. People always talk about every time you commit you run your tests, every time you commit, you deploy.
But that’s actually only one of the kinds of events that you’re dealing with in a software life cycle, right, when something’s actually running. I mean, sure you’re changing the code but also the world’s changing around you. And I feel like you always end up needing a little bit of both—you need something that’s gonna trigger when you change it, but you also need sort of an eye on everything you depend on. And, of course, even figuring out what all those things are can be interesting.
So I wrote a blog post about this on the Heavybit Blog, I think a while back, and it was about third-party APIs you know, how do you test third-party APIs. And the conclusion that I came to was that, so if you run the tests as part of your test suite, then if something breaks, your test suite will be broken, but also some things will just like randomly break in production.
And then of course you can’t deploy because your test suite is broken. So you’re in kind of the worst of both worlds. And so what I considered is, is that you need something which, you know, is just permanently monitoring. Like whatever API things you do constantly hits your personal accounts or your test accounts for those things, and then stub it out in your test suite.
And that way you kind of get that best of both worlds, your test suite doesn’t fall over and you get an actual monitoring event when the third-party service goes down in production.
Sam: I can tie this to an experience from LinkedIn, actually. So LinkedIn has the model where there’s a staging environment and a production environment. And the staging environment is—I don’t know if it’s technically called a staging environment because it’s not exactly production-like, but what they actually call it is early integration. Because it’s the environment in which teams integrate with other teams.
And so the idea is you deploy your stuff into EI, early integration, as soon as you can so that if any other team depends on you or vice versa, you can find out there before the thing hits prod. But what you’ve effectively got in EI is this constantly changing environment full of dependencies and you have exactly this problem and different teams which using different solutions to, well, let’s write some integration tests which actually hit the dependencies and then we’ll run them in our test suite when we deploy to EI or when in the build step which—
Paul: I can’t tell as you’re describing this whether this is a good thing or bad thing.
Sam: I think there wasn’t a clear conclusion, but my conclusion is that it doesn’t work for the same reason that you’re saying.
You need to know that if your test suite fails, it fails because of something you did. And then you need something else that can fail because of something someone else did.
But if you’re ever unsure which of things it is, then the signal is lost for both systems.
Edith: Yeah. When I was in London, I talked to somebody. They don’t have a staging system at all for kind of these reasons. It’s just easier to put everything in a production, feature flag it, and just know whether it’s an issue or not. Maintaining a staging system is sometimes even much more work.
Paul: Yeah. Yeah. It honestly is. There were actually significant amounts of effort put by every team into just keeping their stuff running, then the EI instance of their stuff running. And to some degree making sure that if you had any data that your service needed to run that there was a representative set of data in EI that the teams that were depending on you could use. This isn’t production data, right?
Paul: For use of privacy reasons, this is all fake data, which means you now have to maintain a fake data set for every single service.
Sam: Right, right, right.
Paul: Very few teams have the bandwidth to do that.
Edith: Also, then you always have to remember Oh, let me go to staging. Then it’s just this drudgery.
Paul: The tools have ensured that you did it in that order.
Sam: I think the problem is having a single staging. I don’t think that there’s necessarily anything wrong with the concept of deploying something and possibly pushing a small amount of traffic into it or pressuring it.
Edith: I think it should just go directly to production and feature flag it all.
Sam: Okay. I guess to a certain extent, they’re the same thing. You can have a staging environment and a small amount of traffic is mirrored into that, which is essentially a feature flag situation.
Paul: I’ve heard the word used for that is the dark canary. It’s canary in that it’s deployed into a real production machine, but it’s dark in that the users aren’t actually seeing it.
Paul: The interesting question then is what if that is right traffic? It works great for reads. You can just mirror them, but if you’re mirroring rights, you may have double rights.
Paul: Maybe there’s a bug in that thing you just deployed.
Sam: Yeah, yeah, yeah.
Edith: Yeah. That’s why I argue for to just put it all in production.
Edith: Just the effort to maintain a system to test on is huge.
Sam: What we do is people can spin up their own staging environments. It will just spin up a whole staging environment so you can do some tests on it. People do that very often for load testing or they put traffic against it of their own creation. One of the problems that we often run into is how do builds interact with other builds and if you’re doing anything that that involves LXC or any of the more platform as a service kind of things or cues. Those are very difficult things to do in production. At least, if you do it in production and you fuck it up, then you’re in real trouble. Those are things where we’ll have people spin up staging instances. We’ve set a script to set up you’re own staging instance, but you can have multiple staging. They don’t talk to each other. It’s not an early integration situation.
Edith: That’s interesting. Those are actually one of our early company ideas, which was allow people to do builds on demand. We called it continuously. Anyway, enough about me. What was the biggest difference you saw between moving from a start-up style up to LinkedIn? What was the difference in cultures?
Sam: I’d say a big part of the difference is in a start-up, at least in the size we were at. We were five people at the time of our acquisition. You feel like you’re one integrated unit that … You know who’s doing everything. To a certain extent, everyone is doing a bit of everything. Certainly you always know where to go if you want something done and if you want something prioritized. As a start-up scale and certainly when you’re a big company, you very much specialize. You split off into these groups that do things. As I eluded to when I was talking about this early integration environment, that’s just teams within the company. LinkedIn adopted a version of the microservices model, which as I’ve heard it described is, it’s not a way of writing software. It’s a way of running software, because what microservices gave to LinkedIn was the ability to divide their software by the team structure.
Rather than saying we have this gigantic monolith and this is your bit of the code base, it’s still got to be deployed in the same way.
Sam: Teams could make their changes in an environment that was somewhat controlled. They controlled their deployment schedules. They could go continuous deployment if they felt like their tests were ready for that. They could do their manual deploys if they couldn’t or if they had some extra-special deployment requirements. You had all these different teams often … LinkedIn is a very big company, often in different buildings or sometimes even different time zones, that would be doing the thing that you were currently thinking about. We got a URL and we want to see the contents of the news article that URL represents. You may have to talk to at least one other team, if not two other teams, to get that, which is a really interesting and powerful model because it means you can make progress on all of those things in parallel. You get these very interesting problems of sort of knowing what’s going on between these different teams.
There’s the technological drift of you’ve changed this thing and now we’re not compatible, but there’s also the really subtle mission drift. At the start of the year, we all decided that we were going to do this thing. We were going to build this feature, which required all three of our teams or all nine of our teams, to work towards this thing. We were going to implement this feature, which we’re going to depend on in three months so that the third team can do this thing. It turns out that two months in, the first team realized that to do exactly that was going to require some significant refactoring they weren’t ready for, so they slightly changed their plan. They didn’t realize, because it’s hard to tell, that that change was going to disrupt other people. They continued along the track that they were going on. When team two was ready to start integrating, they found that it doesn’t support this thing that they were depending on.
Sam: You then get these escalations or backpedaling. You get some very good discussions coming out of it. Usually, it happened for a good reason.
Paul: Does that seem parallel here? In Amazon’s, in one of the learning’s of having a microservice model or, at least a services model, is that when something goes down, it often takes a long time to find the team. There’s an escalation that follows to another escalation to another escalation as people try to figure out what service is actually responsible for the outage. It seems a problem of communication structure.
Paul: When people change their things, it’s a new person that has to be talked to, a new team that has to be reached. Maybe you go through several teams before you find out that the API and point of using is actually served by another team, which is served by another team.
Edith: It’s turtles all the way down.
Sam: In some ways, the team model you can seem as an abstraction layer. In theory, you would actually have teams, which in software terms you might call an adapter or a proxy.
Sam: You would have teams, a large part of whose job was to effectively route calls between different other teams. The team I worked in was doing a lot of interesting things. One of its roles was to integrate work from lots of other teams. We would get questions from all around because, as the integration point, we were the most visible. A lot of the questions we would get were things we weren’t fundamentally in control of. We would be like oh you need to go ask that guy or we would ask that guy for you. It was an interesting place to be, especially when people don’t necessarily realize how much you’re delegating things down to other people.
Paul: Why was that the split point for the service or the team? Sorry. I’m interested in the question of when do you create a microservice. All right. In this case, or LinkedIn’s case, since you create a service for each team. Why did that team exist?
Sam: There’s an interesting corollary to create a service to each team, which is if you really need a service which performs an integration role, you sometimes need to create a team for that service. At least, that is a natural, cultural assumption.
Paul: Yeah. Yeah. That’s how your company works. That’s how it works.
Sam: I don’t think that’s exactly what happened here, but you do have is sometimes you have a team that needs to do things, but the service they own isn’t really micro anymore. Sometimes, you have a service which is in an important request path or whose job is fundamentally gluing things together.
Sam: It’s job can become more complicated than you can necessarily represent in this sort of idealistic UNIX model of it just does one thing and that’s what it does.
Sam: Let’s say you’re taking data from a bunch of different content sources, and you want to blend them together in some way. You could say we’ll just have a service that does that sort of stacked together in aggregation. Then we’ll give it to another service to apply some ranking on top of that. Then we’ll give it to another service to apply business rules, like filtering and abuse detection. Except it turns out if you’re doing that many hops, first of all, there’s the inefficiency of having to throw all this data around. Sometimes, it’s large amounts of data, especially if what you want to do is some kind of relevancy ranking on that data. Relevancy is being a broad term for figure out what the user really wanted to see. In the ideal case for relevancy, that requires access to all the data you could possibly have about the user of the article, users like that, user, and so on.
If you need to bring that into more than one place, that’s usually pretty relatively hard even to get into one place. If you need more than one service with access to that kind of thing, then that gets a bit nightmarish. A natural thing is to collapse a lot of those responsibilities into a single mini-service.
Edith: So a microservices become mini-services. Do they eventually just grow up and become services.
Sam: One of the really interesting things I saw, LinkedIn started off with monolithic services, moved itself to microservices, iterated back and forth along the spectrum a few times. There’s a strong tendency for a microservice to grow up into a monolith again.
Sam: As soon as you have 20 people committing to the microservice wise, it’s a monolith now
Paul: I think there’s this interesting question that you see a lot of people who are new to microservices, not really know where do you put or what is a microservice and where do you put the service boundaries. There’s a lot of pragmatic things that you can do. You can say there’s a team boundary. There’s a very obvious API boundary. There’s things that have different deployment schedules, things that have different reliability or uptime requirements. I think those are the kind of major ones. It’s interesting to hear where that breaks down. If you have a model of your one team/one service, then you’re not going to have a microservice anymore. You’re going to have teams managing a bunch of different microservices, and then they have to become a bunch of different micro-teams to manage those microservices.
Sam: I think the way that LinkedIn structured it was actually pretty interesting in that regard. That’s kind of why I said sort of microservices at the start. The actual model LinkedIn used was based on it went all in on a RESTful model. What they actually talk about is REST endpoints. So you would have an endpoint, which is defined pretty much by the name of the URL at that endpoint. I should probably say resource. You might have a resource, which is members. You might have a resource, which is articles. There’s a registry that says if I want to access this endpoint, what physical machines do I go and ask? Services clear it out at run time. If you want to get something out of a member’s resource, you do that look up at the time that you are making the request. What that means is, you are not actually talking to a service. You’re talking to a resource. The choice of whether, for example, more than one resource might live in a single service. That’s up to the team that owns that resource.
Paul: Oh, I see.
Sam: If that team wants to have three similar resources live in the same service, because that worked for their team model iteration speed, their optimal requirements, etc., they can do that.
Paul: Standard computer science solution, just add another layer of direction.
Sam: Yes. You had some big services, some very small ones that just earned a single resource.
Paul: I wasn’t clear whether you were hitting at a big one or a small one.
Sam: Right. I guess the view was you didn’t really need to know.
Paul: Right, right. In fact, it’s great of you don’t know.
Sam: That sort of helped with knowing who to talk to, as well. You could use the registry to figure out … I think there was an earner’s list for every resource. You could start on hitting numbers, numbers as returning in error.
Paul: It’s almost odd to have registries keyed by URLs. You would think that the URL is the destination.
Sam: I’m not sure I see the distinction.
Paul: You would think …
Sam: Oh, I see what you mean.
Paul: Yeah. A URL is the place that you go. Whereas …
Sam: I guess there were two levels. There was the resource, which is sort of a logical URL.
Sam: It would be named after … It wouldn’t even have a host name in it. They called the service D2. It stood for Dynamic Discovery. The URL would be literally D2, colon, slash, slash, numbers.
Paul: Right, right, right.
Sam: That would be the whole thing.
Paul: I do think this is very interesting. People tend to build their microservices. Every service has a URL. If your URL has an actual machine name, maybe not a machine name, but something with a DNS name.
Sam: Probably it’s a load balancing name.
Paul: Exactly. It has a load balancer in front of it. You’re providing these endpoints to users under some other URL scheme, you have to have an actual load balancer in front of it rather than a thing that can be contacted asynchronously. There’s a thing through which traffic is routed rather than a thing, which tells you where you’re going. That’s the difference between a load balancer and a DNS resolver.
Sam: Right. This went along with also having a library that everyone in the company used, which did client-side load balancing. Almost nothing sat behind a physical load balancer.
Paul: Oh, interesting.
Sam: Part of this D2 resolution was figuring out what host should I use in my client-side load balancing.
Paul: It told you the set of hosts and the client-side load balancer picked randomly between them or something.
Sam: Yes. It may have told you the path and zookeeper to subscribe to so that you would be notified if the host went down, etc.
Paul: Got you.
Edith: This was a lot of microservices. I had a macro question for you, Sam. You have some interesting ideas around testing.
Paul: I have some interesting ideas. I think a lot of people missed the point of automated testing.
Edith: Oh. Paul might know a couple things about this.
Paul: I’m excited to see what this is.
Sam: I think that the word testing confuses people because it sounds like a thing that you do to a piece of software or to a product in order to find things that are wrong with it or a thing that you do to prove that the thing works.
Sam: Of course, there’s lots of quotes about how testing cannot prove the absence of bugs. That’s still what people talk about when they’re talking about testing.
Sam: I think that causes two kinds of problems that come from the same root problem, which is people don’t understand the value they’re meant to be getting out of testing.
Sam: I might be generalizing. I think a lot of people think they’re doing testing to find bugs or to ensure quality. One thing people do as a result of that is they’ve seen testing being done somewhere and there were bugs anyway or the quality wasn’t great anyway. So they concluded well I don’t need to do testing. It’s clearly just a waste of time, and it’s not going to find my bug, so why should I even bother?
Paul: What is the purpose of testing?
Sam: There’s this great quote from a kind of obscure source, which is one of the people on the Debian Project, who had run WMMX.
Paul: A software known for it’s reliability.
Edith: Paul? Paul, did you make a joke?
Sam: What they were trying to do was … The title of the post was A Proposable for an Always Releasable Debian. Debian has a hold project that maintains an operating system and tens of thousands packages, was trying to move to a continuous delivery model. They used to do deliveries every few years.
Sam: People loved them for their stability, and at the same time, mocked them for how all their packages were because they released every few years. They were like we have tens of thousands of things. They interact with each other. We don’t own any of them. How the hell can we possibly …
Edith: That’s open source.
Sam: Right. It’s open source. This was a proposal to adopt a lot of the ideas around continuous delivery by saying we’re going to have a trunk that consists of a known releasable version of every package. We’re going to write a big suite of tests that essentially sets, the phrase he used was a minimum acceptable level of quality, I think. Yeah, I think. It’s not to prove that there aren’t bugs. It’s to set a bar that everyone understands and can rely on and replicate. If you do find another bug, okay sure. You can add it to the test suite. In the meantime, everyone knows what is known to work and where the gaps are.
To me, testing is about establishing areas of confidence and about increasing the confidence that you have in what you’ve built and how it interacts with other things.
Edith: Kind of like the known knowns, the known unknowns, and the unknown unknowns.
Sam: Right. If you have a test and it passes, that’s a known known. If you have a test and it fails, you probably shouldn’t ship that, but at least you know it fails. If you don’t have a test, that might be fine because you might know that you don’t have a test in a certain area.
Edith: Yeah. We used to call that 40% coverage or 50% coverage.
Sam: Right. There’s always some part of your system that’s really hard to test. Sometimes, it just isn’t worth the effort to figure out how to test that. It’s useful to have tests everywhere else so that you know if something goes wrong, it’s probably in that area.
Edith: When we were just moving fast, our QA would just complain. We only have time for 50%. You pick.
Sam: Right. You have to prioritize your effort in it. Just to complete a thought there, I think that area of testing being about increasing and establishing areas of confidence. It makes much more sense in the context of continuous delivery. I think that’s part of why people have missed the point because continuous delivery is also kind of new. People are doing testing in the context that the tests are going to be run occasionally by developers when they feel like it or maybe by a QA team whose job it is to effectively do a really slow continuous delivery process and date releases.
Paul: I’m a tiny bit confused by it. I guess I just don’t get the implications. In fact, I’m not 100% sure what it means to increase the … I’m sorry. Say that again.
Sam: Establish areas of confidence
Sam: Increase your confidence in …
Paul: What does that mean? Confidence that it works? Is that …
Sam: If I was to take an extremist view point, I would say the point of testing is to allow you to do continuous deployment. In which case, it’s confidence in your ability to release this stuff.
Paul: Got you. Got you. Yeah. I don’t think that’s too controversial at all. I don’t think I’ve heard it said that way. The other ways I’ve heard it said are reducing the risks of deploying software, which I guess is very similar.
Sam: To me, that’s the flip side.
Paul: Yeah. Or to prevent regressions, which is again very similar, a very similar concept there.
Edith: I think every time you release, there’s some risk though. Every time you change something, by a varied difference, you’re increasing the risk
Paul: Right, right, right. Yeah.
Sam: But do you know where you’re taking risks? And do you know how much risk you’re taking? Often the answer is, we’ll see what happens.
Paul: Generally, when you’re taking that idea, it’s not just the idea of increasing the confidence that you have in your software. It’s not always testing. That’s the solution to that. Monitoring is the thing that I find is particularly. Slow rolling and feature flags, which I don’t know if you know, our company provides feature flags as a service.
Edith: Yeah. I was super excited.
Sam: It’s not a company called LaunchDarkly, by chance?
Edith: I think so. Paul, Paul.
Paul: This is now me almost every …
Edith: Thank you, Paul. I’ll also point out that Circle CI is now using us is now using us for their own feature flagging.
Paul: That’s awesome.
Edith: This station break is now over. Back to discussion.
Paul: The monitoring and feature flags and that sort of thing are all part of this idea of can I reduce the risk, what is the confidence I have that the software goes at?
Sam: This is exactly the conversation I wish people would have with, for example, their product managers. When they said we need to write some UNIX tests for this, the product managers say why because you have bugs anyway and we don’t have time. We have to ship now. I wish people would talk about the package of things you do to increase confidence. We got to need some testing here and we’re going to need some monitoring here.
Paul: Right. I think, as well, when there’s that conversation, I feel those kinds of parallels in the security world, that you’re having that conversation with Pms. There’s this sort of moral reason for doing it.
Paul: We’re developers, and we’re the sort of developers who write tests or who value security or whatever those things are. We refuse to release something which isn’t properly tested or whatever that thing is. That conversation with a PM inevitably goes sour. I see comments on hackneys where people hate product managers or describe all sorts of mal-intent to product managers, which is never a feeling I’ve had.
Paul: No. I’ve never … Anyway.
Sam: Woah, woah, woah, woah.
Edith: Paul’s like I refuse to get dragged into this.
Paul: Yeah. If the conversation is not … We write UNIX tests because tests are important or 80% coverage is the thing that God wrote on the stone tablet and we shall do it. This helps us maintain confidence. We know that next week’s release is going to be on schedule because we are confident that we won’t be breaking these releases.
Sam: That’s exactly it. I think the reason I like using the word confidence here is I think it’s common ground. The developer wants to be confident that what their being asked to support …
Sam: Will work to the degree they think it’s going to work. The product manager wants confidence that what got built is actually what they wanted. They want confidence that they’ll actually hit the milestones that people have told them they’re going to hit. All of those things are impacted by things like technical data and the complete lack of testing.
Paul: Right, right.
Edith: Yeah. I think you’re talking about product managers kind of as a monolith themselves.
Sam: That’s fair.
Paul: Is there a microservice model of product management.
Edith: No. You have this axis … It’s actually three axis, quality, time, features. At any given time, a good product manager is trying to balance between all three.
Sam: Right. I think you can have a conversation like, “Hey Jane developer. We really need to get this extra feature into this coming launch because there’s a customer that really wants to see it.” I’m Jane developer. I’m not going to change my voice. “I don’t think we’re really going to have time to …” Sorry. “I don’t think we’re really going to have time to get this feature because it’s kind of late in the cycle and we’d have to do a rush job. It’s going to be really important to hit the windows.” “It’s just one customer so we don’t necessarily need it to be at 90% confidence. Is there anything you can do?”
Paul: I see what you’re saying.
Sam: “To get it done at a 50% level of confidence for now and we’ll acknowledge that we’ll have to fix that up later if we want to take more customers on.” That might be the end of the conversation. Or Jane might come back and say, “Well, I think we could do that, but it might impact some other part of the system because we’d have to make a change to this service. I’m not sure it would stand up under the load, so it would actually reduce my confidence in the other part of the system that affects all customers.” Neither answer is right or wrong.
Sam: That’s something that both sides can.
Sam: Both sides can take part in it.
Paul: It’s interesting that your use of like a scale of confidence there. You do see this concept. You hear people talk about a minimal viable product.
Paul: Which is a lower confidence model. Tracer bullets is another one.
Edith: MVP is one of the most misused terms. I hate it at this point.
Paul: It’s interesting that this kind of provides a figure that you can adjust. There isn’t just is this a minimal viable product, there is do we have 10% confidence that this works?
Paul: Do we have 50% confidence that this works?
Sam: I think the numbers people will pull out of a hat that people can have some common ground on vague numbers.
Paul: Yeah, yeah, yeah.
Sam: Everyone roughly knows what they mean by 90% confidence.
Paul: Yeah, yeah.
Edith: I think it also comes down to the culture. I’ve been at companies where everybody says we’re fine with stuff breaking and stuff breaks …
Edith: That’s when people start not trusting oh it’s fine to have 50% coverage. You can have 50% coverage, but if this thing breaks, I get yelled at and perhaps even fired.
Paul: I think a lot of this comes back to the team dynamic and whether you have a good faith belief that the promises that you’re making are believed to be understood in the same context in which you’re giving them. If you have a boss, a product manager, a colleague, whatever it is, and you tell them 50% and they hear oh great that’s going to be 100% and I’m just making whatever promise, it’s not going to work. That’s going to end up being a disaster in the future. Good faith, I think, is a very good term for this.
Paul: If your team works and people are good colleagues to each other and there’s a good team dynamic and people hear what you say when you say it, I think that works very, very well.
Edith: Yeah, I agree.
Sam: I guess one interesting thing is people to have tendencies to over-report or under-report their confidence in something. That can depend on the culture and also their personality.
Paul: Right, right, right.
Sam: You have people who are always reluctant to sign off on anything because they know there is more they could do.
Sam: Or they’re used to having their promises taken at more than face value in the past.
Paul: Right, right, right. Does the standards drop where someone says how long will it take to deliver this feature, and they say two months, and then someone says, how about one month? They take their estimate and ask them to cut it in half. If instead, the conversation is we can get 90% confidence in two months. And someone else says I don’t need 90% confidence. I actually need 35% confidence. Would we be able to get that in a month? Maybe there response is you can have 35% confidence tomorrow. Or something else along those lines where people actually working towards a common goal.
Paul: Rather than there being conflicts between what people are asking for and what other people are delivering.
Sam: That’s huge if it’s no longer two differing interests trying to find a compromise, but if it’s two people with different skill sets working towards the same …
Sam: Working towards a business goal, or even figuring out what the correct business goal is in the space of these constraints.
Paul: There’s a framework that I used early in Circle where often when developers are talking to each other, they talk about implementations. They say I think we should do it this way. Someone else says I think we should do it this way. People throw out lots of reasons why they should do it their way or their favorite way or whatever.
The way that we overcame this is we started by stepping it back a little bit. We had three levels. We had problems, also known as goals sometimes, solution, and implementation. Whenever we’d be discussing things on the implementation level, we’d take a step back. What is the problem we are trying to solve? Get on the same page with the problem that we’re trying to solve. Then, decide, based on the problem, what is the solution that we’re trying to achieve? That can include things like confidence levels and that sort of thing. Then, when you get down to discussing implementation, that intends to be relatively trivial because you’ve agreed on the problems or the goals or whatever. You’ve agreed on how you’re going to achieve them and then the implementation just kind of falls in naturally. Implementation is kind of the conflicting schedules, trying to reach a compromise, and the problems and the goals is more everyone on the team getting aligned around a common purpose.
Edith: Yeah. Alignment particularly backs the time. Sometimes, it turns out that there really wasn’t an understanding of when something was needed.
Sam: Right. Yeah. People don’t even necessarily communicate that on either side.
Sam: Actually, I wanted to ask you, Edith. Since you stood up earlier for the internal reality of product managers as not just a monolith, what do you wish you heard from the teams you’ve worked with that you weren’t necessarily hearing?
Edith: It’s funny. I started off in engineering.
Edith: I started off in engineering, and then I moved over to product, so I’ve been on both sides.
Paul: That’s what every product manager says.
Edith: Well, you’re a product manager now, Paul.
Edith: When I was an engineer, I was just like “Oh my God. Here comes a product manager again, asking me for more stuff. We’re already totally overbooked, realistically a week behind schedule, lucky if only that.” I was working at Bigger Enterprise Company. Also, what happened is we would get a lot of bugs from the field. It was this constant thing. Not only did we have to build new features, we had a platform burning out from under us because we were installed software and we had to do an update every time somebody came up with a new app server. We would have to do a major rev.
Sam: And probably a convincing reason why each of those things were urgent.
Edith: Yeah. So when the product manager came up, we were just like, “No. It doesn’t matter what you’re about to ask for. Just no.” Then I became a product manager and I was like “Oh.”
Sam: These things are actually happening.
Edith: Yeah. I think the best thing to semi-answer your question is empathy. I think it’s also very good to have some tension between product engineering.
Sam: That’s interesting. Why’s that?
Edith: You got to ask for stuff. I remember once, we were like a month late on something, and the VP of marketing asked for one more thing. We were already a month late. I was just like, “No.” He said very nicely, he was Irish. He said, “I don’t know till I ask.”
Edith: In marketing or products, sometimes you don’t know how hard something is.
Edith: Sometimes, in engineering, we would be like why don’t you just ask for that? It’s actually really trivial. When you’re on the other side, something you thing is hard could be easy.
Sam: I’ve even seen the extreme version of that where asking for the next thing makes people realize that they misunderstood wanted for the previous thing.
Sam: Now that you’re asking for that thing, they’re like well why didn’t you say that in the first place? We can do this whole thing so much simpler.
Edith: Yeah. Exactly. Again, I’ll go back. I think all problems are basically not tools, but just empathy and having a team. Unless you ask for something, you don’t know.
Paul: Running out of time here. I’m sorry. At double speed if possible. Did you have a question about Hadoop?
Edith: Yeah. Sammy, you said that you could do continuous deployment in Hadoop, but I wanted to hear more about that.
Sam: The interesting thing about Hadoop is you’re sort of deploying into an environment in the same way that you’re deploying servers. The only difference is, instead of deploying something that’s going to be constantly being hit, you’re deploying something that might run immediately, or you might even be deploying something so that it can run on a schedule. If you squint at the problem, it’s actually very similar. You may have a staging environment where you want to run your Hadoop jobs first. You may have a battery of tests you want to run.
Where it gets interesting, is a lot of these things are sort of new to the Hadoop world, so a lot of the ways people are writing Hadoop jobs don’t actually have great testing support, or it’s at least a new thing. This whole field is sort of figuring itself out. To make it a bit concrete, at LinkedIn, a lot of Hadoop jobs are named Pig, which is this sort of sequel-like dialect for writing maps for these jobs basically, which sounds great because it’s nice and easy to read and write. You don’t have to think too much like a programmer, except until you imagine that people are writing hundreds of lines of basically sequel. Now that this thing is powering, it’s an equal open product. Because it looks like a sequel query, it’s not obvious to figure out how to test this thing. People are starting to write unit testing for mWorks that can test a Pig job. People are moving to frameworks, like Scalding and Spark, which have better unit testing sort of built in.
Then you’ve got some tests. The question is who’s going to run them? When are we going to run them? Are we going to make sure that we don’t deploy stuff that doesn’t pass the test? Now you’re in what looks very much like continuous innovation situation.
I guess another interesting place where, especially continuous deployment starts being actually really useful. You have this very common problem with Hadoop jobs that the standard workflow is somebody writes it. They test it on some data they have. They build it up into a big double and double it into the grid. They just took the double they had on their machine and ran it on the grid. Let’s hope it did the right thing. Let’s hope it had everyone’s changes in. Maybe it ran, and these things run for hours overnight. It failed. How do we debug that? Has anyone got the code that ran them? Often the answer is no. If a team wants to get away from that situation of people just uploading whatever they’ve got lying around them and the machine and maybe have the concept of versioning, for example, so you can say it was build number one three two or that’s this version of the code. It’s really useful to have a centralized point plan that these builds go through that can assign a version of those two things.
Actually, moving to a sort of trunk model with continuous deployment point plan is in some ways even more valuable for Hadoop flows. I feel like the team is doing any kind of deployment, I’ve already got a solution to that problem. It’s probably not worth running in production.
Edith: That’s fascinating.
Paul: It sounds like exactly the problem that the rest of the world has dealt with. People used to deploy whatever the hell was on their machine.
Paul: Moved into a standard CI pipeline and promoted things and so on. It kind of feels like the work that they have to overcome this, I feel like people will move on to the next thing after Hadoop rather than actually solve the problem.
Sam: Let’s say there is a lot of work going on in this area at LinkedIn. LinkedIn has a big continuous deployment set of tooling.
Sam: It’s actually been written in a reasonably generic way. They’re working on extending it to work directly with Hadoop jobs and set it into the same …
Paul: Oh, interesting.
Sam: The same pipeline and the same workflow everyone else is using. There are sort of company leverage benefits of all the teams using the same tools, even if we’re writing real time services and we’re writing these offline data crunching things. It’s still quite nice if you can move somewhere between those teams and they still know how to the work flow works.
Sam: That’s the other big thing of continuous deployment, right? You never need to educate someone about how to deploy your stuff again. The more different your deployment is from what people are used to, the more useful it is.
Paul: I wish we could keep talking about this forever, but I think that is time, unfortunately.
Edith: But it was just getting good, Paul.
Paul: That’s the same problem every week.
Edith: The same problem every week. Thanks, Sam. We really enjoyed you coming by.
Sam: Yeah. I really enjoyed being on the show. Thank you for inviting me.
Paul: Thanks for listening to this episode of To Be Continuous, brought to you by Heavy Bit, and hosted by me, Paul Biggar of Circle CI and Edith Harbaugh of LaunchDarkly.
Edith: To learn more about Heavy Bit, visit HeavyBit.com. While you’re there, check out their library, home to great educational talks from other developer company founders and …
In this episode, Edith and Paul discuss the spectrum of Continuous Delivery, and where Continuous Delivery will and won’t work in software development. This is podcast #6 in the To Be Continuous podcast series all about continuous delivery and software development.
This episode of To Be Continuous, brought to you by Heavybit and hosted by Paul Biggar of CircleCI and Edith Harbaugh of LaunchDarkly. To learn more about Heavybit, visit heavybit.com. While you’re there, check out their library, home to great educational talks from other developer company founders and industry leaders.
Paul: Hi, I’m Paul Biggar, founder of CircleCI.
Edith: I’m Edith Harbaugh, CEO and co-founder at LaunchDarkly.
Paul: You are listening to To Be Continuous, a podcast about continuous delivery and software development.
Edith: You can get in touch with us any time at our Twitter handle, @continuouscast.
Paul: The show is brought to you by Heavybit. To learn more visit heavybit.com. While you are there check out their library, home to great educational talks from other developer company founders and industry leaders. In this episode, we discuss the spectrum of continuous delivery and where continuous delivery will and won’t work.
Edith: Paul, does one have to be all in to do continuous delivery?
Paul: I think the obvious answer is no. In particular, you know that the answer must be no because nobody starts at all in or at least, if you are starting a new project you can be all in and many projects are not all in. Someone starts somewhere and they say, “Now we are going to do continuous delivery in some way.” They have to go from zero to full continuous delivery along some way.
Edith: I think people have this conception that continuous delivery just means pushing any time you want. A lot of very old school development shops did that. They would just hot patch in production constantly.
Paul: Are we calling that continuous delivery? I feel that the idea of SSHing into the server is not continuous delivery somehow.
Edith: People have this misconception because they are like, “Oh I did a continuous delivery before this was a thing, I just patched information.”
Paul: I am going to put a lot of money on the line here and say that if you define continuous delivery as I SSH into the production server, then you are not doing continuous delivery right. In fact you are doing it considerably wrong.
Edith: What exactly are you doing wrong, then? What steps are you skipping?
Paul: The whole point is that you have this automated process for releasing software, and SSHing into the production server is the very opposite of that. That’s not to say you shouldn’t do it in the occasional emergency. Occasionally if we have some sort of catastrophe we will SSH into the production server, replace some code, execute some code on the server to keep things as they are and prevent customers from noticing or from things from going down but that isn’t the same as a continuous delivery pipeline or a release workflow or an automated release work flow which is essentially what continuous delivery is.
Edith: Continuous delivery isn’t just shipping stuff out to production. It’s more having all the processes behind it.
Paul: It’s very much the process. When you think about can you be a little bit continuous delivery, I think what you are looking at saying is, is there a lightweight version where we get some benefits of the continuous delivery as we go between all and nothing?
Edith: Do you have to be all in or can you be a little bit continuous?
Paul: I think the very obvious instance of a little bit continuous is where you deliver the code. Where you have the automated release process builds some sort of artifact and then someone manually deploys that by a single click, or in fact where a build happens and test happens and the remaining automated release process is triggered by a human saying, “Now we are going to release.” Then everything else is scripted so they just have one input which is now.
Edith: That’s really interesting. Do you think to truly be continuous it has to all be completely automated with everything always pushed?
Paul: No, no I don’t think so. I think it largely depends on the size of the team and that sort of thing but I have seen a couple of examples where our customers were asking for particular things and indicated that they had sort of semi-continuous workflows. One example of that is a team that only wants to deliver or only wants to do continuous delivery during work hours.
There was another team which only wanted to do continuous delivery at midnight because that was the only time that they didn’t have enough customers on their site to be able to clear the caches. If they wanted to go to complete continuous delivery they would have to say we are going to clear a subset of the caches, or have some other caching policy that allows us to continue, or that allows us to deploy at any time but where they are is basically, we are semi-continuous.
Edith: I had a really interesting chat with Douglas Squirrel who actually listened to our podcast, and he does a lot of consulting for companies in England. He said he goes to a lot of companies that have all the tooling to be continuous but they don’t actually use it.
Paul: What does that mean exactly?
Edith: They have set up continuous integration. They could in theory deploy whenever they wanted but they still, for whatever reason, still cling to their old schedules.
Paul: Yes, that sounds right.
Edith: Jocelyn Goldfein who was at Facebook, right?
Paul: Yes, yes. That’s right. What she talked about was this idea that delivery schedules are useful in certain contexts. In some cases velocity matters, and that’s the Facebook case, and in some cases predictability matters a lot more. If you are delivering enterprise software for example, an enterprise is not going to allow you to continuously deliver your product into their firewall or into their enterprise. What they are going to want is they are going to want every quarter, a new thing.
Multiple times a year preferably, but each time you release to them creates a new workflow. They want to be able to audit it and see a change log and validate that things are, that they might have a change process internally. It’s not necessarily going to be a good idea to continuously deliver there but a team that is building for that can do a continuous delivery process internally where they produce all of the artifacts and they do a complete release on every single push even if that is not released.
Edith: There is a lot of reasons why an enterprise doesn’t want to take new features constantly and a lot of it comes down to training. If there are big new features that need to be rolled out to people, then they have to take on the cost of training. It was actually interesting, I chatted with a guy from Square and he talked about how they really try to limit the amount of pushes they put out to the actual cashiers. Because of the training cost, a cashier at a coffee shop is doing a gazillion other things and they can’t just suddenly pop up to new functionality and expect them to grok it or even take a tour.
Paul: Got you. Right, right, right. That’s an interesting idea.
Edith: Although they have all the processes in place to do a lot of changes and to do continuous delivery, they actually really limit what they push out to the true end users.
Paul: It’s funny that the people who have far, far more users, someone like Facebook, can just do those changes because they don’t necessarily value an individual user on a … Not saying that they don’t value their users but …
Edith: You’re about to … You’re walking down a path.
Paul: It is safe to piss off an individual user. Less so for someone like Square and as you go up the value chain, the more they are paying you or the more involvement they have to have in the product decisions, the less able you are to piss them off.
Edith: Facebook is actually a fascinating example because at any time they are going to be pissing off somebody. It’s kind of like Apple, you know they are always pissing off somebody it’s just who.
Paul: Did you hear about the day at Facebook where all the feature flags went on?
Edith: It was LinkedIn.
Paul: Was it was LinkedIn? Okay.
Edith: Yeah. It’s probably happened to everyone that’s done feature flags, there is the day that that happens and it’s ugly. Facebook is fascinating. Actually, I wrote a blog post about Facebook and how they use feature flags. They have a product called Gatekeeper that controls everything, everything. After they had a huge PR disaster, I think it was in 2011 with their news feed, they actually do really care if they piss off a lot of people and that’s why they implemented Gatekeeper where they do a lot of 1% roll outs.
Paul: I remember when I was setting up Circle I sat down and talked to my friend who worked at Facebook and he talked about their workflow and that sort of thing, and their release process was that code got released on Tuesdays. Everyone who was releasing code or who had code in that bit that was going out had to be available during the release process. The release process didn’t turn on any features because that was all done by Gatekeeper, but the code itself had to go out and they had to validate that everything stayed the same and everyone had to be there. They had a fairly continuous delivery process but were still, manually there was a release going out.
Edith: You want to have some sort of enforcement that people look at stuff and care.
Paul: Care in what sense?
Edith: The example I heard about also at Facebook is it’s so large that there is just no way that all the groups can coordinate with each other. Literally what they do is, when they roll stuff out with Gatekeeper, they roll it out internally to Facebook only employees. That’s how they find out if stuff breaks. It’s not like at a smaller company like Circle or …
Paul: There is a difference between the code being rolled out and the feature being rolled out, and they don’t do … I don’t know what the story is nowadays, but at the time they certainly didn’t do continuous delivery on code, or continuous releases or whatever you might call it.
Edith: I don’t actually work at Facebook but what I did hear was that they just literally can’t … When you are a small company you could still coordinate in a HipChat or a Slack room like, “Hey, we’re pushing this now, start looking for changes,” but with Facebook the only way they know if something is broken is if somebody complains.
Paul: There is an interesting discussion about microservices at AWS. I guess they didn’t call them microservices at the time but being fully service oriented architectured. One of the things they talked about is how when you roll, or when you continuously deploy a service, you might break other services. The thing that actually breaks may not be in any way related to the people whose alarms start going off and in fact they may be multiple steps away from whose alarms are going off.
Edith: Google has a similar system and I heard that they monitor 200-plus different metrics. One of the ones they monitor is just, do people say Gmail sucks more? Like on Twitter.
Paul: Interesting. The thing that I am getting at in terms of how little or much can you continuously deliver is if you are a Google or you’re Facebook and you have the monolithic code repos, the thing that you are releasing is, it’s not the same release process as someone like Amazon who has what I would describe as pure continuous delivery. Every service does its own continuous delivery and your dependencies may be changing in any time and you don’t actually know what is going on.
Versus Facebook that we are taking this multi-gigabyte binary and we are uploading it to a set of servers. Sure, we are slowly releasing and maybe we’re doing that multiple times a week or multiple times a day, but it’s not quite the same as Amazon releasing every 11 seconds. I think we can see even between these multiple large companies who have incredibly advanced release process that you could say that they are clearly at different spectrums along continuous delivery.
Edith: What do you think is suitable for a medium company with 10 developers?
Paul: There’s a lot of different things going in … Who is your customer base? What is the level of safety that you need? Let’s suppose that it’s a consumer web app. If it’s a consumer web app, I would expect that that company should be continuously delivering all the time. Especially if it’s slightly okay to break things or at least you break things, you can roll them back or whatever within a couple of minutes. A team of that size might not have the resources to make their continuous delivery process perfect, but it seems likely that they would have more success shipping with continuous delivery than shipping without it so lower risks, higher velocity, that sort of thing.
Edith: It’s funny how continuous delivery has permeated even the VC world. Jason Lemkin, you know the guy behind SaaSter, he tweeted yesterday that one of his due diligence questions was how often …
Paul: I saw this.
Edith: How often can you roll back, comma and does it work? It’s funny that I think of that as a very technical thing, can you roll back, but the VC is seen as a sign of technical sophistication.
Paul: Can you roll back?
Edith: All the time. Every day.
Paul: Really? You break things so often that you must roll back.
Edith: Paul, no. I mean, we feature flag everything.
Paul: A feature flag is not a rollback.
Edith: I think of it as a rollback. If you think of a rollback …
Paul: How often do you roll back the version of deployed code?
Edith: Virtually never because we feature flag everything, so if something …
Paul: Could you roll it back? Does it work?
Edith: That’s funny. I think we’re hedging now on what rollback means because I take it as can you take … What LaunchDarkly really does is it separates deployment from visibility.
Paul: There is a code deployment and there is a feature deploy which is done at a separate time.
Edith: When I talk about rollback in my mind I’m just talking about, I’m rolling back the feature from any users or any systems. Because if we have a feature flag on something and we turn it off, it is in effect rolled back.
Paul: I understand what you are saying. What I’m asking is, do your code rollbacks work?
Edith: We never have to do it because we always just turn off a feature flag. Stuff breaks and when it does we will just flip the feature flag off.
Paul: It’s funny we’ve ended up with a ton of different types of feature flags. One of them that’s very interesting is we started with this idea of pseudo hacks.
Edith: Isn’t a hack already a hack?
Paul: Yes. We launched this within the first couple of months of Circle that when a customer would ask for a thing, customers didn’t have pseudo at the start on Circle. They weren’t able to install things, they weren’t able to app to get install or do anything as root on a Circle box and we didn’t want to give them access to root either. What we wanted to do, whenever a customer asked for a thing we would add a single line of bash that was executed when their container started up and would get their container into whatever state it needed to be.
It would, for example, install the new version of MySql or something like that and that in effect became a feature flag. A load of customers would start to ask for particular thing, we would add the line of bash to someone’s container and then another customer would ask for it and then we’d have 10 or 20 customers who were using this in production. You can’t see it on the podcast but I am doing air quotes when I say uses this in production, and that was kind of our feature flag.
Then that evolved into global hacks so that when we have a single container image that almost all of our customers use. When we launch a new version of that container, sometimes something will break and we do lots of testing in advance and we have an automated process that ensures that those things work but occasionally something will go wrong. Then we’d add a global hack that runs on all containers before the customer’s code is run to get that back working.
We’ve evolved that. We have container feature flags, we have user feature flags, we have machine feature flags and the net effect is that we also almost never roll back. On certain things, on containers it’s very easy to roll back. On our VM images and on our front end code base it’s very, very easy to roll back. The back end code base is not as easy but it’s getting much, much easier. There is a defined process there but we almost never have to do it because there is nearly always a way to hack it and to keep rolling forward.
Edith: I did remember, so we can roll back. We try to protect everything with feature flags just because it is so much less stressful. Any time you have to do a rollback and redeploy code, it’s very stressful because there is a lot of things that could go wrong and it’s just stressful. We did have to do it the other day because we changed something around, an API schema. We hadn’t feature flagged it because we thought it was so minor and this is always where you get tripped up, the thing you thought was so minor that you didn’t feature flag that broke something very important.
Paul: Stripe has a very interesting, I don’t think you’d quite call it feature flags but it’s their API versioning, so they never change their API. They just launch a new version of the API. New customers get it and old customers can opt into it. They end up in a situation where they never have to roll back their API, they define a transition from their old API to their new API, and there are definitely code changes that sit behind each API but there isn’t a change to how a customer perceives it. Any change that the customer perceives is an actual error or is an actual bug that they need to fix.
Edith: That’s smart. That’s what we do also. APIs are so painful because no matter how much you try to warn people there is always somebody out there who is using the version …
Paul: Who is using the thing that you haven’t told them about but they inspected the data directly and thought that this was always going to be this way or something.
Edith: Oh man, when I used to work at an enterprise software company and we completely deprecated and removed an API that somebody had found out when they upgraded and could no longer use it. They wrote it like, “Where is my meta transactions?” We’re like, “Removed.” We got this really anguished … You could literally hear this guy sobbing. He’s like, “I’ve written over 3000 modules using that metatransaction API. Now what?”
Paul: What did you do?
Edith: There was nothing to be done, the API was gone.
Paul: You didn’t bring it back for him? You didn’t ship him the code for the API and, run this yourself?
Edith: Mistakes were made and he was at a very large Telecom customer that was paying us a lot of money and he was extremely unhappy with us. He was extremely unhappy for good reason because he had spent years of his time.
Paul: One of the things that we’re doing at the moment is … It’s very important to be able to sunset features and to be able to know when exactly things are working or to be able to be in control of your own code base. One of the areas that is hardest is in API because people expect that the UI is going to change all the time, that the function of everything is going to change, that they may have to change their code base sometimes to fit in with that but APIs are a particularly hard thing to change.
Especially since you don’t have any metrics on how people use them. I think that there needs to be a lot of effort if you want to have a continuous delivery to be able to change your API. A couple of things that we’re doing to change the API is one at the moment is where, right now everything is in our V1 API namespace.
Edith: Wow. Still?
Paul: Still. We just add to it, we almost never change it. We did one change, maybe two changes, customers didn’t notice so we were fortunate there. Ours is a product that where the API is not heavily used.
Edith: Oh, really? Our product is all API.
Edith: Is it public?
Paul: De facto.
Edith: That seems …
Paul: We didn’t publish it, but you can see it in Chrome in the web inspector.
Edith: Not to pick on you, though you picked on me earlier, that seems a little non-standard.
Paul: I agree that it is non-standard but it …
Edith: To put that in the politest possible way, why?
Paul: Because at the time we just took all of our stuff and put it in the v1 namespace. There was only one namespace so now …
Edith: It was like Highlander.
Paul: Now we are looking at having multiple namespaces. The two that we are focusing on are the private, which is don’t touch this and if you want it ask us, and the experimental which is we don’t actually know how this is going to be used in public and we don’t want to think about this too much. We just want to get this out the door.
Let you guys use it and give us enough feedback for us to put it in v1 at some point, or v2, whatever version it is at the point. I think that those are very useful API, the idea of namespacing and I think that the more advanced version of that is Stripe’s thing where you validate or where you make a large number of APIs. You version them and you let people exist on all of them via canonicalization process.
Edith: I agree. We take APIs very seriously because at its heart, what we are is an API. We are an API with some SDKs on top of it and then a nice dashboard. Our API is actually the most tested thing because our customers depend on that to run their business.
Paul: That’s all your business is, is a little API and a little dashboard.
Edith: Then a lot of technology to make that all work.
Paul: I keep going on about Stripe’s API versioning.
Edith: Is it because they’re Irish?
Paul: It’s not and the people who gave a talk about this are not Irish. One of the Heavybit talks was by Amber at Stripe about their API versioning. The reason that I like this so much is, have you heard the word canonicalization? This is one of my favorite software engineering techniques which doesn’t really get people talking about it, and the reason that I know about it is because it comes up a lot in compilers. The idea is that you don’t have multiple ways of representing things.
You take the multiple ways of representing things and you modify them into the canonical way of representing things. That’s how Stripe implements its API versions. Every version that the API has a canonicalization step which transforms it to the version that’s expected the next step and at the core of it, they have a single canonical version of the API that every API talks to at the end of the day.
Edith: To bring this back to continuous delivery, do you think then that they are practicing continuous delivery on their API or not?
Paul: Oh yeah, yeah. No, I think that is exactly what they are doing because they are versioning it. They are allowed, create a new version of the API. They can make a backward incompatible change at any time and it will only affect new customers going forward.
Edith: That’s a good point.
Paul: Then the only people who suffer are people like Barometrics where they need to talk to tons and tons of different customers, and actually that’s not true because you can also specify the API version that you want in the API header so you’re not actually stuck with the version that is specified in the dashboard.
Edith: Cool. We talked about APIs, we talked about consumer companies. Do you think there is any company where it’s not a good fit for continuous delivery?
Paul: SpaceX. If you are making rockets, missiles …
Edith: Cars. Cars.
Paul: Pacemakers, cars. Cars is an interesting one because you have something like the self-driving cars where they are almost assuredly doing continuous delivery. Where the ability to iterate is a key function of what will get self-driving cars to market but I wouldn’t want Ford to be continuously delivering and doing an over the air update to something that is really important.
Edith: Volkswagen was just hugely in the news because they basically hacked their software to evade the EPA.
Paul: There’s a question here as well of whether you trust software more than you trust humans.
Edith: But humans write software.
Paul: Right, right but whether you trust the humans on the ground versus the humans at Google who write software. I think it’s fair to say that where you are writing low-level C or something like that, that affects the flight of the rocket, you want to be very, very careful about what you ship and how often you ship. If you are writing this high-level AI code that’s written by the world’s greatest engineers and replaces the world’s dumbest people at the wheel of multiple thousand-pound weapons that can hit other people who are in their own weapons, I think there is definitely a case to be made where self-driving car code is not held to the same standards. Maybe not held to the same standards but is naturally of such a standard that you could expect that you would continuously deliver it.
Edith: It’s a sad story. I run a lot of Ultra marathons and a runner did a 100-mile race in Utah and then he was driving back by himself on the 80 and he just basically, to the best we could tell is he just fell asleep at the wheel and just literally on cruise control ran into the tractor trailer in front of him.
Edith: Maybe if we had smarter cars, he could have taken a nap instead of trying to drive back instead of being awake all night.
Paul: Wow, that’s a tragedy.
Edith: Then you hear cases like Volkswagen who had one of the biggest software cheats in the world.
Paul: Fortunately they are going to be fined 18 billion for it and are unlikely to do it again.
Paul: Unlikely. Yeah.
Edith: You just have to think about the logic that led them to believe that they could get away with this. What exactly they did was, in California when your emissions are measured, they turn on some special software that decrease the pollutants enough that they could pass. Then in normal driving conditions, they turn it off so they could get higher mileage and go faster.
Paul: I see. That’s lovely.
Edith: Somebody somewhere had to think that they could get away with it. It wasn’t a bug.
Paul: Continuous delivery clearly working there.
Edith: What? How?
Paul: It worked as intended. They weren’t intended to get caught but clearly that’s not the software’s fault.
Edith: Don’t blame the software, blame the human that wrote it.
Paul: Right, right, right.
Edith: Or that person’s manager, or their manager’s manager.
Paul: Or the Board. On the question of do different kinds of software lead to different kinds of delivery processes? Obviously. I often make comparisons of what level of testing do you want and the level of testing that you want for consumer software, or if you are an early stage start-up that has no customers, it’s going to be different than most start-ups and it’s going to be different than most enterprise companies and the tech stack that you use if you are going to be one of these web start-ups, you can use Ruby on Rails. If you are writing pacemakers, you want to be using software that has some kind of formal verification in it.
Edith: Then you get into the whole area of government or financial which has its own set of rules.
Paul: All their rules are around process which indicates that there is something to this process thing.
Edith: I talked to a prospect the other day who made kids’ apps and I had to turn them away, because there are so many rules around what data you can collect from children. That they can’t use a key, they can’t ask them for anything, and I said we don’t want to touch this.
Paul: That’s interesting. I will have to not ask any of my customers whether they’re building software for kids. Though we don’t keep any customer data so we would probably be fine, but best not to know I think.
Edith: It’s better not to know.
Paul: Yeah. Thanks for listening to this episode of To Be Continuous, brought to you by Heavybit and hosted by me, Paul Biggar of CircleCi, and Edith Harbaugh of LaunchDarkly.
Edith: To learn more about Heavybit, visit heavybit.com. While you are there, check out their library, home to great educational talks from other developer company founders and industry leaders.