Facebook: Moving Fast at Scale

Facebook: Moving Fast at Scale

“Robert Johnson talks about: the need to prepare for horizontal scalability, very short release cycles associated with a streamlined deploying process, and making the entire process faster every day.”

The neatest thing I got from this presentation was how agile Facebook were.  They do daily releases.  To be able to do this, they’ve put control of QA and deployment back to the engineers.  The engineers are responsible for making sure the rollout happens slowly and to keep an eye for post release bugs.

There are still operations people to assist, but they avoid the common scenario where the operations team gets burnt with some bad deploys and then refuses to roll out further updates, which in turn delays the release cycle, time to get feedback for developers, etc.

The presenter claimed that once they got in the habbit of this, the cycle continued to reinforce itself.  Instead of doing a release every 3-4 weeks, 12 a year, and having 12 lessons learnt a year, by doing em dailyish, you get plenty more lessons learnt from each release and the feedback can be used to improve themselves.

Other neat things they talked about were how they scaled – horizontally across their tiers (web server, index/memcache, persistence/mysql).  It seems a common problem of how to find a way to cluster the information in Facebook in any kind of domain centric database or geographic location since FB users are friends all over the world, in different groups, and ‘like’ different things.  The content on your own FB page is dynamic and pulled from sources all over the world.

He also talked about deploying challenges, in particular getting different versions of php and javascript to interact when different versions of FB code were in the wild (different web servers).  Basically by having a repository lib they wrote called GateKeeper that tells the FB code what version it is running on and essentially which code to follow.  Their code looks a bit yuk on the outset – if this version, do this, if that version, do that – but by doing this they bring the problem of inconsistent behaviour due to having different data structures and code for different versions of the software in the wild back into the hands of the developers to manage.  The code doesn’t cry when different versions interact, it knows what to do which means that they can worry about more pressing things.

Not too technical but a great mix of software practice for distributed systems and something that will hopefully get discussed more and more (and hopefully even taught to undergraduates some day)

Another great IDEA presentation

My favourite IDEA presenter, Vaclav Pech is talking about code analysis tools in IDEA.  He talks about

  • Code Inspections (live and on demand)
  • Abstract Syntax Tree
  • The structural code inspection – AST context helps understand the Structure search and replace dialog and how you can use its functionality to make an Idea warning with autofix
  • language analysis
  • the annotations like @NotNull, @Pattern in new JSRs and the IntelliJ specific annotations @Language for analysis of strings
  • stacktrace detection
  • dataflow to/from this
  • duplicate detection
  • dependency analysis

Asus M51SN LCD Screen Upgrade

I wanted to upgrade the resolution of my laptop screen recently but couldn’t find any resources in the ASUS forums or elsewhere online of anyone who had done it previously.  The other requirement I had was that I wanted to not only go for a piecemeal ‘next resolution up’, I wanted to go all the way WUXGA (1920×1200) if possible.

The tech specs on the ASUS website for the M51SN only stated they supported screens up to WSXGA (1600×1050) but I did come across a laptop reseller p4laptops that was offering the model with an aftermarket WUXGA upgrade.  This got my hopes up that I could support the change.

Unfortunately the laptop LCD reseller websites I listed, only provided panels for the M51SN up to WSXGA if you were lucky.  Some were really bad only offering WXGA panels for this model – I certainly didn’t want that given I had a WXGA+ already.

I ended up contacting a panel vendor, Screen Country based in Canada who after explaining the situation of what I found were quite helpful in finding what they thought would be a compatible WUXGA panel.  It did come with some heavy disclaimers though – you do have to pay for the postage back if it doesn’t work and it has to be in new condition to return.  After telling them my existing panel number, which for my M51SN-AS037G, was an AUO2277 (B154PW02 V2), they advised me of a Toshiba panel (LTD154EZ0L), I soon put the order in and it took about a week to arive.

The first thing you should do before installing is unplug the power from the laptop and remove the battery.

As for pulling apart the laptop, I found the M50 disassembly guide.  The laptops are pretty close, the only difference is that they have 8 screws surrounding the screen.  The 4 pictures they had regarding LCD disassembly let me know what to expect.  The bits to know here was that I didn’t need to pull off one of the plastic hinges at the bottom of the screen.  It wont matter too much if they stay on during the LCD replacement.

Once the plastic surrounding the screen was unscrewed and snapped off, the existing LCD needed to be removed.  The other useful resource was the Screen Country support docs which explained how to disconnect the existing panel.  They do the disassembly on 2 laptops.  For this, the 2nd diagram more closely fit the Asus’ layout.  The key bit here is not to remove the immediate 4 screws that are on the edges connecting the LCD bracket to the laptop casing.  All you need to worry about are the smaller screws on the left and right side of the monitor connecting the casing to the monitor.

When pulling off the main video cable that runs along the back of the monitory, just take the tape off and use your fingernails and slowly edge out the video connector.  To remove the inverter cable at the bottom (white and pink coloured wires), its probably best to approach it from the right side and pull out the connector.  The inverter connector only snaps in one way too if u forget which way it is.

What tripped me up was putting the new panel in and plugging the video connector back into the laptop.  Its a very small bit of connectivity, and I didn’t push it in enough.  Its a bit counter intuitive but you have to apply a bit of force here.  Its probably best that once you line up the connector, you use the sticky tape thats goes over the connection to help push the connector in.  You’ll know the difference between partly in, and fully in when the connector slides in that couple of mm more.

Once that was sorted out though, I powered on the laptop and could see my windows boot up in new resolution glory.  A nice moment indeed.  Facebook, web browsing and IDE use are the apps that benefit the most from this change.