
dl.google.com now served by Go - mseepgood
https://groups.google.com/forum/?fromgroups=#!topic/golang-nuts/BNUNbKSypE0
======
MatthewPhillips
> Why rewrite in Go? It all started back in April of this year, when I was
> running "apt-get update" at home and noticed that downloads from
> dl.google.com were stalling for no apparent reason. I asked about this on
> our internal Google+ and was put in touch with the right people. It turned
> out that the existing C++ dl.google.com service was no longer actively
> maintained (short of being kept alive) and that it relied on some
> assumptions about Google's internal architecture which were no longer true.

This doesn't instill confidence in Go. That it is a success story with
abandoned projects is not what we need to hear; we need to hear that Google+
runs on Go. Or at least something the size of Google Reader. When a startup is
evaluating what language to build their stack on, dl.google.com is not what
they're aiming for.

~~~
dpcx
While true, the amount of traffic that dl.google.com handles is non-trivial.
If Go can handle that, it can probably handle your startup.

~~~
MatthewPhillips
Apparently an unmaintained C++ app using deprecated libraries and making false
assumptions about Google's internal architecture was able to handle it too,
albeit with poor performance. So I disagree that this move says anything about
Go's capabilities, positive or negative.

~~~
Millennium
I'm inclined to agree that by itself, this doesn't say much about Go at all.

That said, I'm not sure how much a non-open-source program can really do in
terms of marketing Go or any other language. This isn't so much politics as
logistics: you need to be able to see the difference in code to get a sense of
the advantages or disadvantages of one language over another, and if the
program isn't open-source you can't do that. The author can say it's "more
readable" (and does, in fact), but that's not something that can be
quantified, and so there's really nothing but one guy's opinion to go on.

~~~
Evbn
Find me 1% of people who have seen Go call it less readable than actual C++
code in the wild, and I would agree that readability is debatable.

Go has an open source compiler, tool chain, and standard library, only this
top-layer app is the non open source part of the stack.

~~~
Millennium
Yeah, but the top-layer app is where the author's statements would bear out:
that's the code directly comparable to the old C++ code that it replaced. It's
not really practical to give examples of that when you can't open-source the
app; you could maybe do a few trivial snippets or put it all behind a big
thick NDA, but neither method works very well.

------
haarts
I've been following Go rather closely lately and I noticed that these little
announcements come regularly. This is clever marketing (mind share!) and one
of the reasons why Go is going to win out over D et al. When was the last time
you read something about D? (Perhaps I frequent the wrong watering holes.)

~~~
mhd
I'd say we've got two different upgrade paths here. D is aimed squarely at the
C++ crowd, so the biggest enemy it has right now is that C++11 is actually
half-way decent.

Go is a bit more difficult to pin down, demographic-wise, but I'd say it's a
mix between C minimalists and Pythonistas and other scripters who want
something faster but don't want to go with a JVM-language or go all the way
down to bare metal.

This target group as well as Google's pedigree is why you're reading a lot
about it at web programmer's forums (like, well, this one), consisting mostly
of people who wouldn't (and couldn't) touch C++ with a ten foot pole.

~~~
cageface
My interest in Go has a lot to do with static typing. Dynamic languages are
great for brewing things up quickly but static typing is just far too useful
for catching dumb bugs early and for enabling powerful tooling.

Perhaps more sophisticated type systems like those found in Haskell are worth
the extra effort but my money is on Go for its simplicity and pragmatism.

~~~
tikhonj
Haskell's type system may be sophisticated, but it's also very simple. There's
no sub-typing of any sort, for example.

With a bit of mathematical notation--which may be a little foreign but is not
_that_ complicated--you can fit all of Haskell's type inference rules on a
single page. These rules specify how the type system behaves _and_ how to
infer types! (The type inference, which may seem magical, is just a constraint
satisfaction problem and so is easy to specify.)

I would not be surprised if Go's typing rules are _more_ complex than
Haskell's. All while giving you less static guarantees and less thorough type
inference.

~~~
sirclueless
Haskell has algebraic datatypes and typeclasses. Both of those are more
complex than Go's type system, which is more or less just primitives, structs,
and interfaces.

Haskell's type system may in fact have fewer moving parts, but it has a LOT
more emergent complexity than Go's does.

------
16s
Languages such as Go would interest me more if they were not controlled by one
company. I've had bad experiences with corporate languages in the past. This
is one reason I'll stick with C++. It has an ISO standard and many different
compilers from different companies. I feel more in control and less likely to
be shafted by Google, Oracle, Microsoft or whoever owns the language de jour.

~~~
icey
a) Go is open source

b) Not sure why you've included Microsoft in your list. The C# specification
has an ECMA and ISO standard.(ECMA-334 and ISO/IEC 23270:2006)

~~~
16s
Java is open source too and C# is not the only corporate language from
MicroSoft.

~~~
kinofcain
Go and the go std lib are licensed under a bsd license, which is a more
liberal license than java and the jdk and would avoid things like the oracle
lawsuit against android.

So yes, just because it's open source doesn't mean much, but it's open source
with a very liberal license, which does mean something.

~~~
Shamanmuni
How does the BSD license avoid something like the Oracle lawsuit against
Android? From my understanding it wouldn't have made a difference.

