SlideShare a Scribd company logo
1 of 33
Evolving IGN’s new APIs with
            Scala



                  Manish Pandit
                  Oct 4th, 2012
About me


             Manish Pandit
      Director of Engineering, IGN
             @lobster1234
       linkedin.com/in/mpandit
About IGN
We are a leading online media and services company
obsessed with gaming and entertainment.

56MM Monthly Unique Views
737MM Monthly Page Views
20MM Monthly Video Views
My Objective
Is:
To get you excited about building APIs in Scala

Isn't:
To incite a functional vs. imperative, or Scala vs.
____ debate
Agenda
•   APIs at IGN
•   API Evolution
•   Why Scala
•   API Development with Scala
•   Monitoring, Maintaining, Evolving
•   Performance Management
APIs at IGN
• Offer SOA advantages
• Isolate the back end systems from the FE
• IGN is going where the audience is, fast
  – Mobile Devices, Consoles, TVs, Aggregators
• APIs are a specialized skillset
• Expand the development to outside
  developers
APIs at IGN : Numbers
• ~5 Billion requests a month
• Average Response time of under 20ms on
  cache misses
• 17 APIs between Social, OAuth, and Content
• Hardest hit APIs doing about 25K RPM at peak
Evolution
The API Evolution : V1 [2006]
• The CMS and the desktop site calling Java
  Services, which wrapped Oracle DB calls
  behind Hibernate.
• Caching with Memcache
  – Near-far Cache Architecture to address hot spots
• Not all content types were supported
• Schema was still too complex
The API Evolution : V2 [2009]
• Rails based Content API, Java based Social API
  –   Standards around request/response
  –   Automated Testing
  –   MongoDB NoSQL storage to simplify the schema
  –   Solr
• Video and Blogs served by V2 API
• Games and Articles still used V1
• Mixed-infrastructure with Rails and Java
  echosystem
• Performance sucked royally
The API Evolution : V3 [2012]
• A fresh look at the APIs and IGN’s direction
• First attempt to
  – Integrate all content types
  – Open up the APIs to external consumers
  – Evolve the CMS, traditionally a monolithic system
  – ElasticSearch
  – Varnish Response Caching
• A learning opportunity for traditional Java
  stack engineers
API Development
• MVC Model for APIs
  – View, which marshals/unmarshals request and
    response data
  – Controller, which picks the right model to serve
    the request
  – Model, which has the necessary logic to talk to the
    database, or other APIs to fetch data
Why Scala
• Performance tied to cores than processor
  speed, i.e. concurrency
• Ideal for API development – (relatively) simple
  to handle concurrency and immutability
• JVM based = Performance
• Re-use Java toolkits and libraries
• Concise, expressive code (1:2.5 with Java)
• Actor model makes the difficult parts easy
Why Scala
•   Richer Collections API
•   Traits enabling Mix-Ins and behavior re-use
•   Statically Typed w/Type inference
•   Functional
•   Growing developer community
•   REPL
•   Culture – learning, hacking and achieving
The Biggest Reason
• Just makes sense
The Biggest Reason
• Just makes sense
  – Pattern matching
  – Implicit conversions
  – Control abstractions for collection mapping,
    filtering, iterating
  – Guaranteed Singletons at the classloader level
  – Almost non-existent boilerplate
  ….Productive, and fun!
Picking up Scala : Week 1
• Scala for Java Developers fast-tracked the
  learning
• Syntax Familiarity
• Java without semicolons?
     def total(nums: List[Int]) :Int = {
       var sum:Int=0
       for(num<-nums) {
         sum+=num
       }
       sum
     }
Picking up Scala : Week 4
• Reduce the lines of code, embrace
  immutability, use the functional paradigms
  built into the language
• Unmystrify the implicits magic
    nums.foldLeft(0)((n,c) => n+c)
Picking up Scala : Today
• Focus on immutability
• Think functional – with the knowledge gained
  from using the functional aspects of the
  language, build control abstractions
• Keep learning and applying
API Components
•   Scalatra (View, Controller)
•   Lift-MongoRecord for MongoDB (Model)
•   Casbah for MongoDB
•   Play! Anorm for MySQL
•   Actors for tasks like syndication
•   Maven for Builds
•   MongoDB for persistance
Other API Components
•   Varnish Cache
•   Elasticsearch
•   Yammer Metrics (ping, healthcheck)
•   Swagger (self-documenting RESTful APIs)
•   3Scale for Partner APIs
•   IntelliJ IDEA and Eclipse with ScalaIDE
Challenges with Scala
• Learning Curve depends on the culture
  • TPS Cover Sheets, vs. Hack Nights


• Scala is what you make of it
Awesome..?




