NetflixOSS Open House Lightning talks
Upcoming SlideShare
Loading in...5
×
 

NetflixOSS Open House Lightning talks

on

  • 62,671 views

NetflixOSS Open House Lightning talks

NetflixOSS Open House Lightning talks

Statistics

Views

Total Views
62,671
Views on SlideShare
2,841
Embed Views
59,830

Actions

Likes
4
Downloads
57
Comments
0

34 Embeds 59,830

http://techblog.netflix.com 58655
http://www-ig-opensocial.googleusercontent.com 808
http://www.newsblur.com 101
http://newsblur.com 63
https://twitter.com 61
http://unvalidness5.zulti.com 30
http://www.directrss.co.il 12
http://725338818844296080_86788a26a62229952c1eead78e94eb109098d662.blogspot.com 11
http://irq.tumblr.com 10
http://localhost 9
http://www.feedspot.com 8
http://apps.synaptive.net 7
http://www.nathanntg.com 6
http://webcache.googleusercontent.com 6
http://feedly.com 5
http://translate.googleusercontent.com 5
http://www.hanrss.com 4
http://dev.newsblur.com 4
http://127.0.0.1 3
http://1kpl.us 3
http://68.166.223.4 3
http://smashingreader.com 2
http://cafe.naver.com 2
http://digg.com 2
http://cloud.feedly.com 1
http://xianguo.com 1
http://embedded.dreamwidth.net 1
http://newsvi.be 1
http://www.feedly.com 1
http://www.verious.com 1
http://mail.tedparton.com 1
http://printwhatyoulike.com 1
http://www.diffbot.com&_=1360712379258 HTTP 1
http://techblognetflix.downloadwindows8.me 1
More...

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

