SlideShare uma empresa Scribd logo
1 de 42
Baixar para ler offline
erlang at hover.in




    Bhasker V Kode
    co­founder  & CTO at hover.in

    at Erlang Factory, London
    June 26, 2009
                                 

                                    http://developers.hover.in
brief introduction to hover.in
    choose words from your blog, & decide what content / ad 
              you want when you hover* over it
                                           * or other events like click,right click,etc
                                     or...
                 the worlds first publisher driven 
             in­text content & ad delivery platform...
                                 or
lets web publishers push client­side event handling to the 
  cloud, to run various rich applications called hoverlets

demo at http://start.hover.in/ and  http://hover.in/demo
          more at http://hover.in ,  http://developers.hover.in/blog/ 
                                        

                                                                 http://developers.hover.in
<html> <body>
 <a href="http://facebook.com" title="
http://onclick.hover.in/hoverlet/hover.in/crunchbase/facebook" > facebook  
profile from crunchbase </a> 

 <a title="http://onclick.hover.in/hoverlet/hover.in/twittersearch/election"  
href=”#”>election tweets</a>   

 <a href="#" title="http://onclick.hover.in/hoverlet/hover.in/nytimes/iphone" 
> iphone on NYT</a>

 <a title="http://onclick.hover.in/hoverlet/hover.in/relatedyoutube/cooking"  
href=”#” >cooking videos</a>  from youtube. 

 <script src="http://start.hover.in/script" id="hi_start"  type="text/javascript"></script>
                                                  
 </body><html>                                                          http://developers.hover.in
➔
        hover.in founded late 2007




                               

                                     http://developers.hover.in
➔
        hover.in founded late 2007 
    ➔
        the web ~ 10­ 20 years old 




                               

                                      http://developers.hover.in
➔
        hover.in founded late 2007 
    ➔
        the web ~ 10­ 20 years old 
    ➔
        humans 100's of thousands of years 




                               

                                          http://developers.hover.in
➔
        hover.in founded late 2007 
    ➔
        the web ~ 10­ 20 years old 
    ➔
        humans 100's of thousands of years 
    ➔
        but bacteria.... around for millions of years
        ... so this talk is going to be about what we can 
        learn from bacteria, the brain, and memory in 
        a concurrent world followed by hover.in's erlang 
        setup and lessons learnt 

                                              http://developers.hover.in
%% Should_we_glow_underwater.erl
%% query each cell's protein and if
%% total +ves pass some value, then glow!

%% process spawned to hold state of +ves
Pid = spawn(fun()­>
      should_we_glow(0,length(Cells),0) 
  end)


%% querying cell protein ,message passing
[ Pid !{in, Cell } || Cell < Cells ]
                       

                                   http://developers.hover.in
should_we_glow(Ctr, Max, Acc)­>
  receive
   {in,Cell}­> 
     One_or_zero  = should_i_glow(Cell),
     case Ctr of 
       Max ­> done;
       _ ­> 
        case Acc of 
          ?SOME_VAL ­> 
               glow_for_8_hours(), done;
          _ ­>
          NewAcc = One_or_zero + Acc,
          should_we_glow(Ctr+1,Max,NewAcc)
       end;
  _ ­> error
                       
end                              http://developers.hover.in
some traits of bacteria
    ●
        each bacteria cell spawns its own proteins
    ●
        All bacteria have some sort of  some presence 
        & replies associated, (asynchronous comm.)
    ●
        group dynamics exhibits 'list fold' ish operation
    ●
        only when the Accumulator is > some guard 
        clause, will group­dynamics of making light 
        (bioluminiscence) work (eg: in deep sea)
                                 

                                              http://developers.hover.in
spawning, in practice
    ●
        for a single google search result, the same 
        requests are sent to multiple machines( ~1000 
        as of 09), which ever replies the quickest wins. 
    ●
        in amazon's dynamo architecture that powers 
        S3, use a (3,2,2) rule . ie Maintain 3 copies of 
        the same data, reads/writes are succesful only 
        when 2 concurrent requests succeed. This ratio 
        varies based on SLA, internal vs public service. 
        ( more on conflict resolution... )
                                  

                                               http://developers.hover.in
pattern matching behaviour
    ●
        each molecule connects to its specific receptor 
        protein to complete the missing piece,to trigger 
        the group behaviour that are only succesful 
        when all of the cells participate in unison.
    ●
        Type = case UserType of 
                          user ­> true;
                         admin ­> true;
                         _Else  ­> false
 
                   end                 

                                             http://developers.hover.in
supervisors, workers
    ●
        as bacteria grow, they split into two. when 
        muscle tears, it knows exactly what to replace.
    ●
        erlang supervisors can decide restart policies: if 
        one worker fails, restart all .... or if one worker 
        fails, restart just that worker, more tweaks.
    ●
        can spawn multiple workers on the fly, much 
        like the need for launching a new ec2 instant

                                 

                                              http://developers.hover.in
inter­species communication
    ●
        if you look at your skin – consists of very many 
        different species, but all bacteria found to 
        communicate using one common chemical 
        language. 




                                

                                             http://developers.hover.in
inter­species communication
    ●
        if you look at your skin – consists of very many 
        different species, but all bacteria found to 
        communicate using one common chemical 
        language. 
        hmmmmmmmmmmmmmmmmmmm..............
        ....serialization ?!
        ....a common protein interpretor ?!
        ....or perhaps just­in­time protein compilation?!
                                

                                             http://developers.hover.in
interspecies comm. in practice
    ➔
        attempts at serialization , cross language 
        communication include:
        ➔
            thrift ( by facebook) 
        ➔
            protocol buffers ( by google) 
        ➔
            en/decoding , port based communication ( erlang<­
            >python at hover.in )
        ➔
            rabbitMQ shows speeds of several thousands of  
            msgs/sec between python <­> erlang (by using...?)
                                      

                                                 http://developers.hover.in
talking about scaling
    The brain of the worker honeybee weighs about 
     1mg ( ~ 950,000 neurons )
    ●
        Flies acrobatically , recognizes patterns, 
        navigates , communicates, etc
    ●
        Energy consumption: 10−15 J/op, at least 106 
        more efficient than digital silicon neurons 


                                

                                              http://developers.hover.in