http://scalaz.github.com/scalaz/scalaz-2.9.1-6.0.4/doc.sxr/scalaz/BKTree.scala.html
Challenges with Scala
• Scala is what you make of it
  – Middle ground – simple is beautiful
• Tooling not as rich as Java
  – Changing with Typesafe investing in ScalaIDE
Challenges with Scala
• Slow compilation based on the source
  – How well the code matches up to the JVM
    constructs
• No (binary) compatibility of dependencies for
  the major releases (2.8, 2.9, 2.10(?))
• Monitoring
  – No native instrumentation agents as they exist for
    Java
API Development : Deploying
• Continuous Deployment
  • Jenkins hooks to github
  • Pushes artifact(s) to Nexus
  • Fabric to push code to production (to be
    automated)
API Performance Management
• As far as Scala goes, the tips are not much
  different than Java
  – GC Tuning
  – Avoid shared state
  – Parallel collections
API Performance Management
• For the overall APIs, the performance tuning has
  many knobs to work around with
  – Stateless services
  – Async calls with Akka Agents
  – Response level cache
• Keep an eye on the database and network
  –   Control the payload size
  –   Use reasonable defaults
  –   Allow field filtering
  –   Paginate your response
Monitoring and Maintenance
• Newrelic
  – JVM stats, SQL trace
  – Supports Scala via annotations, but not as rich as
    Java
• Typesafe Console for Akka
Future of APIs at IGN
• Opening up the APIs
• Tests, tests, tests..
• Move towards simplifying the stack
  – sbt vs. maven
  – Typesafe stack
The IGN Tech Stack
Resources
• Do NOT use scaladoc as your 1st reference, at
  least initially
• StackOverflow
• Twitter’s Scala School
• Online blogs and tutorials
• Book: Scala for the Impatient
• Scala Meetup Groups in your area
• Coursera course on FP by Martin Odersky
Questions

More Related Content

What's hot

Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3Wen-Tien Chang
 
Scala for java developers 6 may 2017 - yeni
Scala for java developers   6 may 2017 - yeniScala for java developers   6 may 2017 - yeni
Scala for java developers 6 may 2017 - yeniBaris Dere
 
Sbt, idea and eclipse
Sbt, idea and eclipseSbt, idea and eclipse
Sbt, idea and eclipseMike Slinn
 
The Need For Speed - NxtGen Cambridge
The Need For Speed - NxtGen CambridgeThe Need For Speed - NxtGen Cambridge
The Need For Speed - NxtGen CambridgePhil Pursglove
 
Build and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API GatewayBuild and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API GatewayAmazon Web Services
 
From java to scala at crowd mix
From java to scala at crowd mixFrom java to scala at crowd mix
From java to scala at crowd mixStefano Galarraga
 
React.js for Rails Developers
React.js for Rails DevelopersReact.js for Rails Developers
React.js for Rails DevelopersArkency
 
Migration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET CoreMigration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET CoreMiroslav Popovic
 
Scala in the Enterprise
Scala in the EnterpriseScala in the Enterprise
Scala in the EnterpriseEric Pederson
 
Java SE 7 New Features and Enhancements
Java SE 7 New Features and EnhancementsJava SE 7 New Features and Enhancements
Java SE 7 New Features and EnhancementsFu Cheng
 
Data normalization across API interactions
Data normalization across API interactionsData normalization across API interactions
Data normalization across API interactionsCloud Elements
 
Building serverless app_using_aws_lambda_b4usolution
Building serverless app_using_aws_lambda_b4usolutionBuilding serverless app_using_aws_lambda_b4usolution
Building serverless app_using_aws_lambda_b4usolutionHoa Le
 
Designing your API Server for mobile apps
Designing your API Server for mobile appsDesigning your API Server for mobile apps
Designing your API Server for mobile appsMugunth Kumar
 
React on rails v6.1 at LA Ruby, November 2016
React on rails v6.1 at LA Ruby, November 2016React on rails v6.1 at LA Ruby, November 2016
React on rails v6.1 at LA Ruby, November 2016Justin Gordon
 
Lecture #5 Introduction to rails
Lecture #5 Introduction to railsLecture #5 Introduction to rails
Lecture #5 Introduction to railsEvgeniy Hinyuk
 
Introduction to Rails by Evgeniy Hinyuk
Introduction to Rails by Evgeniy HinyukIntroduction to Rails by Evgeniy Hinyuk
Introduction to Rails by Evgeniy HinyukPivorak MeetUp
 

What's hot (20)

Apereo OAE - Bootcamp
Apereo OAE - BootcampApereo OAE - Bootcamp
Apereo OAE - Bootcamp
 
Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3
 
