Hacker Read top | best | new | newcomments | leaders | about | bookmarklet login

I know, but they don't mention what exactly they are using hg for. Someone (from IRC) said they were using this for some "secret" thing :)

From IRC I know someone has said git didn't scale very well for Facebook.



sort by: page size:

Relevant: Facebook migrated from git to hg awhile back.

Here's a blog post on how they are scaling hg for their monolithic repos https://code.facebook.com/posts/218678814984400/scaling-merc...


Facebook uses Mercurial.

Facebook uses mercurial internally.

Facebook uses Mercurial with a REALLY large monorepo with some extensions[0]. Google also has some usage of Mercurial.

[0] https://bitbucket.org/facebook/hg-experimental


They do support HG in a way. See http://hg-git.github.com/

Yes, Mercurial is being actively developed; Facebook has a great post about why Mercurial and not Git with data: https://code.facebook.com/posts/218678814984400/scaling-merc...

Has Facebook switched to Mercurial? In one news it says so, in the next one read it has a ~50GB Git repo. If they really switched, it would be a good advertisement for Mercurial and its capabilities.

Huh? I don’t know about Facebook but Google for sure does not use Mercurial as monorepo backend (nor does it use Git). There are Git and Mercurial-alike clients to interface with the in-house backend which is a Perforce like thing. Neither Git nor Mercurial would be fun to use at Google scale. Dropbox has a much smaller monorepo hence they can clone the whole Git thing on developer machines. I assume doing the same with Mercurial is impractical as no one has patience for something that slow.

And Facebook added a lot to Mercurial so that it would scale to their stupidly enormous code base.

https://code.facebook.com/posts/218678814984400/scaling-merc...


I didn't, the Hg dev simply used Facebook as a very large, well known software shop that uses Mercurial. We could swap out "Facebook" for "Mozilla" or "Nginx Inc." or a number of open source (either community or corporate backed) projects.

If you have a large repo, it actually helps you to save storage if you don't need the full history on clone by using shallow clone.

hg is still behind this, AFAI can tell from search. FB has this as an extension. https://bitbucket.org/facebook/hg-experimental/

Is FB fully using hg internally, or both Git and hg, because obviously FB has public repo on Github.


Wow, this is pretty cool. Reminds me of the performance optimizations Facebook has done with Mercurial: https://code.facebook.com/posts/218678814984400/scaling-merc...

Mercurial was designed to be easy to extend, and it shows.


I'm sort of amazed that git and mercurial haven't built something like that yet. Makes me a little sad that Facebook created a new scm instead of expanding mercurial to include features like this.

You're right, I should have been more precise: They seem to be switching to Mercurial because they think it's easier to customize Mercurial in order to address scaling issues they're having. (And I'd guess that some of those customization are going to end up in a future Mercurial release.)

Btw, I'm pretty impressed by Facebook's open source efforts.


Facebook is still using mercurial last time I heard

"We made mercurial up to 50x faster than git, more than 2000 improvements" on big repos with lot of history.

This would be their blog post about this: https://code.facebook.com/posts/218678814984400/scaling-merc... and the code at http://selenic.com/repo/hg/shortlog/


Google is working on integrating Mercurial into their workflows, but hasn't quite achieved this goal yet. They are growing their hg team with hopes of replicating what Facebook has done, but they aren't there yet. Check out their contributions:

http://selenic.com/hg/log?rev=google.com&revcount=80

Facebook is almost entirely hg by this point, though.


> Lots of support for monorepos – indeed, this is the main reason that Google, Facebook, and Mozilla are all pouring work into hg and are using it.

They are improving mercurial[1], but are they using it ?

[1] https://code.fb.com/core-data/scaling-mercurial-at-facebook/


Facebook uses a heavily modified fork of Mercurial which they have (as of last year) released publicly, and now refer to it by a new name, "Sapling" (though the command may still be called 'hg' internally). And Sapling actually stores data using Git's on-disk format, along with an entirely bespoke server-side backend. It is an entirely different project from Mercurial, now.
next

Legal | privacy