the human brain
    ●
        100 billion neurons, stores ~100 TB
    ●
        Differential analysis e.g., we compute color
    ●
        Multiple inputs: sight, sound, taste, smell, touch
    ●
        Facial recognition subcircuits, peripheral vision
    ●
        in essence  ­ the left & right brain vary in:
        left ­> persistent disk , handles past/future
        right ­> temporal caches! , handles present
                                 

                                              http://developers.hover.in
in­memory is the new embedded
    ●
        servers as of '09 typically have 4 ­ 16 GB RAM 
    ●
        stats of how companies are adding nodes




                               

                                            http://developers.hover.in
in­memory is the new embedded
    ●
        caching systems avoid disk/db makes sense
    ●
        caching systems for processing tasks makes 
        sense
    ●
        but ....
    ●
        keeping your entire data in­memory by having N 
        number of nodes ? 


                              

                                           http://developers.hover.in
in­memory is the new embedded
    ●
        keeping your entire data in­memory by having N 
        number of nodes ,  ( where N = total data in gb / 
        max ram per node ) is like ...
        –   building a billion dollar company with 999 milion 
            dollars of funding!
            or 
        –   having only a right brain !
    ●
        surely we can do better than that!
                                     

                                                    http://developers.hover.in
in­memory capacity planning
    ●
        No matter how many machines you have, and 
        how many cores, in production level – your 
        product could be defined by how well you  
        design your in­memory / RAM strategies.
    ●
        alternatives to avoid swapping could be – just 
        leaving results partioned on diff nodes, or 
        additional tasks to reduce the data­load further 
        until they can fit in memory
                                

                                             http://developers.hover.in
in­memory capacity planning
    ●
        parallizing jobs in­memory is a lot of fun...
    ●
        but...
    ●
        more often bottleneck will not be how well you 
        can paralliize, but how much you need to 
        parallize so that memory does'nt swap (eg: || db 
        reads)


                                 

                                               http://developers.hover.in