Scala for java developers 6 may 2017 - yeni
Scala for java developers   6 may 2017 - yeniScala for java developers   6 may 2017 - yeni
Scala for java developers 6 may 2017 - yeni
 
Full stack
Full stackFull stack
Full stack
 
Sbt, idea and eclipse
Sbt, idea and eclipseSbt, idea and eclipse
Sbt, idea and eclipse
 
The Need For Speed - NxtGen Cambridge
The Need For Speed - NxtGen CambridgeThe Need For Speed - NxtGen Cambridge
The Need For Speed - NxtGen Cambridge
 
Build and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API GatewayBuild and Manage Your APIs with Amazon API Gateway
Build and Manage Your APIs with Amazon API Gateway
 
From java to scala at crowd mix
From java to scala at crowd mixFrom java to scala at crowd mix
From java to scala at crowd mix
 
React.js for Rails Developers
React.js for Rails DevelopersReact.js for Rails Developers
React.js for Rails Developers
 
JIRA5 Introduction
JIRA5 IntroductionJIRA5 Introduction
JIRA5 Introduction
 
Laravel 4 presentation
Laravel 4 presentationLaravel 4 presentation
Laravel 4 presentation
 
Migration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET CoreMigration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET Core
 
Scala in the Enterprise
Scala in the EnterpriseScala in the Enterprise
Scala in the Enterprise
 
Java SE 7 New Features and Enhancements
Java SE 7 New Features and EnhancementsJava SE 7 New Features and Enhancements
Java SE 7 New Features and Enhancements
 
Data normalization across API interactions
Data normalization across API interactionsData normalization across API interactions
Data normalization across API interactions
 
Building serverless app_using_aws_lambda_b4usolution
Building serverless app_using_aws_lambda_b4usolutionBuilding serverless app_using_aws_lambda_b4usolution
Building serverless app_using_aws_lambda_b4usolution
 
Designing your API Server for mobile apps
Designing your API Server for mobile appsDesigning your API Server for mobile apps
Designing your API Server for mobile apps
 
React on rails v6.1 at LA Ruby, November 2016
React on rails v6.1 at LA Ruby, November 2016React on rails v6.1 at LA Ruby, November 2016
React on rails v6.1 at LA Ruby, November 2016
 
Lecture #5 Introduction to rails
Lecture #5 Introduction to railsLecture #5 Introduction to rails
Lecture #5 Introduction to rails
 
Introduction to Rails by Evgeniy Hinyuk
Introduction to Rails by Evgeniy HinyukIntroduction to Rails by Evgeniy Hinyuk
Introduction to Rails by Evgeniy Hinyuk
 

Viewers also liked

Knowwi Intro 2010
Knowwi Intro 2010Knowwi Intro 2010
Knowwi Intro 2010marklaszlo
 
Onlinetools&amp;Job Search2010
Onlinetools&amp;Job Search2010Onlinetools&amp;Job Search2010
Onlinetools&amp;Job Search2010Cindy Edwards
 
Dossier robotica Albert Claveria
Dossier robotica Albert ClaveriaDossier robotica Albert Claveria
Dossier robotica Albert Claveriaalbert
 
Funcionlinealyafin
FuncionlinealyafinFuncionlinealyafin
FuncionlinealyafinRodolfo A
 
南東京I phone勉強会(stidev) 20101030
南東京I phone勉強会(stidev) 20101030南東京I phone勉強会(stidev) 20101030
南東京I phone勉強会(stidev) 20101030Kaz Watanabe
 
Hummingbird Banding in Paridise, AZ
Hummingbird  Banding  in Paridise, AZHummingbird  Banding  in Paridise, AZ
Hummingbird Banding in Paridise, AZtdainsure
 
ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12
ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12
ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12Christos Gotzaridis
 
Object Oriented Programming
Object Oriented ProgrammingObject Oriented Programming
Object Oriented ProgrammingManish Pandit
 
Pp Kee Dome Web
Pp Kee Dome WebPp Kee Dome Web
Pp Kee Dome WebKee Safety
 
Mapping an all-weather Tour de France
Mapping an all-weather Tour de FranceMapping an all-weather Tour de France
Mapping an all-weather Tour de Francedbyhundred
 
αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...
αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...
αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...Christos Gotzaridis
 
Ppt Presentations Best Methods
Ppt Presentations Best MethodsPpt Presentations Best Methods
Ppt Presentations Best MethodsFlagler College
 
Osig Annual Report 2008
Osig Annual Report 2008Osig Annual Report 2008
Osig Annual Report 2008ryangood2009
 
RiciCreo sistema per la raccolta differenziata con dinamica di gamification
RiciCreo sistema per la raccolta differenziata con dinamica di gamificationRiciCreo sistema per la raccolta differenziata con dinamica di gamification
RiciCreo sistema per la raccolta differenziata con dinamica di gamificationMichele Pierangeli
 
