Hacker News new | ask | show | jobs
by lmm 4617 days ago
What on earth were you comparing with to come up with go as having stricter code checking?

I'd say early stage startups are probably the least likely place for go to be a good choice - it sacrifices a lot for the sake of performance, which only matters once you've made it. As they say, scaling is a nice problem to have.

(Edit: and like Java it makes other sacrifices in the interests of being maintainable by less talented engineers. Again, that's something big companies need, not early stage startups)

2 comments

What we are discovering is that actually it doesn't sacrifice as much as you'd think - and I think that's the point we are trying to make with our article.

You get both the performance, and you get a very lightweight language - I'd say almost as easy to write as Ruby or Python - with great open source support and growing and with a great community around it.

Many modern languages in any field are almost as easy to write as Ruby or Python, have great open source support and a great community.

If you use Ruby or Python, you get extreme dynamism that makes things like ActiveRecord or dealing with external semi-structured data very easy (though you pay a performance cost).

If you use OCaml or Scala you get a lot of control over effects, making the code very safe and easy to reason about. And the type systems let you pull out high-level patterns in your code without going crazy, even when those patterns are very abstract, resulting in more concise and maintainable code.

From here go looks like the worst of both worlds.

Go has both faster run-time performance and stricter type checking than Ruby, Python, or JS, competitors in the server space.

Go development is fast, because the language is simple and it compiles very quickly.

Once you've made it, you certainly don't want to recode. Although, of course, if you've super-made it, you can just get more hardware. But even the largest web companies can run into the performance bottleneck. Like Google, apparently.

The Go Authors say one of the motives for building Go was the very long compile times of building C++ apps for large-scale web development. One thing they mentioned in particular was the large compile times due to processing and reprocessing of #include files. We know Microsoft ran into the same problem because they put Pre-Compiled Headers (PCH files) into their C family tools. Go has an import facility that prevents the problems of the #include file design.

Go is trying to hit the sweet spot for large-scale development. Go is by no means the only one, of course.

Any of you guys know how well .NET does in compiling big web-scale applications? I don't.

> Go has both faster run-time performance and stricter type checking than Ruby, Python, or JS, competitors in the server space.

I don't dispute that, but those aren't the only competitors. If you're willing to give up the extreme dynamicism of those languages, you gain a lot more type-safety and expressiveness, and similar performance, from a modern strongly typed functional language like OCaml/F#/Scala/Haskell.

> Once you've made it, you certainly don't want to recode.

Yes and no. You probably want to accumulate a lot of technical debt during the early stages, meaning you're going to be doing substantial rewriting in any case. The rewrite strategy has worked out pretty well for e.g. Twitter.

> The Go Authors say one of the motives for building Go was the very long compile times of building C++ apps for large-scale web development. One thing they mentioned in particular was the large compile times due to processing and reprocessing of #include files. We know Microsoft ran into the same problem because they put Pre-Compiled Headers (PCH files) into their C family tools. Go has an import facility that prevents the problems of the #include file design.

Sure, like pretty much any language from the past 20 years. The C++ header recompilation problem is basically unique to C++. I can understand Go would seem good if C++ (and Ruby/Python et al) were the only alternatives, but that's really not the case.