NetflixOSS Open House Lightning talks NetflixOSS Open House Lightning talks Presentation Transcript

  • NetflixOSS Open House Lightning talks
  • Jordan Zimmerman @randgalt jzimmerman@netflix.comNetflixOSS projects I work on Jordan Zimmerman Netflix Platform Team jzimmerman@netflix.com @randgalt
  • Correct ZooKeeper use is hard!● Curator is a set of Java libraries that make using ZooKeeper much easier and enforce best practices.● Curator is focused on the recipes: locks, leaders, etc. Most people interested in ZooKeeper dont need to be concerned with the details of connection management, etc. What they want is a simple way to use the recipes.● Connection management, retries, recipes, best practices.● Recipes! Leader Latch, Leader Election, Shared Reentrant Lock, Shared Lock, Shared Reentrant Read Write Lock, Shared Semaphore, Multi Shared Lock, Distributed Queue, Distributed Id Queue, Distributed Priority Queue, Distributed Delay Queue, Simple Distributed Queue, Barrier, Double Barrier, Shared counter, Distributed Atomic Long, Path Cache, Node Cache View slide
  • ZooKeeper Ops is very hard!● Instance Monitoring● Log Cleanup● Backup/Restore● Cluster-wide Configuration● Rolling Ensemble Changes● Automatic Instance Management● Visualizer● ZooKeeper Data Mutation● Curator Integration● Rich REST API View slide
  • A library of extensions and utilities that enhance Google Guice to provide:● Classpath scanning and automatic binding● Lifecycle management● Configuration to field mapping● Field validation● Parallelized object warmup● Lazy singleton● Fine grained, more concurrent singleton● Generic binding annotations
  • BLITZ4j● At Netflix ● Billions of log lines per day ● BI reporting, Monitoring, Debugging ● Log4j for several years● What we faced? ● Traffic increased – per instance logging increased ● Contentions in logging ● Impact in application response time ● Deadlocks during reconfiguration● What is wrong with Log4j? ● Strict locking model ● Synchronization semantics everywhere ● Impacting application response for logging a few lines?● What is Blitz4j? ● Seamlessly replace all contention points ● Decouple logging and application ● Asynchronous appender – optimized, configurable ● Dynamic configurability● How can your application benefit? ● Does your application use log4j and logs heavily? ● Immediate performance boost ● Include blitz4j in classpath and couple of lines of configuration
  • EUREKA● REST service ● Primarily useful in the AWS cloud ● Find other middle-tier services in the cloud ● Service -farm of instances providing functionality ● identified by well known name● Why discover other services? ● Services find other services to interact - midde tier ● In AWS cloud, this communication can be tricky ● Instances come and go, ASG scales up/down ● Interacting services should be aware of this ● ELB can track this – but exposes internet traffic ● DNS can discover services – but cannot maintain automatically ● Eureka tracks this information and relays to all communicating services● What does Eureka provide? ● Finding instances for middle-tier communication and loadbalancing ● Other management activities - take instances in/out of live traffic ● Share application-specific metadata between services ● Built-in Resilience to network partitions, zone failures,eureka peer outages VMore about Eureka and Blitz4j - Visit us at the booth
  • RibbonInter-process communication library with software load balancers andclient ● Cornerstone of Netflix Internal Web Services (NIWS), a Service Oriented Architecture ● Multiple built-in load balancing schemes ○ round robin, response time weighted, circuit breaker enabled ● Cloud ready ○ Integration with Eureka to provide dynamic server pools in AWS ○ AWS specific features - zone affinity, zone avoidance, connection priming ● Highly configurable JSR 311 based REST Client ● Coming soon ○ Annotation based provider for easy serialization/deserialization and cache support ○ SLA measurement for clients ○ Response cache for REST client ○ Asynchronous/batch operation for REST client
  • ArchaiusArchaius is a dynamic configuration library● Enable configuration change at runtime without restarting● Framework to poll configuration source or listen to external property related events● Supports configuration sources from generic URLs, JDBC, Amazon DynamoDB, ZooKeeper and jCloud● Central place to organize properties into "buckets" by their nature and priorities● Coming soon ○ Service that manage properties with multiple dimensions ○ Property Management UI ○ Property validation and change notification
  • Astyanax /əˈstaɪ.ənæks/● Cassandra Java Client Library - Higher level fluent API● Connection Pool ○ Bag, Round Robin, Token Aware, Rack aware ○ Connection Priming ○ Failover + Retry ○ Latency optimization● Optimized for running in the cloud ○ Node discovery ○ Monitoring ○ Metrics● Recipes - Common Cassandra Data Models ○ Entity Mapping ○ Message Queue (w/ Quartz like scheduling) ○ All rows reader with checkpoints ○ Distributed lock ○ Large object store
  • Priam - Jason Brown (@jasobrown) - Coprocess for running cassandra in ec2 - backup & recovery - configuration - token management (*)
  • Cassandra virtual nodes- new feature in c* 1.2 - multiple, non-contiguous shards per instance- simplifies operations for growing / shrinking c * cluster
  • CassJMeter- plugin for Apache JMeter- load testing cassandra- swappable clients - astyanax - hector - fat client
  • Edda● REST Webservice● Crawls Amazons AWS APIs ○ Stores results as versioned JSON docs● Dynamic Querying$ curl "http://edda/api/v2/view/instances;publicIpAddress=1.2.3.4"["i-012345678b"]● View History (resources that no longer exist)$ curl "http://edda/api/v2/view/instances;publicIpAddress=1.2.3.4;_since=0"["i-0123456789","i-012345678a","i-012345678b"]● View Changes (diff over time of a resource)
  • Founder of the Netflix Simian Army
  • The Netflix Simian Army• Chaos Monkey • Circus Monkey• Chaos Gorilla • Doctor Monkey• Latency Monkey • Howler Monkey• Janitor Monkey • Security Monkey• Conformity Monkey • Chaos Kong • Efficiency Monkey
  • 3099.99% = 99.7% uptime
  • TurbineMetrics Stream Aggregator Puneet Oberai API Platform
  • ● Low latency streaming infrastructure● Pluggable Cloud Instance Discovery ● Config based (Use Archaius) ● File system ● Eureka Plugin● Data agnostic
  • Rx JavaFunctional Reactive Programming
  • What do these ops have in common?● Query for all videos that a Netflix member has rated >= 4● Drag and Drop event
  • Theyre both queries.
  • Two Design Patterns Iterator Observer● next() ● update(item)● hasNext() ● ???● throw ex ● ???
  • Two Design Patterns Iterator Observer● next() ● onNext(item)● hasNext() ● onCompleted()● throw ex ● onError(ex)
  • Example: Videos with Rating >= 4.0Iterable<Video> videosWithHighRating = netflixMember.getVideoLists(). map({ Iterable<Video> videoList -> return videoList. filter({ Video video -> video.getRating() >= 4.0 }); }). merge();
  • Example: Drag EventObservable<MouseEvent> mouseDowns = // convert a legacy ObservableObservable<MouseEvent> mouseMoves = // ...Observable<MouseEvent> mouseUps = // ...Observable<MouseEvent> mouseDrags = mouseDowns. map({ MouseEvent mouseDownEvent -> return mouseMoves. takeUntil(mouseUps); }). merge();
  • Spin Locks Dead Locks Threads Observable 1. mapSemaphores 2. filter 3. merge 4. reduceRace Conditions 5. zip
  • @AsgardOSS