Music Video Powerpoint
Music Video PowerpointMusic Video Powerpoint
Music Video PowerpointHayleyMoore
 

Viewers also liked (20)

Knowwi Intro 2010
Knowwi Intro 2010Knowwi Intro 2010
Knowwi Intro 2010
 
Onlinetools&amp;Job Search2010
Onlinetools&amp;Job Search2010Onlinetools&amp;Job Search2010
Onlinetools&amp;Job Search2010
 
Dossier robotica Albert Claveria
Dossier robotica Albert ClaveriaDossier robotica Albert Claveria
Dossier robotica Albert Claveria
 
Funcionlinealyafin
FuncionlinealyafinFuncionlinealyafin
Funcionlinealyafin
 
南東京I phone勉強会(stidev) 20101030
南東京I phone勉強会(stidev) 20101030南東京I phone勉強会(stidev) 20101030
南東京I phone勉強会(stidev) 20101030
 
Hummingbird Banding in Paridise, AZ
Hummingbird  Banding  in Paridise, AZHummingbird  Banding  in Paridise, AZ
Hummingbird Banding in Paridise, AZ
 
ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12
ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12
ΟΔΗΓΙΕΣ ΔΙΔΑΣΚΑΛΙΑΣ ΤΗΣ ΒΙΟΛΟΓΙΑΣ Α ΛΥΚΕΙΟΥ 2011-12
 
Object Oriented Programming
Object Oriented ProgrammingObject Oriented Programming
Object Oriented Programming
 
Pp Kee Dome Web
Pp Kee Dome WebPp Kee Dome Web
Pp Kee Dome Web
 
Mapping an all-weather Tour de France
Mapping an all-weather Tour de FranceMapping an all-weather Tour de France
Mapping an all-weather Tour de France
 
Crash
CrashCrash
Crash
 
Small Group Makeup Workshops in Tauranga
Small Group Makeup Workshops in TaurangaSmall Group Makeup Workshops in Tauranga
Small Group Makeup Workshops in Tauranga
 
αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...
αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...
αρχαια ολυμπιακα αγωνισματα & σχολικη φυσικη μια διαθεματικη προταση για το λ...
 
Ppt Presentations Best Methods
Ppt Presentations Best MethodsPpt Presentations Best Methods
Ppt Presentations Best Methods
 
Osig Annual Report 2008
Osig Annual Report 2008Osig Annual Report 2008
Osig Annual Report 2008
 
RiciCreo sistema per la raccolta differenziata con dinamica di gamification
RiciCreo sistema per la raccolta differenziata con dinamica di gamificationRiciCreo sistema per la raccolta differenziata con dinamica di gamification
RiciCreo sistema per la raccolta differenziata con dinamica di gamification
 
Music Video Powerpoint
Music Video PowerpointMusic Video Powerpoint
Music Video Powerpoint
 
Nuestros Valores
Nuestros ValoresNuestros Valores
Nuestros Valores
 
Sacchetti Di Plastica
Sacchetti Di PlasticaSacchetti Di Plastica
Sacchetti Di Plastica
 
Reflecting On Research Outcomes - Ricardo's Presentation
Reflecting On Research Outcomes - Ricardo's PresentationReflecting On Research Outcomes - Ricardo's Presentation
Reflecting On Research Outcomes - Ricardo's Presentation
 

Similar to Evolving IGN’s New APIs with Scala

Whitepages Practical Experience Converting from Ruby to Reactive
Whitepages Practical Experience Converting from Ruby to ReactiveWhitepages Practical Experience Converting from Ruby to Reactive
Whitepages Practical Experience Converting from Ruby to ReactiveDragos Manolescu
 
Emulators as an Emerging Best Practice for API providers
Emulators as an Emerging Best Practice for API providersEmulators as an Emerging Best Practice for API providers
Emulators as an Emerging Best Practice for API providersPostman
 
IncQuery Server for Teamwork Cloud - Talk at IW2019
IncQuery Server for Teamwork Cloud - Talk at IW2019IncQuery Server for Teamwork Cloud - Talk at IW2019
IncQuery Server for Teamwork Cloud - Talk at IW2019Istvan Rath
 
Scala and Spark are Ideal for Big Data
Scala and Spark are Ideal for Big DataScala and Spark are Ideal for Big Data
Scala and Spark are Ideal for Big DataJohn Nestor
 
Experience Converting from Ruby to Scala
Experience Converting from Ruby to ScalaExperience Converting from Ruby to Scala
Experience Converting from Ruby to ScalaJohn Nestor
 
