Live data from Hacker News

New case studies about Google’s use of Go

opensource.googleblog.com

181–190 of 269 posts

Re: New case studies about Google’s use of Go

#181
post #178
post #170

Earlier quoted context omitted.

Async/await solves a different problem than green threads. Async/await works well when you need to manage scheduling of a single thread (very common in UI or other cross runtime tasks). Implicit green threads are nice if all you care about is total throughput across all threads. Its not great for keeping a single thread responsive.

Async / await is just an abstraction over threads. It doesn't dictate how many threads are used.

I'm not sure what your point is exactly but I would disagree with the presented assertions none the less.

In C# async/await is essentially sugar around callbacks, which isn't really related to threads, per se. However, the language has the Task Parallel Library, and a Task promise type that has a lot of methods around scheduling and thread targeting. Essentially the TPL does dictate how many threads are used and is, as far as language design is concerned, inextricable from async/await.

Re: New case studies about Google’s use of Go

#182
post #167
post #104

Earlier quoted context omitted.

Other comments on this post: > I absolutely love using Go. The logical flows for my programs... > Go is super productive. My day-to-day responsibilities include... > Nothing gets out of the way better than Go. > Go as a new language is a mega success. I'm guessing you're OK with these, and maybe it's just negative opinions that are irrelevant?

I'm not the person you're responding to, but I think there is a difference between positive and negative posts in this context. Negativity is inherently bad. There is a place for it, of course, but when it's off-topic it's especially unwelcome in my opinion. And programming language discussion already has far too much negativity.

Many people find the "pozzy vibes only" philosophy much more annoying than relentless cynicism, which can at least be refuted by just ignoring it & building stuff.

Re: New case studies about Google’s use of Go

#183

Earlier quoted context omitted.

map/filter and sum types are not about "fun", they're about correctness and expressiveness. map/filter and their equivalent loops are both perfectly readable, but the latter involves more boilerplate.

And I'd disagree. Numerous engineers of differing skill levels (what I deal with day to day), struggle significantly when map/filter are added into the mix. And we may say "get better engineers", but we don't have that ability. We have to write code that is maintainable for the engineers we have and can get (and the ones coming in the future).

Come on, map and filter difficult? That's hyperbole of the highest order.

Re: New case studies about Google’s use of Go

#184
post #169

Earlier quoted context omitted.

I always cringe when people proclaim that they need to "get shit done". It often pays to be mindful of what is getting done as a result.

I think some people feel productive when they write out a big loop, but to me it’s wasted effort. I want to write col.filter(_.isReady).map(convertToX).any(_.color == BLUE) and generate whatever fused loops make that work. I don’t want to write and review loop boilerplate by hand for the same reason that I don’t want to customize the stack frame layout when I call a function.

It really doesn't matter day to day once you're in the loop (cough). I agree, it's an ugly language on the face of it, but you get over that quickly. You come to appreciate the language as a whole.

A bigger concern when I started out with Go was the imports/lack of versioning, and at the time the lack of official package manager.

Re: New case studies about Google’s use of Go

#185
post #169

Earlier quoted context omitted.

I always cringe when people proclaim that they need to "get shit done". It often pays to be mindful of what is getting done as a result.

I think some people feel productive when they write out a big loop, but to me it’s wasted effort. I want to write col.filter(_.isReady).map(convertToX).any(_.color == BLUE) and generate whatever fused loops make that work. I don’t want to write and review loop boilerplate by hand for the same reason that I don’t want to customize the stack frame layout when I call a function.

I've never found it much more painful to write:

  for i, c in range col {
    if c.isReady && convertToX(c).color == "BLUE":
      return True
  }
(which is not to say I don't miss the map/filter syntax - although I don't miss the bugs related to lazy execution in stuff like LINQ or Spark)

Re: New case studies about Google’s use of Go

#186
post #75

While I do trust Rob Pike to not let personal biases sway his writing, I do have to wonder if the case studies weren't selecting because they were positive. So I'm curious: does anyone have a case study where using Go was a disaster? Every language has things it's good at, and things it's bad at. Where does Go not do well?

Honestly any low level/system code is pretty disastrous in Go.

Edit:

Just to add to that statement: the work stealing goroutine runtime is particularly problematic, certain things are even impossible in go due to it. If you look at runc, large parts of it are written in C and called during init before the runtime is started.

Re: New case studies about Google’s use of Go

#187
post #81
post #75

While I do trust Rob Pike to not let personal biases sway his writing, I do have to wonder if the case studies weren't selecting because they were positive. So I'm curious: does anyone have a case study where using Go was a disaster? Every language has things it's good at, and things it's bad at. Where does Go not do well?

I know a case (second hand) where they migrated from a Java backend to Go, then had to roll it all back to Java because it was too hard and error prone to maintain. This is a very successful business, not a startup. No idea why they felt they had to migrate to Go in the first place. I'd rather not mention the company, even though I did not work there.

And as a counterpoint there are many non-hearsay examples where teams migrated large projects from C++/Java/Python/Ruby/JavaScript to Go.

Described publicly like Dropbox's backend migration to Go: https://twitter.com/jamwt/status/629727590782099456

I could give you tens examples of that, many have been posted on HN.

Re: New case studies about Google’s use of Go

#188
post #75

While I do trust Rob Pike to not let personal biases sway his writing, I do have to wonder if the case studies weren't selecting because they were positive. So I'm curious: does anyone have a case study where using Go was a disaster? Every language has things it's good at, and things it's bad at. Where does Go not do well?

Discord abandoned Go due to GC overhead. https://blog.discord.com/why-discord-is-switching-from-go-to...

That's not what the article is saying.

It describes a rewrite of a single service from Go to Rust.

Reading between the lines, a rather simple piece of code.

At no point it implies that Discord rewrote all their Go code in Rust and completely abandoned Go.

Re: New case studies about Google’s use of Go

#189
post #151
post #140

Earlier quoted context omitted.

But they’re specifically talking about a server component here. Using Electron on the client doesn’t magically make their need for a high performance backend disappear. They’re still having to make all those clients work and deliver voice chat to millions of simultaneous users.

Yes of course they are. Further I understand the "strategic decisions", "markets have spoken" , "faster feature due to single codebase" justifications to Electron usage. To me it just feels like saying we care about our servers meanwhile users can eat crap.

Yeah, one is free, one isnt

Re: New case studies about Google’s use of Go

#190
post #188

Earlier quoted context omitted.

Discord abandoned Go due to GC overhead. https://blog.discord.com/why-discord-is-switching-from-go-to...

That's not what the article is saying. It describes a rewrite of a single service from Go to Rust. Reading between the lines, a rather simple piece of code. At no point it implies that Discord rewrote all their Go code in Rust and completely abandoned Go.

Top-voted comment on that post raises some red flags.

> Any reason you’re using 3-year-old Go 1.9.2 but you’re okay using Rust nightly?

Post reply on HN