~~~
mseepgood
The Oracle lawsuit is based on the Java ME licensing restrictions:
[http://en.wikipedia.org/wiki/Embedded_Java#Licencing_restric...](http://en.wikipedia.org/wiki/Embedded_Java#Licencing_restrictions)

A pure BSD license does not have these restrictions.

~~~
pyre
Originally, the Oracle lawsuit had some patent claims in it, IIRC. They were
thrown out though. I can't recall if they were thrown out by the judge or if
Google spent the time/money/lawyers to get them invalidated.

~~~
jlgreco
Any open source language, even those not affiliated with a company, could be
vulnerable to that though.

Now, in this particular case (for those who can digest legalease):
<http://golang.org/PATENTS>

~~~
chimeracoder
IANAL, I don't think that's true for the Apache license, because it includes a
clause that explicitly reassigns patents (or at least licenses any relevant
patents).

------
knodi
I have been working with Go for about 6 months now and I'm in love with Go. I
find it simple, easy and fun to write in.

~~~
why-el
I dont know where you come from, language-wise, but do you think one can make
a nice transition if they are used to Ruby and JS? I want to experiment
building a simple web server and thought maybe I should use Go.

Specifically, what was it that convinced you that Go is "fun to write in"?
Thats mostly what I care about too.

~~~
grey-area
If you're coming from Ruby, you'll feel right at home, perhaps less so if
you're coming from JS. What I found surprising and fun about Go is just how
similar it is to scripting languages in style, and how much baggage it drops
from C (header files, explicit types, pointer arithmetic etc).

The lack of header files, clear and simple syntax, minimal language core, and
predictable standard library all combine to make it feel very like a compiled
Ruby, though obviously there are differences. The main differences coming from
a dynamic background are the type system, interfaces, imports and packages (no
circular imports), and the lack of dynamic loading - everything is loaded at
compile time. Interfaces feel a little like duck typing with checks on whether
a type really does quack like a duck at compile time!

If you mean writing a web app, it's not really as mature as other ecosystems
in terms of support for this, but would be great for a smaller, minimal web-
app, if you mean writing a web server from scratch, go is a great place to
start, and even has a good example for you to look at in the built-in server:

<http://golang.org/src/pkg/net/http/server.go>

------
djhworld
Cool.

As a sidenote is there any way of viewing google group posts without logging
into google? I'm at work at the moment and my google account keeps on getting
logged out as cookies are deleted frequently.

~~~
asdfaoeu
This comes up every time someone links to Google. If you have any Google
cookies it will make you log in. Open it up in an incognito window or
something if you don't want to.

------
stephen
Huh; did the full switch over just happen?

Out of the blue 1-2 days ago, a DTD hosted on dl.google.com
(<http://dl.google.com/gwt/DTD/xhtml.ent>) started semi-randomly timing out
and hanging Eclipse.

(This was due to the Eclipse UI asking "Is this your XML file?" for every XML
file in the project, for every plugin, and one of the plugins, IvyDE, ended up
not having fetch-eternal-dtds turned off. What a silly default.)

~~~
bradfitz
No, it's been running for months.

------
signa11
as another example of stuff in go, there is a window-manager called "wingo"
that is still pretty alpha, but kinda-sorta-works
<https://github.com/BurntSushi/wingo>

~~~
burntsushi
> but kinda-sorta-works

Hey man, I've been running it for at least week for day-to-day work and it
hasn't crashed yet. :-)

I'm quite pleased that most of the bugs reported so far are related to state
transition bugs, which is the part of Wingo I'm least happy with.

And this includes using completely untested libraries that implement the
entire X client stack (from the wire to the screen) in pure Go. Which amounts
to roughly 31,000 lines of code.

N.B. I blame Go (mostly) for this state of affairs.

------
playingcolours
Can Go be a good language to implement NoSql database?

~~~
jlouis
I would think so. It has many of the properties you would like in implementing
a database system. First, the language is statically typed and executes
surprisingly quickly. Second, it can handle high concurrency which is needed
in a database since you will have many clients connection. Third, the
libraries letting you interface with protobufs and HTTP provides two pretty
simple ways to connect your Database interface to the rest of the world.

The perhaps most glaring problem, compared to the world of Erlang where I come
from, is the lack of built-in seamless distribution. Many NoSQL databases
trades consistency for availability and more machines. You are on your own
implementing this.

Also, the lack of a ZooKeeper-like library may be something you will end up
implementing. That, or perhaps the basis of the Dynamo paper.

~~~
azth
> I would think so. It has many of the properties you would like in
> implementing a database system. First, the language is statically typed and
> executes surprisingly quickly. Second, it can handle high concurrency which
> is needed in a database since you will have many clients connection. Third,
> the libraries letting you interface with protobufs and HTTP provides two
> pretty simple ways to connect your Database interface to the rest of the
> world.

But that is not unique to Go, it may as well apply to Java, Scala, etc...

------
sanatgersappa
Always nice to see some real-world application of a promising technology.

------
signa11
<rant> this is weird, i had posted the same story approx 7 hours ago, which
received 2 votes, now the same story, 5 hours later is on the front-page
<http://news.ycombinator.com/item?id=4700943>

~~~
jrockway
7 hours ago everyone was asleep. Now everyone is at work looking for something
to distract them.

------
jff
"Uh oh, another story about success in Go, better post some FUD!" Nobody's yet
come in to say how using Go on a 10-year-obsolete computer (32-bit PC) may
have problems with garbage collection, pretty unusual for a Go post.