Transitioning from Java to Scala for Spark - March 13, 2019
Transitioning from Java to Scala for Spark - March 13, 2019Transitioning from Java to Scala for Spark - March 13, 2019
Transitioning from Java to Scala for Spark - March 13, 2019Gravy Analytics
 
Scala and Spark are Ideal for Big Data - Data Science Pop-up Seattle
Scala and Spark are Ideal for Big Data - Data Science Pop-up SeattleScala and Spark are Ideal for Big Data - Data Science Pop-up Seattle
Scala and Spark are Ideal for Big Data - Data Science Pop-up SeattleDomino Data Lab
 
A look ahead at RAP (ESE 2010)
A look ahead at RAP (ESE 2010)A look ahead at RAP (ESE 2010)
A look ahead at RAP (ESE 2010)Ralf Sternberg
 
Google Developer Days Brazil 2009 - Java Appengine
Google Developer Days Brazil 2009 -  Java AppengineGoogle Developer Days Brazil 2009 -  Java Appengine
Google Developer Days Brazil 2009 - Java AppenginePatrick Chanezon
 
Apache Spark MLlib 2.0 Preview: Data Science and Production
Apache Spark MLlib 2.0 Preview: Data Science and ProductionApache Spark MLlib 2.0 Preview: Data Science and Production
Apache Spark MLlib 2.0 Preview: Data Science and ProductionDatabricks
 
Scala in practice
Scala in practiceScala in practice
Scala in practiceTomer Gabel
 
Polyglot Plugin Programming
Polyglot Plugin ProgrammingPolyglot Plugin Programming
Polyglot Plugin ProgrammingAtlassian
 
Ohio Devfest - Visual Analysis with GCP
Ohio Devfest - Visual Analysis with GCPOhio Devfest - Visual Analysis with GCP
Ohio Devfest - Visual Analysis with GCPWesley Workman
 
Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...IncQuery Labs
 
Resume
ResumeResume
ResumeMina k
 

Similar to Evolving IGN’s New APIs with Scala (20)

Whitepages Practical Experience Converting from Ruby to Reactive
Whitepages Practical Experience Converting from Ruby to ReactiveWhitepages Practical Experience Converting from Ruby to Reactive
Whitepages Practical Experience Converting from Ruby to Reactive
 
Emulators as an Emerging Best Practice for API providers
Emulators as an Emerging Best Practice for API providersEmulators as an Emerging Best Practice for API providers
Emulators as an Emerging Best Practice for API providers
 
IncQuery Server for Teamwork Cloud - Talk at IW2019
IncQuery Server for Teamwork Cloud - Talk at IW2019IncQuery Server for Teamwork Cloud - Talk at IW2019
IncQuery Server for Teamwork Cloud - Talk at IW2019
 
Scala and Spark are Ideal for Big Data
Scala and Spark are Ideal for Big DataScala and Spark are Ideal for Big Data
Scala and Spark are Ideal for Big Data
 
Experience Converting from Ruby to Scala
Experience Converting from Ruby to ScalaExperience Converting from Ruby to Scala
Experience Converting from Ruby to Scala
 
Transitioning from Java to Scala for Spark - March 13, 2019
Transitioning from Java to Scala for Spark - March 13, 2019Transitioning from Java to Scala for Spark - March 13, 2019
Transitioning from Java to Scala for Spark - March 13, 2019
 
Introduction to Scala
Introduction to ScalaIntroduction to Scala
Introduction to Scala
 
Scala and Spark are Ideal for Big Data - Data Science Pop-up Seattle
Scala and Spark are Ideal for Big Data - Data Science Pop-up SeattleScala and Spark are Ideal for Big Data - Data Science Pop-up Seattle
Scala and Spark are Ideal for Big Data - Data Science Pop-up Seattle
 
Frontend as a first class citizen
Frontend as a first class citizenFrontend as a first class citizen
Frontend as a first class citizen
 
Apache Drill (ver. 0.2)
Apache Drill (ver. 0.2)Apache Drill (ver. 0.2)
Apache Drill (ver. 0.2)
 
A look ahead at RAP (ESE 2010)
A look ahead at RAP (ESE 2010)A look ahead at RAP (ESE 2010)
A look ahead at RAP (ESE 2010)
 
Google Developer Days Brazil 2009 - Java Appengine
Google Developer Days Brazil 2009 -  Java AppengineGoogle Developer Days Brazil 2009 -  Java Appengine
Google Developer Days Brazil 2009 - Java Appengine
 
Apache Spark MLlib 2.0 Preview: Data Science and Production
Apache Spark MLlib 2.0 Preview: Data Science and ProductionApache Spark MLlib 2.0 Preview: Data Science and Production
Apache Spark MLlib 2.0 Preview: Data Science and Production
 