(1)#1 shard thy data to make it sufficiently un­related

    ●
        typical web backends – all user data in one 
        table – then clustering just splits that on artibary 
        basis. eg: query user table where id=user1, 
    ●
        what if you have N concurrent process's 
        accessing N diff user tables – no locks, you can 
        ||'ze & results can come back asynchronously 
        since sufficiently un­related. 
    ●
        Warning: but more atoms  ( list_to_atom atoms 
                                

        aren't garbage collected )          http://developers.hover.in
(1)#2 implementing flowcontrol

    ●
        great to handle both bursts or silent traffic & to 
        determine bottlenecks.(eg ur own,rabbitmq,etc )
    ●
        eg1: when we addjobs to the queue, if it takes 
        greater than X consistently we move it to high 
        traffic bracket, do things differently, possibly 
        add workers  or ignore based on the task.
    ●
        eg2: amazon shopping carts, are known to be 
        extra resilient to write failures, (dont mind 
 
        multiple versions of them over time) http://developers.hover.in
                                   
(1)#3 all data is important, but some less important

    ●
        priority queue used to built heat­seeking algo 
        ( priority to crawl webpages that get more hits 
        rather than depth­first or breadth­first) 
    ●
        can configure max number of buckets
    ●
        can configure max number of urls per bucket
    ●
        can configure pyramid like queue. ( moving 
        from lower buckets to higher is easier than 
        moving from high to higher ) 
                                

                                                http://developers.hover.in
erlang in a crawler architecture ?
    ●
        each time a hit occurs for a url, it moves from bucket N 
        to bucket N+1




                                    

                                                  http://developers.hover.in
erlang in a crawler architecture ?
    ●
        each time a hit repeats for a URL , it moves from 
        bucket N to bucket N+1
    ●
        crawls happen from top down (priority queue)




                                   

                                                  http://developers.hover.in
erlang in a crawler architecture ?
    ●
        each time a hit repeats for a URL , it moves from 
        bucket N to bucket N+1
    ●
        crawls happen from top down (priority queue)
    ●
        so the bucket is locked, so that locked urls dont keep 
        move up anymore




                                   

                                                  http://developers.hover.in
erlang in a crawler architecture ?
    ●
        each time a hit repeats for a URL , it moves from 
        bucket N to bucket N+1
    ●
        crawls happen from top down (priority queue)
    ●
        so the bucket is locked, so that locked urls dont keep 
        move up anymore
    ●
        each user/site has their own priority queues, which 
        keep shifting round­robin after every X urls crawled 
        per user/site


                                   

                                                  http://developers.hover.in
erlang in a crawler architecture ?
    ●
        each time a hit repeats for a URL , it moves from 
        bucket N to bucket N+1
    ●
        crawls happen from top down (priority queue)
    ●
        so the bucket is locked, so that locked urls dont keep 
        move up anymore
    ●
        each user/site has their own priority queues, which 
        keep shifting round­robin after every X urls crawled 
        per user/site
    ●
        python crawler leaves text files which dirty loaded into 
        fragmented mnesia          

                                                   http://developers.hover.in
(1)#3 time spent x RAM utilization = a constant
    (2)          eg: of || db reads
    (3)
    (4)#4 before every succesful persistent write & after 
      every succesful persistent read is an in­memory one
    (5)        eg: hi_cache_worker's used to build
    (6)              most recent queue's 
                                       

                                                http://developers.hover.in
(1)#5 before every succesful persistent write & after 
         every succesful persistent read is an in­memory one

    ●
        you listen to a phone number in batch's of 3 or 4 
        digits. the part that absorbs just before writing 
        (temporal), until you write into your contact book 
        or memorize it ( persistent)
    ●
        eg: if LRU cache exists in­memory, like 100 
        most recent url's or tags, then no need to parse 
        server logs for computation, try during writes 
        itself . No logs, no files. live buzz analytics!
                                  

                                                 http://developers.hover.in
(1)#6  know thy RAM, trial/error to find ideal dataload

●
    eg: || db reads  if || happens so fast, mem probs
●
    replication vs location transparency, are they 
    fragmented, are some nodes read­only ? (rpc...)
●
    need metadata for which node to acess for user1, 
    (or use hashing fn like memcache)
●
    are tables in­memory (right brain ), cached from 
    disk , or on disk alone ( left brain ) 
 
●
    fortunately mnesia allows highly granular choices
                            

                                              http://developers.hover.in
(1)#7 what cannot be measured cannot be improved

●
    you can't improve what you can't measure. an 
    investment in debugging utilities is a good 
    investment
●
    looking forward to debugging with dtrace,gproc 
    etc but until then – just a set/get away!
●
    using tsung (written in erlang again ) – load 
    performance testing tool, for simulating 100's of 
    concurrent users/requests , and great for 
    analysing bottlenecks of your system ,CDN's ) , 
                            

                                           http://developers.hover.in
hi_cache_worker
    ●
        a circular queue implemented via gen_server
    ●
        set ( ID  , Key , Value , OptionsList)
        Options are     {purge, <true| false>}
                                { size , <integer> }
                                { set_callback , <Function> }
                                { delete_callback , <Function> }
                                { get_callback , <Function> }
                                { timeout, <int>, <Function> }
 
        ID is usually a siteid  or  “global”
                                          

                                                   http://developers.hover.in
●
    C = hi_cache_worker,
    C:set ( User1, “recent_saved” , Value) 
    C:set ( “global”, “recent_hits” , Value  
                                      [{size,1000}] ) 

    C:get (“global”,”recent_voted”)
    C:get (User1,”recenthits”)
    C:get (User1,”recent_cron_times”)
●
    ( Note: initially used in debugging internally ­> 
    then reporting ­> next in public community stats)
                                

                                                    http://developers.hover.in
7 rules of in­memory capacity planning
    (1) shard thy data to make it sufficiently un­related
    (2) implementing flowcontrol
    (3) all data is important, but some less important
    (4) time spent x RAM utilization = a constant
    (5) before every succesful persistent write & after 
      every succesful persistent read is an in­memory one
    (6) know thy RAM, trial/error to find ideal dataload
    (7) what cannot be measured cannot be improved
                              

                                                http://developers.hover.in
summary of erlang at hover.in
    ●
        LYME stack since ~dec 07 ,  3 nodes (64­bit 4gb )
    ●
        python crawler, associated NLP parsers, cpu time­
        splicing algo's for cron's app, configurable priority 
        queue's for heat­seeking algo's app,  flowcontrol 
        app , caching app , pagination app for memoizing
    ●
        remote node debugger, cyclic queue workers, lru 
        cache workers , headless­firefox for thumbnails 
    ●
        touched 1 million hovers/month in May'09 after 
        launching closed beta to publishers in Jan 09
                                 

                                               http://developers.hover.in
summary of our erlang modules
  rewrites.erl error.erl frag_mnesia.erl hi_api_response.erl   hi_appmods_api_user.erl  
      hi_cache_app.erl , hi_cache_sup.erl   hoverlingo.erl hi_cache_worker.erl 
     hi_lru_worker.erl  hi_classes.erl  hi_community.erl 
     hi_cron_hoverletupdater_app.erl  hi_cron_hoverletupdater.erl 
     hi_cron_hoverletupdater_sup.erl  hi_cron_kwebucket.erl  hi_crypto.erl 
     hi_flowcontrol_hoverletupdater.erl hi_htmlutils_site.erl hi_hybridq_app.erl 
     hi_hybridq_sup.erl hi_hybridq_worker.erl hi_login.erl hi_mailer.erl 
     hi_messaging_app.erl hi_messaging_sup.erl hi_messaging_worker.erl 
     hi_mgr_crawler.erl hi_mgr_db_console.erl hi_mgr_db.erl hi_mgr_db_mnesia.erl 
     hi_mgr_hoverlet.erl hi_mgr_kw.erl hi_mgr_node.erl hi_mgr_thumbs.erl 
     hi_mgr_traffic.erl hi_nlp.erl hi_normalizer.erl hi_pagination_app.erl   
     hi_pagination_sup.erl, hi_pagination_worker.erl hi_pmap.erl  hi_register_app.erl 
     hi_register.erl, hi_register_sup.erl, hi_register_worker.erl 
     hi_render_hoverlet_worker.erl hi_rrd.erl , hi_rrd_worker.erl hi_settings.erl  
     hi_sid.erl hi_site.erl hi_stat.erl hi_stats_distribution.erl hi_stats_overview.erl 
                                                 
     hi_str.erl hi_trees.erl hi_utf8.erl hi_yaws.erl                     http://developers.hover.in
references
    ●
        http://developers.hover.in
    ●
        http://erlang.org 
    ●
        http://memcached.org , http://rabbitmq.org/ http://highscalability.com/ 
    ●
        http://www.allthingsdistributed.com/files/amazon­dynamo­sosp2007.pdf
    ●
        shoutout to everyone at #erlang ! 
    ●
        amazing brain­related talks at   http://ted.com ,

    ●
         go read more about the brain and hack on 
        erlang NOW!
                                           

                                                              http://developers.hover.in
thank you




     

           http://developers.hover.in

Mais conteúdo relacionado

Mais procurados

Chat bot-automation-hubot
Chat bot-automation-hubotChat bot-automation-hubot
Chat bot-automation-hubotEueung Mulyana
 
Puppet getting started by Dirk Götz
Puppet getting started by Dirk GötzPuppet getting started by Dirk Götz
Puppet getting started by Dirk GötzNETWAYS
 
JUDCon 2010 Boston : BoxGrinder
JUDCon 2010 Boston : BoxGrinderJUDCon 2010 Boston : BoxGrinder
JUDCon 2010 Boston : BoxGrindermarekgoldmann
 
TorqueBox for Rubyists
TorqueBox for RubyistsTorqueBox for Rubyists
TorqueBox for Rubyistsbobmcwhirter
 
JUDCon 2010 Boston : TorqueBox
JUDCon 2010 Boston : TorqueBoxJUDCon 2010 Boston : TorqueBox
JUDCon 2010 Boston : TorqueBoxmarekgoldmann
 
TorqueBox at DC:JBUG - November 2011
TorqueBox at DC:JBUG - November 2011TorqueBox at DC:JBUG - November 2011
TorqueBox at DC:JBUG - November 2011bobmcwhirter
 
Under the Dome (of failure driven pipeline)
Under the Dome (of failure driven pipeline)Under the Dome (of failure driven pipeline)
Under the Dome (of failure driven pipeline)Maciej Lasyk
 
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...bobmcwhirter
 
PuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & Hadoop
PuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & HadoopPuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & Hadoop
PuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & HadoopWalter Heck
 
Go for SysAdmins - LISA 2015
Go for SysAdmins - LISA 2015Go for SysAdmins - LISA 2015
Go for SysAdmins - LISA 2015Chris McEniry
 
Gofer 200707
Gofer 200707Gofer 200707
Gofer 200707oscon2007
 
Jruby a Pi and a database
Jruby a Pi and a databaseJruby a Pi and a database
Jruby a Pi and a databasePhilipp Fehre
 
Toplog candy elves - HOCM Talk
Toplog candy elves - HOCM TalkToplog candy elves - HOCM Talk
Toplog candy elves - HOCM TalkPatrick LaRoche
 
Linux, Apache, Mysql, PHP
Linux, Apache, Mysql, PHPLinux, Apache, Mysql, PHP
Linux, Apache, Mysql, PHPwebhostingguy
 
Complex Made Simple: Sleep Better with TorqueBox
Complex Made Simple: Sleep Better with TorqueBoxComplex Made Simple: Sleep Better with TorqueBox
Complex Made Simple: Sleep Better with TorqueBoxbobmcwhirter
 
Intro to-ansible-sep7-meetup
Intro to-ansible-sep7-meetupIntro to-ansible-sep7-meetup
Intro to-ansible-sep7-meetupRamesh Godishela
 
Burp Plugin Development for Java n00bs - 44CON 2012
Burp Plugin Development for Java n00bs - 44CON 2012Burp Plugin Development for Java n00bs - 44CON 2012
Burp Plugin Development for Java n00bs - 44CON 201244CON
 

Mais procurados (20)

Chat bot-automation-hubot
Chat bot-automation-hubotChat bot-automation-hubot
Chat bot-automation-hubot
 
At Scale With Style
At Scale With StyleAt Scale With Style
At Scale With Style
 
Puppet getting started by Dirk Götz
Puppet getting started by Dirk GötzPuppet getting started by Dirk Götz
Puppet getting started by Dirk Götz
 
Devignition 2011
Devignition 2011Devignition 2011
Devignition 2011
 
JUDCon 2010 Boston : BoxGrinder
JUDCon 2010 Boston : BoxGrinderJUDCon 2010 Boston : BoxGrinder
JUDCon 2010 Boston : BoxGrinder
 
TorqueBox for Rubyists
TorqueBox for RubyistsTorqueBox for Rubyists
TorqueBox for Rubyists
 
JUDCon 2010 Boston : TorqueBox
JUDCon 2010 Boston : TorqueBoxJUDCon 2010 Boston : TorqueBox
JUDCon 2010 Boston : TorqueBox
 
TorqueBox at DC:JBUG - November 2011
TorqueBox at DC:JBUG - November 2011TorqueBox at DC:JBUG - November 2011
TorqueBox at DC:JBUG - November 2011
 
Under the Dome (of failure driven pipeline)
Under the Dome (of failure driven pipeline)Under the Dome (of failure driven pipeline)
Under the Dome (of failure driven pipeline)
 
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...
 
PuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & Hadoop
PuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & HadoopPuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & Hadoop
PuppetCamp SEA 1 - Using Vagrant, Puppet, Testing & Hadoop
 
Go for SysAdmins - LISA 2015
Go for SysAdmins - LISA 2015Go for SysAdmins - LISA 2015
Go for SysAdmins - LISA 2015
 
Python in Action (Part 2)
Python in Action (Part 2)Python in Action (Part 2)
Python in Action (Part 2)
 
Gofer 200707
Gofer 200707Gofer 200707
Gofer 200707
 
Jruby a Pi and a database
Jruby a Pi and a databaseJruby a Pi and a database
Jruby a Pi and a database
 
Toplog candy elves - HOCM Talk
Toplog candy elves - HOCM TalkToplog candy elves - HOCM Talk
Toplog candy elves - HOCM Talk
 
Linux, Apache, Mysql, PHP
Linux, Apache, Mysql, PHPLinux, Apache, Mysql, PHP
Linux, Apache, Mysql, PHP
 
Complex Made Simple: Sleep Better with TorqueBox
Complex Made Simple: Sleep Better with TorqueBoxComplex Made Simple: Sleep Better with TorqueBox
Complex Made Simple: Sleep Better with TorqueBox
 
Intro to-ansible-sep7-meetup
Intro to-ansible-sep7-meetupIntro to-ansible-sep7-meetup
Intro to-ansible-sep7-meetup
 
Burp Plugin Development for Java n00bs - 44CON 2012
Burp Plugin Development for Java n00bs - 44CON 2012Burp Plugin Development for Java n00bs - 44CON 2012
Burp Plugin Development for Java n00bs - 44CON 2012
 

Destaque

Kafka & Storm - FifthElephant 2015 by @bhaskerkode, Helpshift
Kafka & Storm - FifthElephant 2015 by @bhaskerkode, HelpshiftKafka & Storm - FifthElephant 2015 by @bhaskerkode, Helpshift
Kafka & Storm - FifthElephant 2015 by @bhaskerkode, HelpshiftBhasker Kode
 
hover.in at CUFP 2009
hover.in at CUFP 2009hover.in at CUFP 2009
hover.in at CUFP 2009Bhasker Kode
 
end user programming & yahoo pipes
end user programming & yahoo pipesend user programming & yahoo pipes
end user programming & yahoo pipesBhasker Kode
 
Recursion & Erlang, FunctionalConf 14, Bangalore
Recursion & Erlang, FunctionalConf 14, BangaloreRecursion & Erlang, FunctionalConf 14, Bangalore
Recursion & Erlang, FunctionalConf 14, BangaloreBhasker Kode
 
QCON SP 2016 - Elixir: Tolerância a Falhas para Adultos
QCON SP 2016 - Elixir: Tolerância a Falhas para AdultosQCON SP 2016 - Elixir: Tolerância a Falhas para Adultos
QCON SP 2016 - Elixir: Tolerância a Falhas para AdultosFabio Akita
 
Functional Programing
Functional ProgramingFunctional Programing
Functional ProgramingMax Arshinov
 
There Are Literally Thousands of Erlang Projects
There Are Literally Thousands of Erlang ProjectsThere Are Literally Thousands of Erlang Projects
There Are Literally Thousands of Erlang ProjectsPierre Fenoll
 
High Performance Erlang - Pitfalls and Solutions
High Performance Erlang - Pitfalls and SolutionsHigh Performance Erlang - Pitfalls and Solutions
High Performance Erlang - Pitfalls and SolutionsYinghai Lu
 
Erlang Supervision Trees
Erlang Supervision TreesErlang Supervision Trees
Erlang Supervision TreesDigikrit
 
The Erlang Programming Language
The Erlang Programming LanguageThe Erlang Programming Language
The Erlang Programming LanguageDennis Byrne
 
Elixir - Easy fun for busy developers @ Devoxx 2016
Elixir - Easy fun for busy developers @ Devoxx 2016Elixir - Easy fun for busy developers @ Devoxx 2016
Elixir - Easy fun for busy developers @ Devoxx 2016David Schmitz
 
FunctionalConf '16 Robert Virding Erlang Ecosystem
FunctionalConf '16 Robert Virding Erlang EcosystemFunctionalConf '16 Robert Virding Erlang Ecosystem
FunctionalConf '16 Robert Virding Erlang EcosystemRobert Virding
 
Repeating History...On Purpose...with Elixir
Repeating History...On Purpose...with ElixirRepeating History...On Purpose...with Elixir
Repeating History...On Purpose...with ElixirBarry Jones
 
Erlang и n2o. Web-разработка без JavaScript
Erlang и n2o. Web-разработка без JavaScriptErlang и n2o. Web-разработка без JavaScript
Erlang и n2o. Web-разработка без JavaScriptEugene Tataurov
 
RabbitMQ: Message queuing that works
RabbitMQ: Message queuing that worksRabbitMQ: Message queuing that works
RabbitMQ: Message queuing that worksCodemotion
 
Rethink programming: a functional approach
Rethink programming: a functional approachRethink programming: a functional approach
Rethink programming: a functional approachFrancesco Bruni
 
Erlang and Elixir
Erlang and ElixirErlang and Elixir
Erlang and Elixirhayabusa333
 

Destaque (20)

Kafka & Storm - FifthElephant 2015 by @bhaskerkode, Helpshift
Kafka & Storm - FifthElephant 2015 by @bhaskerkode, HelpshiftKafka & Storm - FifthElephant 2015 by @bhaskerkode, Helpshift
Kafka & Storm - FifthElephant 2015 by @bhaskerkode, Helpshift
 
hover.in at CUFP 2009
hover.in at CUFP 2009hover.in at CUFP 2009
hover.in at CUFP 2009
 
end user programming & yahoo pipes
end user programming & yahoo pipesend user programming & yahoo pipes
end user programming & yahoo pipes
 
Recursion & Erlang, FunctionalConf 14, Bangalore
Recursion & Erlang, FunctionalConf 14, BangaloreRecursion & Erlang, FunctionalConf 14, Bangalore
Recursion & Erlang, FunctionalConf 14, Bangalore
 
QCON SP 2016 - Elixir: Tolerância a Falhas para Adultos
QCON SP 2016 - Elixir: Tolerância a Falhas para AdultosQCON SP 2016 - Elixir: Tolerância a Falhas para Adultos
QCON SP 2016 - Elixir: Tolerância a Falhas para Adultos
 
Beam me up, Scotty
Beam me up, ScottyBeam me up, Scotty
Beam me up, Scotty
 
Functional Programing
Functional ProgramingFunctional Programing
Functional Programing
 
There Are Literally Thousands of Erlang Projects
There Are Literally Thousands of Erlang ProjectsThere Are Literally Thousands of Erlang Projects
There Are Literally Thousands of Erlang Projects
 
High Performance Erlang - Pitfalls and Solutions
High Performance Erlang - Pitfalls and SolutionsHigh Performance Erlang - Pitfalls and Solutions
High Performance Erlang - Pitfalls and Solutions
 
Erlang Supervision Trees
Erlang Supervision TreesErlang Supervision Trees
Erlang Supervision Trees
 
The Erlang Programming Language
The Erlang Programming LanguageThe Erlang Programming Language
The Erlang Programming Language
 
Elixir - Easy fun for busy developers @ Devoxx 2016
Elixir - Easy fun for busy developers @ Devoxx 2016Elixir - Easy fun for busy developers @ Devoxx 2016
Elixir - Easy fun for busy developers @ Devoxx 2016
 
Erlang containers
Erlang containersErlang containers
Erlang containers
 
FunctionalConf '16 Robert Virding Erlang Ecosystem
FunctionalConf '16 Robert Virding Erlang EcosystemFunctionalConf '16 Robert Virding Erlang Ecosystem
FunctionalConf '16 Robert Virding Erlang Ecosystem
 
Elixir intro
Elixir introElixir intro
Elixir intro
 
Repeating History...On Purpose...with Elixir
Repeating History...On Purpose...with ElixirRepeating History...On Purpose...with Elixir
Repeating History...On Purpose...with Elixir
 
Erlang и n2o. Web-разработка без JavaScript
Erlang и n2o. Web-разработка без JavaScriptErlang и n2o. Web-разработка без JavaScript
Erlang и n2o. Web-разработка без JavaScript
 
RabbitMQ: Message queuing that works
RabbitMQ: Message queuing that worksRabbitMQ: Message queuing that works
RabbitMQ: Message queuing that works
 
Rethink programming: a functional approach
Rethink programming: a functional approachRethink programming: a functional approach
Rethink programming: a functional approach
 
Erlang and Elixir
Erlang and ElixirErlang and Elixir
Erlang and Elixir
 

Semelhante a in-memory capacity planning, Erlang Factory London 09

PHP Mega Meetup, Sep, 2020, Anti patterns in php
PHP Mega Meetup, Sep, 2020, Anti patterns in phpPHP Mega Meetup, Sep, 2020, Anti patterns in php
PHP Mega Meetup, Sep, 2020, Anti patterns in phpAhmed Abdou
 
Yeahhhh the final requirement!!!
Yeahhhh the final requirement!!!Yeahhhh the final requirement!!!
Yeahhhh the final requirement!!!olracoatalub
 
Margareth lota
Margareth lotaMargareth lota
Margareth lotamaggybells
 
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...Arnauld Loyer
 
Fundamentals of programming final santos
Fundamentals of programming final santosFundamentals of programming final santos
Fundamentals of programming final santosAbie Santos
 
Fundamentals of programming final
Fundamentals of programming finalFundamentals of programming final
Fundamentals of programming finalRicky Recto
 
Deguzmanpresentationprogramming
DeguzmanpresentationprogrammingDeguzmanpresentationprogramming
Deguzmanpresentationprogrammingdeguzmantrisha
 
SiestaTime - Defcon27 Red Team Village
SiestaTime - Defcon27 Red Team VillageSiestaTime - Defcon27 Red Team Village
SiestaTime - Defcon27 Red Team VillageAlvaro Folgado Rueda
 
Mark asoi ppt
Mark asoi pptMark asoi ppt
Mark asoi pptmark-asoi
 
Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...
Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...
Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...OW2
 
You got ur Erlang in my Ruby
You got ur Erlang in my RubyYou got ur Erlang in my Ruby
You got ur Erlang in my Rubyelliando dias
 
The Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingThe Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingJuan J. Merelo
 
Singularity Registry HPC
Singularity Registry HPCSingularity Registry HPC
Singularity Registry HPCVanessa S
 
Fundamentalsofprogrammingfinal 121011003536-phpapp02
Fundamentalsofprogrammingfinal 121011003536-phpapp02Fundamentalsofprogrammingfinal 121011003536-phpapp02
Fundamentalsofprogrammingfinal 121011003536-phpapp02thinesonsing
 
Cs121 Unit Test
Cs121 Unit TestCs121 Unit Test
Cs121 Unit TestJill Bell
 
From a web application to a distributed system
From a web application to a distributed systemFrom a web application to a distributed system
From a web application to a distributed systemGianluca Padovani
 
Apache Flex and the imperfect Web
Apache Flex and the imperfect WebApache Flex and the imperfect Web
Apache Flex and the imperfect Webmasuland
 
Automated Testing
Automated TestingAutomated Testing
Automated TestingSpeed FC
 
XOOPS 2.5.x Debugging with FirePHP/FireBug
XOOPS 2.5.x Debugging with FirePHP/FireBugXOOPS 2.5.x Debugging with FirePHP/FireBug
XOOPS 2.5.x Debugging with FirePHP/FireBugxoopsproject
 
Kubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad Assis
Kubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad AssisKubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad Assis
Kubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad AssisAgileSparks
 

Semelhante a in-memory capacity planning, Erlang Factory London 09 (20)

PHP Mega Meetup, Sep, 2020, Anti patterns in php
PHP Mega Meetup, Sep, 2020, Anti patterns in phpPHP Mega Meetup, Sep, 2020, Anti patterns in php
PHP Mega Meetup, Sep, 2020, Anti patterns in php
 
Yeahhhh the final requirement!!!
Yeahhhh the final requirement!!!Yeahhhh the final requirement!!!
Yeahhhh the final requirement!!!
 
Margareth lota
Margareth lotaMargareth lota
Margareth lota
 
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
Dégraissons le mammouth ou Darwin a encore frappé - La théorie de l'évolution...
 
Fundamentals of programming final santos
Fundamentals of programming final santosFundamentals of programming final santos
Fundamentals of programming final santos
 
Fundamentals of programming final
Fundamentals of programming finalFundamentals of programming final
Fundamentals of programming final
 
Deguzmanpresentationprogramming
DeguzmanpresentationprogrammingDeguzmanpresentationprogramming
Deguzmanpresentationprogramming
 
SiestaTime - Defcon27 Red Team Village
SiestaTime - Defcon27 Red Team VillageSiestaTime - Defcon27 Red Team Village
SiestaTime - Defcon27 Red Team Village
 
Mark asoi ppt
Mark asoi pptMark asoi ppt
Mark asoi ppt
 
Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...
Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...
Guidance, Code and Education: ScalaCenter and the Scala Community, Heather Mi...
 
You got ur Erlang in my Ruby
You got ur Erlang in my RubyYou got ur Erlang in my Ruby
You got ur Erlang in my Ruby
 
The Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingThe Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms Programming
 
Singularity Registry HPC
Singularity Registry HPCSingularity Registry HPC
Singularity Registry HPC
 
Fundamentalsofprogrammingfinal 121011003536-phpapp02
Fundamentalsofprogrammingfinal 121011003536-phpapp02Fundamentalsofprogrammingfinal 121011003536-phpapp02
Fundamentalsofprogrammingfinal 121011003536-phpapp02
 
Cs121 Unit Test
Cs121 Unit TestCs121 Unit Test
Cs121 Unit Test
 
From a web application to a distributed system
From a web application to a distributed systemFrom a web application to a distributed system
From a web application to a distributed system
 
Apache Flex and the imperfect Web
Apache Flex and the imperfect WebApache Flex and the imperfect Web
Apache Flex and the imperfect Web
 
Automated Testing
Automated TestingAutomated Testing
Automated Testing
 
XOOPS 2.5.x Debugging with FirePHP/FireBug
XOOPS 2.5.x Debugging with FirePHP/FireBugXOOPS 2.5.x Debugging with FirePHP/FireBug
XOOPS 2.5.x Debugging with FirePHP/FireBug
 
Kubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad Assis
Kubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad AssisKubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad Assis
Kubernetes is Hard! Lessons Learned Taking Our Apps to Kubernetes by Eldad Assis
 

Último

Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPathCommunity
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkPixlogix Infotech
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfpanagenda
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesBernd Ruecker
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical InfrastructureVarsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructureitnewsafrica
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Nikki Chapple
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024TopCSSGallery
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 

Último (20)

Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to Hero
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App Framework
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architectures
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical InfrastructureVarsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 

in-memory capacity planning, Erlang Factory London 09

  • 1. erlang at hover.in Bhasker V Kode co­founder  & CTO at hover.in at Erlang Factory, London June 26, 2009     http://developers.hover.in
  • 2. brief introduction to hover.in choose words from your blog, & decide what content / ad  you want when you hover* over it * or other events like click,right click,etc or... the worlds first publisher driven  in­text content & ad delivery platform... or lets web publishers push client­side event handling to the  cloud, to run various rich applications called hoverlets demo at http://start.hover.in/ and  http://hover.in/demo more at http://hover.in ,  http://developers.hover.in/blog/      http://developers.hover.in
  • 4. hover.in founded late 2007     http://developers.hover.in
  • 5. hover.in founded late 2007  ➔ the web ~ 10­ 20 years old      http://developers.hover.in
  • 6. hover.in founded late 2007  ➔ the web ~ 10­ 20 years old  ➔ humans 100's of thousands of years      http://developers.hover.in
  • 7. hover.in founded late 2007  ➔ the web ~ 10­ 20 years old  ➔ humans 100's of thousands of years  ➔ but bacteria.... around for millions of years ... so this talk is going to be about what we can  learn from bacteria, the brain, and memory in  a concurrent world followed by hover.in's erlang    setup and lessons learnt  http://developers.hover.in
  • 9. should_we_glow(Ctr, Max, Acc)­> receive  {in,Cell}­>     One_or_zero  = should_i_glow(Cell),    case Ctr of       Max ­> done;      _ ­>        case Acc of          ?SOME_VAL ­>               glow_for_8_hours(), done;         _ ­>         NewAcc = One_or_zero + Acc,         should_we_glow(Ctr+1,Max,NewAcc)        end;   _ ­> error     end http://developers.hover.in
  • 10. some traits of bacteria ● each bacteria cell spawns its own proteins ● All bacteria have some sort of  some presence  & replies associated, (asynchronous comm.) ● group dynamics exhibits 'list fold' ish operation ● only when the Accumulator is > some guard  clause, will group­dynamics of making light  (bioluminiscence) work (eg: in deep sea)     http://developers.hover.in
  • 11. spawning, in practice ● for a single google search result, the same  requests are sent to multiple machines( ~1000  as of 09), which ever replies the quickest wins.  ● in amazon's dynamo architecture that powers  S3, use a (3,2,2) rule . ie Maintain 3 copies of  the same data, reads/writes are succesful only  when 2 concurrent requests succeed. This ratio  varies based on SLA, internal vs public service.  ( more on conflict resolution... )     http://developers.hover.in
  • 12. pattern matching behaviour ● each molecule connects to its specific receptor  protein to complete the missing piece,to trigger  the group behaviour that are only succesful  when all of the cells participate in unison. ● Type = case UserType of                    user ­> true;                  admin ­> true;                  _Else  ­> false              end   http://developers.hover.in
  • 13. supervisors, workers ● as bacteria grow, they split into two. when  muscle tears, it knows exactly what to replace. ● erlang supervisors can decide restart policies: if  one worker fails, restart all .... or if one worker  fails, restart just that worker, more tweaks. ● can spawn multiple workers on the fly, much  like the need for launching a new ec2 instant     http://developers.hover.in
  • 14. inter­species communication ● if you look at your skin – consists of very many  different species, but all bacteria found to  communicate using one common chemical  language.      http://developers.hover.in
  • 15. inter­species communication ● if you look at your skin – consists of very many  different species, but all bacteria found to  communicate using one common chemical  language.  hmmmmmmmmmmmmmmmmmmm.............. ....serialization ?! ....a common protein interpretor ?! ....or perhaps just­in­time protein compilation?!     http://developers.hover.in
  • 16. interspecies comm. in practice ➔ attempts at serialization , cross language  communication include: ➔ thrift ( by facebook)  ➔ protocol buffers ( by google)  ➔ en/decoding , port based communication ( erlang<­ >python at hover.in ) ➔ rabbitMQ shows speeds of several thousands of   msgs/sec between python <­> erlang (by using...?)     http://developers.hover.in
  • 17. talking about scaling The brain of the worker honeybee weighs about  1mg ( ~ 950,000 neurons ) ● Flies acrobatically , recognizes patterns,  navigates , communicates, etc ● Energy consumption: 10−15 J/op, at least 106  more efficient than digital silicon neurons      http://developers.hover.in
  • 18. the human brain ● 100 billion neurons, stores ~100 TB ● Differential analysis e.g., we compute color ● Multiple inputs: sight, sound, taste, smell, touch ● Facial recognition subcircuits, peripheral vision ● in essence  ­ the left & right brain vary in: left ­> persistent disk , handles past/future right ­> temporal caches! , handles present     http://developers.hover.in
  • 19. in­memory is the new embedded ● servers as of '09 typically have 4 ­ 16 GB RAM  ● stats of how companies are adding nodes     http://developers.hover.in
  • 20. in­memory is the new embedded ● caching systems avoid disk/db makes sense ● caching systems for processing tasks makes  sense ● but .... ● keeping your entire data in­memory by having N  number of nodes ?      http://developers.hover.in
  • 21. in­memory is the new embedded ● keeping your entire data in­memory by having N  number of nodes ,  ( where N = total data in gb /  max ram per node ) is like ... – building a billion dollar company with 999 milion  dollars of funding! or  – having only a right brain ! ● surely we can do better than that!     http://developers.hover.in
  • 22. in­memory capacity planning ● No matter how many machines you have, and  how many cores, in production level – your  product could be defined by how well you   design your in­memory / RAM strategies. ● alternatives to avoid swapping could be – just  leaving results partioned on diff nodes, or  additional tasks to reduce the data­load further  until they can fit in memory     http://developers.hover.in
  • 23. in­memory capacity planning ● parallizing jobs in­memory is a lot of fun... ● but... ● more often bottleneck will not be how well you  can paralliize, but how much you need to  parallize so that memory does'nt swap (eg: || db  reads)     http://developers.hover.in
  • 24. (1)#1 shard thy data to make it sufficiently un­related ● typical web backends – all user data in one  table – then clustering just splits that on artibary  basis. eg: query user table where id=user1,  ● what if you have N concurrent process's  accessing N diff user tables – no locks, you can  ||'ze & results can come back asynchronously  since sufficiently un­related.  ● Warning: but more atoms  ( list_to_atom atoms      aren't garbage collected ) http://developers.hover.in
  • 25. (1)#2 implementing flowcontrol ● great to handle both bursts or silent traffic & to  determine bottlenecks.(eg ur own,rabbitmq,etc ) ● eg1: when we addjobs to the queue, if it takes  greater than X consistently we move it to high  traffic bracket, do things differently, possibly  add workers  or ignore based on the task. ● eg2: amazon shopping carts, are known to be  extra resilient to write failures, (dont mind    multiple versions of them over time) http://developers.hover.in  
  • 26. (1)#3 all data is important, but some less important ● priority queue used to built heat­seeking algo  ( priority to crawl webpages that get more hits  rather than depth­first or breadth­first)  ● can configure max number of buckets ● can configure max number of urls per bucket ● can configure pyramid like queue. ( moving  from lower buckets to higher is easier than    moving from high to higher )    http://developers.hover.in
  • 27. erlang in a crawler architecture ? ● each time a hit occurs for a url, it moves from bucket N  to bucket N+1     http://developers.hover.in
  • 28. erlang in a crawler architecture ? ● each time a hit repeats for a URL , it moves from  bucket N to bucket N+1 ● crawls happen from top down (priority queue)     http://developers.hover.in
  • 29. erlang in a crawler architecture ? ● each time a hit repeats for a URL , it moves from  bucket N to bucket N+1 ● crawls happen from top down (priority queue) ● so the bucket is locked, so that locked urls dont keep  move up anymore     http://developers.hover.in
  • 30. erlang in a crawler architecture ? ● each time a hit repeats for a URL , it moves from  bucket N to bucket N+1 ● crawls happen from top down (priority queue) ● so the bucket is locked, so that locked urls dont keep  move up anymore ● each user/site has their own priority queues, which  keep shifting round­robin after every X urls crawled  per user/site     http://developers.hover.in
  • 31. erlang in a crawler architecture ? ● each time a hit repeats for a URL , it moves from  bucket N to bucket N+1 ● crawls happen from top down (priority queue) ● so the bucket is locked, so that locked urls dont keep  move up anymore ● each user/site has their own priority queues, which  keep shifting round­robin after every X urls crawled  per user/site ● python crawler leaves text files which dirty loaded into    fragmented mnesia   http://developers.hover.in
  • 32. (1)#3 time spent x RAM utilization = a constant (2)          eg: of || db reads (3) (4)#4 before every succesful persistent write & after  every succesful persistent read is an in­memory one (5)        eg: hi_cache_worker's used to build (6)              most recent queue's      http://developers.hover.in
  • 33. (1)#5 before every succesful persistent write & after  every succesful persistent read is an in­memory one ● you listen to a phone number in batch's of 3 or 4  digits. the part that absorbs just before writing  (temporal), until you write into your contact book  or memorize it ( persistent) ● eg: if LRU cache exists in­memory, like 100  most recent url's or tags, then no need to parse  server logs for computation, try during writes  itself . No logs, no files. live buzz analytics!     http://developers.hover.in
  • 34. (1)#6  know thy RAM, trial/error to find ideal dataload ● eg: || db reads  if || happens so fast, mem probs ● replication vs location transparency, are they  fragmented, are some nodes read­only ? (rpc...) ● need metadata for which node to acess for user1,  (or use hashing fn like memcache) ● are tables in­memory (right brain ), cached from  disk , or on disk alone ( left brain )    ● fortunately mnesia allows highly granular choices   http://developers.hover.in
  • 35. (1)#7 what cannot be measured cannot be improved ● you can't improve what you can't measure. an  investment in debugging utilities is a good  investment ● looking forward to debugging with dtrace,gproc  etc but until then – just a set/get away! ● using tsung (written in erlang again ) – load  performance testing tool, for simulating 100's of  concurrent users/requests , and great for  analysing bottlenecks of your system ,CDN's ) ,      http://developers.hover.in
  • 36. hi_cache_worker ● a circular queue implemented via gen_server ● set ( ID  , Key , Value , OptionsList) Options are     {purge, <true| false>}                         { size , <integer> }                         { set_callback , <Function> }                         { delete_callback , <Function> }                         { get_callback , <Function> }                         { timeout, <int>, <Function> }   ID is usually a siteid  or  “global”   http://developers.hover.in
  • 37. C = hi_cache_worker, C:set ( User1, “recent_saved” , Value)  C:set ( “global”, “recent_hits” , Value                                     [{size,1000}] )  C:get (“global”,”recent_voted”) C:get (User1,”recenthits”) C:get (User1,”recent_cron_times”) ● ( Note: initially used in debugging internally ­>    then reporting ­> next in public community stats)   http://developers.hover.in
  • 38. 7 rules of in­memory capacity planning (1) shard thy data to make it sufficiently un­related (2) implementing flowcontrol (3) all data is important, but some less important (4) time spent x RAM utilization = a constant (5) before every succesful persistent write & after  every succesful persistent read is an in­memory one (6) know thy RAM, trial/error to find ideal dataload   (7) what cannot be measured cannot be improved   http://developers.hover.in
  • 39. summary of erlang at hover.in ● LYME stack since ~dec 07 ,  3 nodes (64­bit 4gb ) ● python crawler, associated NLP parsers, cpu time­ splicing algo's for cron's app, configurable priority  queue's for heat­seeking algo's app,  flowcontrol  app , caching app , pagination app for memoizing ● remote node debugger, cyclic queue workers, lru  cache workers , headless­firefox for thumbnails  ● touched 1 million hovers/month in May'09 after  launching closed beta to publishers in Jan 09     http://developers.hover.in
  • 40. summary of our erlang modules rewrites.erl error.erl frag_mnesia.erl hi_api_response.erl   hi_appmods_api_user.erl    hi_cache_app.erl , hi_cache_sup.erl   hoverlingo.erl hi_cache_worker.erl  hi_lru_worker.erl  hi_classes.erl  hi_community.erl  hi_cron_hoverletupdater_app.erl  hi_cron_hoverletupdater.erl  hi_cron_hoverletupdater_sup.erl  hi_cron_kwebucket.erl  hi_crypto.erl  hi_flowcontrol_hoverletupdater.erl hi_htmlutils_site.erl hi_hybridq_app.erl  hi_hybridq_sup.erl hi_hybridq_worker.erl hi_login.erl hi_mailer.erl  hi_messaging_app.erl hi_messaging_sup.erl hi_messaging_worker.erl  hi_mgr_crawler.erl hi_mgr_db_console.erl hi_mgr_db.erl hi_mgr_db_mnesia.erl  hi_mgr_hoverlet.erl hi_mgr_kw.erl hi_mgr_node.erl hi_mgr_thumbs.erl  hi_mgr_traffic.erl hi_nlp.erl hi_normalizer.erl hi_pagination_app.erl    hi_pagination_sup.erl, hi_pagination_worker.erl hi_pmap.erl  hi_register_app.erl  hi_register.erl, hi_register_sup.erl, hi_register_worker.erl  hi_render_hoverlet_worker.erl hi_rrd.erl , hi_rrd_worker.erl hi_settings.erl     hi_sid.erl hi_site.erl hi_stat.erl hi_stats_distribution.erl hi_stats_overview.erl    hi_str.erl hi_trees.erl hi_utf8.erl hi_yaws.erl    http://developers.hover.in
  • 41. references ● http://developers.hover.in ● http://erlang.org  ● http://memcached.org , http://rabbitmq.org/ http://highscalability.com/  ● http://www.allthingsdistributed.com/files/amazon­dynamo­sosp2007.pdf ● shoutout to everyone at #erlang !  ● amazing brain­related talks at   http://ted.com , ●  go read more about the brain and hack on  erlang NOW!     http://developers.hover.in
  • 42. thank you     http://developers.hover.in