text stringlengths 0 1.49k |
|---|
**Brian Ketelsen:** Oh my god, okay... Yeah, guilty. \[laughter\] |
**Cindy Sridharan:** And these are amazing things... Honestly, I think people should be sort of like going completely wild in their free time with whatever crazy technology they wanna work with or they wanna build or they wanna play with. But at the end of the day, most of us - at least most of the people I know - are ... |
\[28:06\] I've most certainly been guilty of prioritizing one thing over the other. That's a lesson I've learned, and it becomes really important to be cognizant of that, even when we find something super interesting or super cool. |
**Erik St. Martin:** I think it's easy to feel like you're being left behind. When it feels like the whole industry is going containers and Kubernetes, and you're like "Oh, we're still using [Ansible](https://github.com/ansible/ansible) or [Puppet](https://github.com/puppetlabs/puppet), or something like that..." It's ... |
I worked for a manager one time that had a cool rule. For greenfield projects where you're building something new for the company, you've got a credit - you could pick one bleeding edge technology, but everything else had to be well proven already. I thought that was a pretty good rule, because you always end up down t... |
**Cindy Sridharan:** That's true. Another downside to new technology is the operational burden of it. I'm a software engineer and it is one thing for me to say "I wanna use this cool new language, or this cool new framework", but when I'm also wearing the ops hat, even if it's just for 15% of my time, actually working ... |
The good thing with old, boring technology is that being able to proactively predict failure modes, or being able to understand how it needs to be instrumented or how it needs to be monitored is really easy, as compared to something that's bleeding edge... Because you know, all these blog posts where people are explain... |
My philosophy is that when I'm writing a new service or when I'm operating a service, the fewer things that I have to actually figure out for myself, the better. It's not gonna be possible to completely have everything figured out for you already. If that were the case, none of us would have jobs. It becomes really ben... |
**Carlisia Thompson:** Very good point. |
**Erik St. Martin:** So you had started talking about the one post that was one of the most popular that hit Hacker News and you kind of got some slack about, which was your [short methods post](https://medium.com/@copyconstruct/small-functions-considered-harmful-91035d316c29). Did you wanna give a little bit of insigh... |
**Cindy Sridharan:** \[32:05\] It was more about people genuinely believing that a lot of the things that I said weren't something that they agreed with, and that is totally fine. It wasn't particularly negative, the fact that the vast majority of people who commented were disagreeing with me. There were a handful of p... |
Some people complained that it lacked examples, but again, I cracked it out in two hours; it wasn't like something I spent two days writing, so that probably explains why I didn't feel the need to inject a whole bunch of examples. |
I also think in a lot of cases examples can be very contrived. It's kind of hard to translate a real problem that one sees in a real codebase that has been developed over several years by several different people with several different styles, and a codebase that's been built to satisfy increasingly different and varyi... |
Technically, you can write an example, but it's just very hard to really capture what you're saying - at least in my case, to capture the experience that I've had... Like saying "Hey, here's an example, here's the function", split it into two things and sort of make sense. |
That probably explains one of the reasons why there weren't too many examples, and a lot of people felt that a lot of the content of that post was very abstract. And I understand that, it can come across as abstract to someone who hasn't really felt the same pain. That's also the flipside of writing posts - it's probab... |
I wasn't really trying to be contrary for the sake of being contrary. It was more about something that I generally thought didn't make sense. Because I grew up learning, reading all these books; I grew up reading clean code and refactoring, and book on design patterns of the [Gang of Four](http://wiki.c2.com/?GangOfFou... |
Something that might seem very obvious to you, something that might seem very simple might actually not be the case for someone else, especially for someone completely new to the codebase or the technology or the tool. The way they think about it might be -- they might be missing a lot of context, a lot of the assumpti... |
\[36:00\] When it comes to code, I think the best way to make something intuitive is just to be explicit, and that is I think one of the most amazing features of Go - what you see is what you get. There is not magic, there is no hidden abstractions or any talk of zero cost abstractions or any of this; it's just dead si... |
**Carlisia Thompson:** I couldn't agree more with what you said - everything, and especially what you said last, that Go is very different, and it strives to make everything explicit. I absolutely love that about Go, too. |
As far as your blog post on small functions, for me personally, when I started programming, I was more struggling with knowing how to do it right - I still struggle, it was just that I struggled a lot more - than learning how to do it perfect. But I always kept reading books like Clean Code and Pragmatic Programmer, an... |
When I read your post, it resonated with me, and what caught my attention was the combination of having had experience of doing Go for long enough to feel comfortable with a different way of doing things, which is longer functions, making things very explicit, repeating yourself... Like Dave Cheney says all the time, i... |
So a combination of that, and also the fact that your post was so well written... Because if it was a blog post writing about this but the post had been written in a so-so way, I wouldn't have given it much thought. But your post is really well written, and it really caught my attention. I was thinking "This absolutely... |
**Cindy Sridharan:** Thank you. |
**Brian Ketelsen:** One of the things that you mentioned, Cindy, that resonated with me was the idea of building examples that don't necessarily make sense just because it's hard to build examples. That was something that always gave me the hardest time building training materials, because you're trying to exercise a p... |
**Cindy Sridharan:** \[40:24\] Right. I think it's a lot easier for authors of books though, because they can start with one example and keep building on top of that. That totally would not work for the blog post format, because it's just super hard to... Unless you're doing a series of posts and you repurpose the same... |
I'm sure there are ways, but it's something that I find extremely hard, to sort of capture without really making examples seem very contrived. And I had a lot of people actually write to me saying that "Here's this simple..." -- I mean, I actually tried doing that a little bit, where I was like, you know... Well, imagi... |
I sort of did that perhaps I was like, "Okay, so let's think of this example where I have to create a user." The point that I was trying to get across is that when you say a small function should do one thing, that one thing can be really hard to define. Creating a user, from a logical perspective, is one thing, but it... |
A lot of people wrote to me saying "Of course those things have to be separate functions. Why would you want to put all of that in one function?", where that really wasn't my point, that those all have to be one function. The idea I was trying to convey there is that one logical thing maps to more than one programmatic... |
If I could go back, I'd actually go back and edit that post a lot, because I just kind of feel that a lot of ideas could be expressed both more concisely and more reusably. But frankly, I don't think I'm gonna be bothered; it's done, it's over. I'll probably write a different one, that's all. |
**Carlisia Thompson:** I find myself actually doing the opposite of refactoring into small functions with my code in Go. Sometimes I see small functions that I just wipe out and put the code back inside the function, or I refactor things out and then I change my mind and put it back in. I find myself doing that a lot m... |
**Cindy Sridharan:** I think the one thing people underestimate is just how hard it can be when you technically just have to move around, even when you're reading code. One of my co-workers, who sort of started working on a Go project and he started thinking about what packages should be, what the API should look like,... |
\[44:09\] Two weeks into the project he told me that "I'm actually giving up. I've put everything in a package called _main_, and actually a function called that." He was like, "I was so fed up with just making all these decisions; I just wanted to get this thing working." So it's now one package _main_. It really was ... |
The first thing that he did when he started this project was do that, and then a couple of weeks later he was like "Geez, I've complicated this just way too much. I'm just gonna put everything in one _main_ function and get it actually working." |
I think it's a lot easier to abstract later in the process than to do it upfront. In this case it's just a really extreme example of someone just writing that whole application in one function, especially the function _main_, but I had definitely seen a lot of projects that actually have just one package called _main_,... |
At the end of the day, I think it comes down to how easy (or not) something is to maintain and how easy (or not) something is for someone new to the codebase to understand. Optimizing for these two things I think should be the goal, which could a lot of times mean going against the grain or doing things that may not se... |
As such, the goal is to just build something that is good enough, that can be extended and that can be modified without requiring a lot of cognitive overhead, or without requiring a fully-fledged refactor. Sort of making it good enough, and not perfect, probably makes a lot of sense to me. That helps in writing maintai... |
And the thing is it could be a lot better for a short period of time. I think that is what a lot of people fail to understand - perfection is sort of short-lived, especially in software development. You can achieve it, but it really is gonna be short-lived. Versus being good enough, which can actually get you a very lo... |
The most successful projects are projects that evolve and live on. It's not like something that you're just going to put into production and two weeks later just get rid of. For a lot of these extremely long-running -- and potentially any project that one wishes to be successful, the goal there should be to just make i... |
**Carlisia Thompson:** \[47:53\] I agree with absolutely every single thing you said. In the end it is about tradeoffs, and it really sucks when you start making the tradeoffs too soon. The example you cited of your co-worker putting everything in the main package - it's hard to say that there's only one right way to d... |
So the more I work, the more I aim for the things that you were saying - readability and easy to understand code, versus optimizing for other things. And even when I start writing a function and I don't know what the function exactly is going to be or what the scope of that function is going to be once it's done, I jus... |
Anyway, I think we should move on to projects and news... |
**Erik St. Martin:** I think we should. I think we've got five or six minutes left of this show. So interesting projects and news - we've been gone for about two weeks, so probably the first out is [Go 1.9](https://blog.golang.org/go1.9) is out of RC, so it is officially released... Please download it. |
**Brian Ketelsen:** Yay! Go get some! And Erik has a new job - I think that's probably the more exciting news than any of this. Why don't you tell us about that, Erik? |
**Erik St. Martin:** I do have a new job. I announced last week we didn't have a show, but I am joining Brian and everybody on Microsoft Azure. \[laughter\] It's almost literally everybody. |
**Brian Ketelsen:** Brian and everybody. |
**Erik St. Martin:** We've gotta get Carlisia, and then it will be the whole show. |
**Carlisia Thompson:** Oh, I also have an announcement... \[laughs\] I don't have a new job. \[laughter\] |
**Brian Ketelsen:** That's awesome. |
**Carlisia Thompson:** For the record, I'm very happy where I am... So Microsoft hasn't asked, but if Microsoft asks - you don't even need to ask; I'm very happy where I am. Not looking to move. |
**Erik St. Martin:** I was really happy where I was too, but the opportunity to work on Kubernetes and Docker and all of that stuff, all of the things that I love to do in my spare time, during my business hours, is really awesome. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.