Scala in practice
Scala in practiceScala in practice
Scala in practice
 
Polyglot Plugin Programming
Polyglot Plugin ProgrammingPolyglot Plugin Programming
Polyglot Plugin Programming
 
Varun-CV-J
Varun-CV-JVarun-CV-J
Varun-CV-J
 
Ohio Devfest - Visual Analysis with GCP
Ohio Devfest - Visual Analysis with GCPOhio Devfest - Visual Analysis with GCP
Ohio Devfest - Visual Analysis with GCP
 
Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...
 
Resume
ResumeResume
Resume
 
IGN's V3 API
IGN's V3 APIIGN's V3 API
IGN's V3 API
 

More from Manish Pandit

Disaster recovery - What, Why, and How
Disaster recovery - What, Why, and HowDisaster recovery - What, Why, and How
Disaster recovery - What, Why, and HowManish Pandit
 
Serverless Architectures on AWS in practice - OSCON 2018
Serverless Architectures on AWS in practice - OSCON 2018Serverless Architectures on AWS in practice - OSCON 2018
Serverless Architectures on AWS in practice - OSCON 2018Manish Pandit
 
Disaster Recovery and Reliability
Disaster Recovery and ReliabilityDisaster Recovery and Reliability
Disaster Recovery and ReliabilityManish Pandit
 
Immutable AWS Deployments with Packer and Jenkins
Immutable AWS Deployments with Packer and JenkinsImmutable AWS Deployments with Packer and Jenkins
Immutable AWS Deployments with Packer and JenkinsManish Pandit
 
AWS Lambda with Serverless Framework and Java
AWS Lambda with Serverless Framework and JavaAWS Lambda with Serverless Framework and Java
AWS Lambda with Serverless Framework and JavaManish Pandit
 
AWS Primer and Quickstart
AWS Primer and QuickstartAWS Primer and Quickstart
AWS Primer and QuickstartManish Pandit
 
Securing your APIs with OAuth, OpenID, and OpenID Connect
Securing your APIs with OAuth, OpenID, and OpenID ConnectSecuring your APIs with OAuth, OpenID, and OpenID Connect
Securing your APIs with OAuth, OpenID, and OpenID ConnectManish Pandit
 
Silicon Valley 2014 - API Antipatterns
Silicon Valley 2014 - API AntipatternsSilicon Valley 2014 - API Antipatterns
Silicon Valley 2014 - API AntipatternsManish Pandit
 
Scalabay - API Design Antipatterns
Scalabay - API Design AntipatternsScalabay - API Design Antipatterns
Scalabay - API Design AntipatternsManish Pandit
 
OSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at Netflix
OSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at NetflixOSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at Netflix
OSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at NetflixManish Pandit
 
API Design Antipatterns - APICon SF
API Design Antipatterns - APICon SFAPI Design Antipatterns - APICon SF
API Design Antipatterns - APICon SFManish Pandit
 
Motivation : it Matters
Motivation : it MattersMotivation : it Matters
Motivation : it MattersManish Pandit
 
Building Apis in Scala with Playframework2
Building Apis in Scala with Playframework2Building Apis in Scala with Playframework2
Building Apis in Scala with Playframework2Manish Pandit
 
Silicon Valley Code Camp 2011: Play! as you REST
Silicon Valley Code Camp 2011: Play! as you RESTSilicon Valley Code Camp 2011: Play! as you REST
Silicon Valley Code Camp 2011: Play! as you RESTManish Pandit
 
Silicon Valley Code Camp: 2011 Introduction to MongoDB
Silicon Valley Code Camp: 2011 Introduction to MongoDBSilicon Valley Code Camp: 2011 Introduction to MongoDB
Silicon Valley Code Camp: 2011 Introduction to MongoDBManish Pandit
 
NoSQLCamp : MongoDB at IGN
NoSQLCamp : MongoDB at IGNNoSQLCamp : MongoDB at IGN
NoSQLCamp : MongoDB at IGNManish Pandit
 
MongoSF 2011 - Using MongoDB for IGN's Social Platform
MongoSF 2011 - Using MongoDB for IGN's Social PlatformMongoSF 2011 - Using MongoDB for IGN's Social Platform
MongoSF 2011 - Using MongoDB for IGN's Social PlatformManish Pandit
 

More from Manish Pandit (20)

Disaster recovery - What, Why, and How
Disaster recovery - What, Why, and HowDisaster recovery - What, Why, and How
Disaster recovery - What, Why, and How
 
Serverless Architectures on AWS in practice - OSCON 2018
Serverless Architectures on AWS in practice - OSCON 2018Serverless Architectures on AWS in practice - OSCON 2018
Serverless Architectures on AWS in practice - OSCON 2018
 
