6 ms·
I will say that I saw and experienced many things that changed my definition of 'large' at Google, but the most amazing was the source code control / code revie
by ChuckMcM 11y ago
I will say that I saw and experienced many things that changed my definition of 'large' at Google, but the most amazing was the source code control / code review / build system that kept it all together.
The bad news was that it allowed people to say "I've just changed the API to <x> to support the <y> initiative, code released after this commit will need to be updated." and have that effect hundreds of projects, but at the same time, the project teams could do the adaptation very quickly and adapt. With the orb on their desk telling them at that their integration and unit tests were passing.
I thought to myself, if there is ever a distributed world wide operating system / environment, it is going to look something like that.
- devit 11y agoThe solution to the excessive API change problem is to force whoever changes the API to fix all the consumers himself before the change is accepted. The Linux kernel generally uses this policy for internal APIs for example.
- Lewisham 11y agoWe do, mostly. Because Piper is a global repository, we have systems to do global safe refactors, and do so often. If the API changes drastically, there's usually a lengthy deprecation period before the API is switched over.
- revelation 11y agoI guess that works for the Linux kernel, but I would presume that for a large distributed operation like Google it would be much better to simply deprecate/version APIs and have the project teams update to a deadline. I mean, it's presumably impossible to have a single computer running a single OS build all of the Google software and run the testing.
- stock_toaster 11y ago> The solution to the excessive API change problem is to force > whoever changes the API to fix all the consumers himself > before the change is accepted. This doesn't seem scalable. Let's consider the case of one api endpoint being changed by one developer, to add a new param to a function call. Further assume that this impacts hundreds of projects. Does it really make sense to make one developer update those hundred projects? Not only will it take forever for it to get finished (possibly never if there are new consumers of this api coming online frequently), but the developer of the core api may not have any experience in the impacted consumers of this codebase. I think the end result of this policy would be nothing once written ever would get updated, and new apis would just be added all the time (api explosion).
- masterj 11y agoIt's scalable with the right tools. If you can write a transform at the level of the AST that will make the change for you, you can do it in one commit. FB has written about this: https://medium.com/@cpojer/effective-javascript-codemods-5a6686bb46fb https://medium.com/@cpojer/effective-javascript-codemods-5a6... Not that it's a silver bullet, but it can make a lot of these cases non-issues.
- XorNot 11y agoGoogle's product explosions / surprise deprecations possibly hint that this is what happens? Changing the API becomes cumbersome, so you just make a new product with a new API to do an end-run around the requirement...
- zenbowman 11y agoIf all your RPCs take a single parameter, this isn't a problem provided you use universal defaults.
- nulltype 11y agoIt seems bad but the alternative (wait forever for groups that don't understand the change and may not even exist anymore to update their code) seems worse.
- thrownaway2424 11y ago
- trollian 11y agoThis makes it harder to change APIs. Which has advantages and disadvantages.
- Touche 11y ago> The solution to the excessive API change problem is to force whoever changes the API to fix all the consumers himself before the change is accepted. Having people unaware of a project's purpose making changes to its code sounds like a nightmare to me.
- sowbug 11y agoWhen that's the cultural norm, people adjust accordingly. Tools include liberal use of assertions, defensive tests, and most important, code reviews that catch and remove quirkiness. It's a nice environment to work in. In addition to hastening Noogler onboarding, it also increases employee retention. If you are an expert in your project's codebase but get burned out, you can easily transfer to another project and be almost immediately productive. Obviously, there's domain-specific knowledge that doesn't transfer easily or quickly from project to project. But that's quite different from self-inflicted code fragility; one's an asset and the other's a liability.
- comrh 11y ago> With the orb on their desk telling them at that their integration and unit tests were passing. Anymore info on this? Is it in house hardware?
- thatoneguy 11y agoIIRC, it was built on a hacked up Ambient Orb http://ambientdevices.myshopify.com/products/stock-orb http://ambientdevices.myshopify.com/products/stock-orb
- shostack 11y agoWow, $150? Shocked there isn't a cheaper USB version that is more easily hackable. I mean, is it really more than color-changing LEDs in a plastic sphere?
- PhantomGremlin 11y agoIt's also a perpetual? subscription to a nationwide wireless network to obtain e.g. the latest stock prices.
- andor 11y agoblink(1) is a small USB light to give you glanceable notice of anything on your computer or the internet. blink(1) makes it easy to connect data sources in the cloud or on your computer to a full-color RGB LED so you can know what’s happening https://blink1.thingm.com/ https://blink1.thingm.com/
- shostack 11y agoThanks for the link--looks awesome, wish the form factor were a bit larger and not so directly attached to the computer. I'll bet I could create an extension cable for it and rip off the housing to make the LEDs allow more light through, then put it in a translucent plastic sphere.
- ChuckMcM 11y ago
- RogerL 11y agoCan you (or somebody) explain how that works in practice? Here I am ready to deploy some new feature to gmail. In the meantime, I'm getting a steady stream of API changes. Can I build and release gmail to a specific revision number, and only incorporate the changes when I am ready, or are all release essentially off of the tip of the tree. I don't need specifics, just the general idea. Where we work basically every project lives in its own branch, which makes it essentially impossible to synchonize changes. Things have to get merged to trunk, then pulled into the appropriate branch, and I don't like it at all. Do you have version numbers for libraries/components: projext X uses version 1.5.4 of Y, 32.4.18 of Z, and so on, do you pull by revision number, are you all on tip? It'd be very interesting to hear how you manage this.
- pacala 11y agoEvery feature has a flag that you can turn on/off to your heart content. Releases are cut at head. No need to use the version control hammer to screw all the zippers.
- randyrand 11y agoWould that be analogous to, every feature is it's own git branch? and you choose which branches to merge when building? How are conflicts managed?
- electrum 11y agoNo, features are configurable at runtime. This allows A/B testing or slowly rolling out a new feature. Depending on the type of change, you might test it on 1% of users, 1% of servers, etc.
- pacala 11y agoEvery feature is in HEAD, behind a flag. Precisely because managing conflicts cannot be automated, relying on branching is unwise. With HEAD based development, you manually solve conflicts exactly once, when submitting to HEAD, then you never have to think about them again. Local branches for development, a single HEAD for merging code.
- Strikingwolf 11y agoThat's actually a good question. What would a world wide environment look like. Currently we have the web, but that isn't really a world wide environment in this sense. I think that this could be a way it would look, but more of a combination of this and a way to split everything down into the parts again without breaking the system. However, I've never worked at G, so I can't know if they have a method for this