Disaster Recovery and Reliability
Disaster Recovery and ReliabilityDisaster Recovery and Reliability
Disaster Recovery and Reliability
 
OAuth2 primer
OAuth2 primerOAuth2 primer
OAuth2 primer
 
Immutable AWS Deployments with Packer and Jenkins
Immutable AWS Deployments with Packer and JenkinsImmutable AWS Deployments with Packer and Jenkins
Immutable AWS Deployments with Packer and Jenkins
 
AWS Lambda with Serverless Framework and Java
AWS Lambda with Serverless Framework and JavaAWS Lambda with Serverless Framework and Java
AWS Lambda with Serverless Framework and Java
 
AWS Primer and Quickstart
AWS Primer and QuickstartAWS Primer and Quickstart
AWS Primer and Quickstart
 
Securing your APIs with OAuth, OpenID, and OpenID Connect
Securing your APIs with OAuth, OpenID, and OpenID ConnectSecuring your APIs with OAuth, OpenID, and OpenID Connect
Securing your APIs with OAuth, OpenID, and OpenID Connect
 
Silicon Valley 2014 - API Antipatterns
Silicon Valley 2014 - API AntipatternsSilicon Valley 2014 - API Antipatterns
Silicon Valley 2014 - API Antipatterns
 
Scalabay - API Design Antipatterns
Scalabay - API Design AntipatternsScalabay - API Design Antipatterns
Scalabay - API Design Antipatterns
 
OSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at Netflix
OSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at NetflixOSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at Netflix
OSCON 2014 - API Ecosystem with Scala, Scalatra, and Swagger at Netflix
 
API Design Antipatterns - APICon SF
API Design Antipatterns - APICon SFAPI Design Antipatterns - APICon SF
API Design Antipatterns - APICon SF
 
Motivation : it Matters
Motivation : it MattersMotivation : it Matters
Motivation : it Matters
 
Building Apis in Scala with Playframework2
Building Apis in Scala with Playframework2Building Apis in Scala with Playframework2
Building Apis in Scala with Playframework2
 
Scala at Netflix
Scala at NetflixScala at Netflix
Scala at Netflix
 
Java and the JVM
Java and the JVMJava and the JVM
Java and the JVM
 
Silicon Valley Code Camp 2011: Play! as you REST
Silicon Valley Code Camp 2011: Play! as you RESTSilicon Valley Code Camp 2011: Play! as you REST
Silicon Valley Code Camp 2011: Play! as you REST
 
Silicon Valley Code Camp: 2011 Introduction to MongoDB
Silicon Valley Code Camp: 2011 Introduction to MongoDBSilicon Valley Code Camp: 2011 Introduction to MongoDB
Silicon Valley Code Camp: 2011 Introduction to MongoDB
 
NoSQLCamp : MongoDB at IGN
NoSQLCamp : MongoDB at IGNNoSQLCamp : MongoDB at IGN
NoSQLCamp : MongoDB at IGN
 
MongoSF 2011 - Using MongoDB for IGN's Social Platform
MongoSF 2011 - Using MongoDB for IGN's Social PlatformMongoSF 2011 - Using MongoDB for IGN's Social Platform
MongoSF 2011 - Using MongoDB for IGN's Social Platform
 

Recently uploaded

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 

Recently uploaded (20)

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 

Evolving IGN’s New APIs with Scala

  • 1. Evolving IGN’s new APIs with Scala Manish Pandit Oct 4th, 2012
  • 2. About me Manish Pandit Director of Engineering, IGN @lobster1234 linkedin.com/in/mpandit
  • 3. About IGN We are a leading online media and services company obsessed with gaming and entertainment. 56MM Monthly Unique Views 737MM Monthly Page Views 20MM Monthly Video Views
  • 4. My Objective Is: To get you excited about building APIs in Scala Isn't: To incite a functional vs. imperative, or Scala vs. ____ debate
  • 5. Agenda • APIs at IGN • API Evolution • Why Scala • API Development with Scala • Monitoring, Maintaining, Evolving • Performance Management
  • 6. APIs at IGN • Offer SOA advantages • Isolate the back end systems from the FE • IGN is going where the audience is, fast – Mobile Devices, Consoles, TVs, Aggregators • APIs are a specialized skillset • Expand the development to outside developers
  • 7. APIs at IGN : Numbers • ~5 Billion requests a month • Average Response time of under 20ms on cache misses • 17 APIs between Social, OAuth, and Content • Hardest hit APIs doing about 25K RPM at peak
  • 9. The API Evolution : V1 [2006] • The CMS and the desktop site calling Java Services, which wrapped Oracle DB calls behind Hibernate. • Caching with Memcache – Near-far Cache Architecture to address hot spots • Not all content types were supported • Schema was still too complex
  • 10. The API Evolution : V2 [2009] • Rails based Content API, Java based Social API – Standards around request/response – Automated Testing – MongoDB NoSQL storage to simplify the schema – Solr • Video and Blogs served by V2 API • Games and Articles still used V1 • Mixed-infrastructure with Rails and Java echosystem • Performance sucked royally
  • 11. The API Evolution : V3 [2012] • A fresh look at the APIs and IGN’s direction • First attempt to – Integrate all content types – Open up the APIs to external consumers – Evolve the CMS, traditionally a monolithic system – ElasticSearch – Varnish Response Caching • A learning opportunity for traditional Java stack engineers
  • 12. API Development • MVC Model for APIs – View, which marshals/unmarshals request and response data – Controller, which picks the right model to serve the request – Model, which has the necessary logic to talk to the database, or other APIs to fetch data
  • 13. Why Scala • Performance tied to cores than processor speed, i.e. concurrency • Ideal for API development – (relatively) simple to handle concurrency and immutability • JVM based = Performance • Re-use Java toolkits and libraries • Concise, expressive code (1:2.5 with Java) • Actor model makes the difficult parts easy
  • 14. Why Scala • Richer Collections API • Traits enabling Mix-Ins and behavior re-use • Statically Typed w/Type inference • Functional • Growing developer community • REPL • Culture – learning, hacking and achieving
  • 15. The Biggest Reason • Just makes sense
  • 16. The Biggest Reason • Just makes sense – Pattern matching – Implicit conversions – Control abstractions for collection mapping, filtering, iterating – Guaranteed Singletons at the classloader level – Almost non-existent boilerplate ….Productive, and fun!
  • 17. Picking up Scala : Week 1 • Scala for Java Developers fast-tracked the learning • Syntax Familiarity • Java without semicolons? def total(nums: List[Int]) :Int = { var sum:Int=0 for(num<-nums) { sum+=num } sum }
  • 18. Picking up Scala : Week 4 • Reduce the lines of code, embrace immutability, use the functional paradigms built into the language • Unmystrify the implicits magic nums.foldLeft(0)((n,c) => n+c)
  • 19. Picking up Scala : Today • Focus on immutability • Think functional – with the knowledge gained from using the functional aspects of the language, build control abstractions • Keep learning and applying
  • 20. API Components • Scalatra (View, Controller) • Lift-MongoRecord for MongoDB (Model) • Casbah for MongoDB • Play! Anorm for MySQL • Actors for tasks like syndication • Maven for Builds • MongoDB for persistance
  • 21. Other API Components • Varnish Cache • Elasticsearch • Yammer Metrics (ping, healthcheck) • Swagger (self-documenting RESTful APIs) • 3Scale for Partner APIs • IntelliJ IDEA and Eclipse with ScalaIDE
  • 22. Challenges with Scala • Learning Curve depends on the culture • TPS Cover Sheets, vs. Hack Nights • Scala is what you make of it
  • 24. Challenges with Scala • Scala is what you make of it – Middle ground – simple is beautiful • Tooling not as rich as Java – Changing with Typesafe investing in ScalaIDE
  • 25. Challenges with Scala • Slow compilation based on the source – How well the code matches up to the JVM constructs • No (binary) compatibility of dependencies for the major releases (2.8, 2.9, 2.10(?)) • Monitoring – No native instrumentation agents as they exist for Java
  • 26. API Development : Deploying • Continuous Deployment • Jenkins hooks to github • Pushes artifact(s) to Nexus • Fabric to push code to production (to be automated)
  • 27. API Performance Management • As far as Scala goes, the tips are not much different than Java – GC Tuning – Avoid shared state – Parallel collections
  • 28. API Performance Management • For the overall APIs, the performance tuning has many knobs to work around with – Stateless services – Async calls with Akka Agents – Response level cache • Keep an eye on the database and network – Control the payload size – Use reasonable defaults – Allow field filtering – Paginate your response
  • 29. Monitoring and Maintenance • Newrelic – JVM stats, SQL trace – Supports Scala via annotations, but not as rich as Java • Typesafe Console for Akka
  • 30. Future of APIs at IGN • Opening up the APIs • Tests, tests, tests.. • Move towards simplifying the stack – sbt vs. maven – Typesafe stack
  • 31. The IGN Tech Stack
  • 32. Resources • Do NOT use scaladoc as your 1st reference, at least initially • StackOverflow • Twitter’s Scala School • Online blogs and tutorials • Book: Scala for the Impatient • Scala Meetup Groups in your area • Coursera course on FP by Martin Odersky