SlideShare a Scribd company logo
1 of 34
//Building scalable web sites with tight game integration
Johan Mjönes & Joakim Bodin
What is battlelog?

   › Battlefield 10 year anniversary soon
   › Battlelog becoming the community hangout
   › Integrate game launching for PC players
Features

   › Friend-centric
   › Easy communication
   › Current stats and history
   › Activity log
   › PC Menu
   › News / Forums
ESN PLANET
ESN PLANET OVERVIEW
Languages

  › Developing Battlelog means developing in Python, Java, C++
  › The Battlelog Web is written primarily using Python
  › Plugin, game components in C++
  › Python allows for rapid web development (e.g. remote access console)
Partitioning

       Horizontal (sharding)                  Vertical

               Battlelog                      Battlelog




         1-7     7-14       ...            User           Lab Feature
                                  ...
                                     ...
           User DBs
                                             Different processes
      (slices and shards)
Persistence & Index

   › MySQL
       › No joins
       › Used as indexed KVS
   ›   Apache Solr
       › Full text search for forums
       › Other uses in the future
       › Fast!
Server to client push

   › Uses ESN Beaconpush
   › Allows delivery of messages from web server to client browser.
   › Uses long polling or websockets (or flash)
   › AV / anti-malware software + push =
     › Blocks all websockets
     › Injects Javascript into the DOM
     › Etc...
Caching with Memcached

   › Great framework support
    › Service methods cached via annotations



    › Invalidation using method signature instead of key

    › Allows populating cache directly after modification
    › Dog pile prevention
EA Services

   › Nucleus
    › Users
        › No user info in Battlelog DB! Success!
    ›   Personas
        › Soldiers
    ›   Entitlements
        › Licenses
   › Blaze
    › Game Servers reports to Blaze
    › Events to Battlelog
        › Game Server information
        › Asynchronous responses (e.g. matchmaking)
    ›   REST
        › Stats
Nucleus Details




            Web                              Nucleus
                                    HTTP
           Soldiers   Web Backend           Accounts

           Licenses                        Entitlements
Game Servers

Blaze Details                                                               Blaze

   › Uses Web Access Layer (WAL)                                             DB
                                                      Blaze
   › WAL client generated from TDF
       › TDF is a API definition language
   ›   Blaze events (XML over HTTP)
                                                    Events        WAL

                                        Thrift
                 Web Frontend                      Web Backend




                     AJAX                                Real-time Events
                                     Web Browser
Friends

   › Started out normalized
   › Unmanagable amount of rows
   › Ended up as one blob per user
       › Packed user ids
   ›   A lot easier to cache properly
Server Browser

   › Custom search server (Java)
   › Custom query language, minimal message overhead
   › Fast update, fast search
Joining a game
Joining a game: plugin details




             Web Browser

                                    Pipe   Game Client
                           Plugin
      Game UI      JS
Battle Reports

   › Game report from Blaze (HTTP XML event)
   › Parse and divide per player
       › One report per player via internal message queue
       › Look for unlocks, rankups, medals, awards etc
         › Add to feed, send real time updates
       › Invalidate player stats caches
   ›   Compile Battlereport (& pre-cache it)
   ›   Send notification to involved (logged in) users
Background

  › Load tested using Locust
      › Open Source (MIT License)
      › https://github.com/cgbystrom/locust
      › Built by ESN (& others)
  ›   Battlelog tested with 2.7 million PSU with 36 million players
      › That’s 40,000 requests per second
      › The tests was successful
Pre-pass

   › Planet dev bar
       › Timing
       › Queries
   ›   No point in load testing if there are apparent issues with a
       single user
Realistic load testing

   › Some testing tools simply hammer certain URLs
   › Locust allows for realistic usage scenarios
       › Many players go away for 20 minutes while playing, receiving notifications
       › Updated tests using actual usage data from alpha trial / open beta
   ›   Coordinated testing
       › Same user spans
   ›   Overpopulate tables to simulate fragmented MySQL
       indices
What did we find?

   › Bugs
   › Bottlenecks
       › Never assume where your bottlenecks are
       › Test to find out
   ›   Network related
       › Saturated network, not CPU
       › Keep the traffic within the rack!
   ›   Software related
       › Best practices be damned, cheat if neccessary
       › Lazy loading data in controllers
       › Client side rendering
         ›   Surface + History API + JSON =
Being a part of the pipeline

   › Data driven games
   › Battlelog has its own pipeline
     › Written in Python
     › Imports data from the game pipeline
         › Weapons, vehicles, levels, dog tags, etc
         › Assets include images, text, data
     ›   Resolving unlocks and dependencies
     ›   Generates python structs and javascript structs
         › Generates many helper maps. Some might only be used once.
     ›   DLC friendly!
     ›   Result of many iterations
User Interface
   › Separate UI from consoles / in game menu
     › Having the same wouldn’t make sense, different UX
     › Adapt to different devices
   › Web features
     › Easily accessible, e.g. Sharing
     › Extendability with browser extensions, user styles etc
     › Access on any platform (play on console, have Battlelog on iPad)
   › Easy to iterate over UI changes
Battlelog will evolve

   › Agile: Easy to update
   › Big things:
       › DLC
       › Public APIs
       › Other things we can’t talk about
   ›   Small things
       › Improvements based on community feedback
Johan Mjönes   The Battlelog team is hiring!
  @nollbit
                 http://dice.se/hiring.asp
Joakim Bodin     jobs@dice.se
  @jbripley
                 Technical Director
                 Development Director
                 Backend
                 Frontend

More Related Content

What's hot

Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)
Tiago Sousa
 
A Bit More Deferred Cry Engine3
A Bit More Deferred   Cry Engine3A Bit More Deferred   Cry Engine3
A Bit More Deferred Cry Engine3
guest11b095
 
Windows to reality getting the most out of direct3 d 10 graphics in your games
Windows to reality   getting the most out of direct3 d 10 graphics in your gamesWindows to reality   getting the most out of direct3 d 10 graphics in your games
Windows to reality getting the most out of direct3 d 10 graphics in your games
changehee lee
 

What's hot (20)

Advancements in-tiled-rendering
Advancements in-tiled-renderingAdvancements in-tiled-rendering
Advancements in-tiled-rendering
 
SPU-Based Deferred Shading in BATTLEFIELD 3 for Playstation 3
SPU-Based Deferred Shading in BATTLEFIELD 3 for Playstation 3SPU-Based Deferred Shading in BATTLEFIELD 3 for Playstation 3
SPU-Based Deferred Shading in BATTLEFIELD 3 for Playstation 3
 
Shiny PC Graphics in Battlefield 3
Shiny PC Graphics in Battlefield 3Shiny PC Graphics in Battlefield 3
Shiny PC Graphics in Battlefield 3
 
Siggraph2016 - The Devil is in the Details: idTech 666
Siggraph2016 - The Devil is in the Details: idTech 666Siggraph2016 - The Devil is in the Details: idTech 666
Siggraph2016 - The Devil is in the Details: idTech 666
 
Rendering Battlefield 4 with Mantle
Rendering Battlefield 4 with MantleRendering Battlefield 4 with Mantle
Rendering Battlefield 4 with Mantle
 
Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)
 
A Bit More Deferred Cry Engine3
A Bit More Deferred   Cry Engine3A Bit More Deferred   Cry Engine3
A Bit More Deferred Cry Engine3
 
Destruction Masking in Frostbite 2 using Volume Distance Fields
Destruction Masking in Frostbite 2 using Volume Distance FieldsDestruction Masking in Frostbite 2 using Volume Distance Fields
Destruction Masking in Frostbite 2 using Volume Distance Fields
 
D2 Hdr
D2 HdrD2 Hdr
D2 Hdr
 
Future Directions for Compute-for-Graphics
Future Directions for Compute-for-GraphicsFuture Directions for Compute-for-Graphics
Future Directions for Compute-for-Graphics
 
Dissecting the Rendering of The Surge
Dissecting the Rendering of The SurgeDissecting the Rendering of The Surge
Dissecting the Rendering of The Surge
 
A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...
A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...
A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...
 
DRAW: Deep Recurrent Attentive Writer
DRAW: Deep Recurrent Attentive WriterDRAW: Deep Recurrent Attentive Writer
DRAW: Deep Recurrent Attentive Writer
 
Lighting you up in Battlefield 3
Lighting you up in Battlefield 3Lighting you up in Battlefield 3
Lighting you up in Battlefield 3
 
A Real-time Radiosity Architecture
A Real-time Radiosity ArchitectureA Real-time Radiosity Architecture
A Real-time Radiosity Architecture
 
Physically Based Sky, Atmosphere and Cloud Rendering in Frostbite
Physically Based Sky, Atmosphere and Cloud Rendering in FrostbitePhysically Based Sky, Atmosphere and Cloud Rendering in Frostbite
Physically Based Sky, Atmosphere and Cloud Rendering in Frostbite
 
Compute shader DX11
Compute shader DX11Compute shader DX11
Compute shader DX11
 
Volumetric Lighting for Many Lights in Lords of the Fallen
Volumetric Lighting for Many Lights in Lords of the FallenVolumetric Lighting for Many Lights in Lords of the Fallen
Volumetric Lighting for Many Lights in Lords of the Fallen
 
Windows to reality getting the most out of direct3 d 10 graphics in your games
Windows to reality   getting the most out of direct3 d 10 graphics in your gamesWindows to reality   getting the most out of direct3 d 10 graphics in your games
Windows to reality getting the most out of direct3 d 10 graphics in your games
 
Rendering Techniques in Rise of the Tomb Raider
Rendering Techniques in Rise of the Tomb RaiderRendering Techniques in Rise of the Tomb Raider
Rendering Techniques in Rise of the Tomb Raider
 

Viewers also liked

Viewers also liked (8)

Building the Battlefield AI Experience
Building the Battlefield AI ExperienceBuilding the Battlefield AI Experience
Building the Battlefield AI Experience
 
5 Major Challenges in Interactive Rendering
5 Major Challenges in Interactive Rendering5 Major Challenges in Interactive Rendering
5 Major Challenges in Interactive Rendering
 
How data rules the world: Telemetry in Battlefield Heroes
How data rules the world: Telemetry in Battlefield HeroesHow data rules the world: Telemetry in Battlefield Heroes
How data rules the world: Telemetry in Battlefield Heroes
 
A Step Towards Data Orientation
A Step Towards Data OrientationA Step Towards Data Orientation
A Step Towards Data Orientation
 
Shadows & Decals: D3D10 Techniques in Frostbite (GDC'09)
 	 Shadows & Decals: D3D10 Techniques in Frostbite (GDC'09) 	 Shadows & Decals: D3D10 Techniques in Frostbite (GDC'09)
Shadows & Decals: D3D10 Techniques in Frostbite (GDC'09)
 
Stable SSAO in Battlefield 3 with Selective Temporal Filtering
Stable SSAO in Battlefield 3 with Selective Temporal FilteringStable SSAO in Battlefield 3 with Selective Temporal Filtering
Stable SSAO in Battlefield 3 with Selective Temporal Filtering
 
Introduction to Data Oriented Design
Introduction to Data Oriented DesignIntroduction to Data Oriented Design
Introduction to Data Oriented Design
 
Level Design Challenges & Solutions - Mirror's Edge
Level Design Challenges & Solutions - Mirror's EdgeLevel Design Challenges & Solutions - Mirror's Edge
Level Design Challenges & Solutions - Mirror's Edge
 

Similar to Battlelog - Building scalable web sites with tight game integration

Firefox3.5 And Next
Firefox3.5 And NextFirefox3.5 And Next
Firefox3.5 And Next
Channy Yun
 
Dynamics NAV, Windows Azure & Windows Phone 7, Eric Wauters
Dynamics NAV, Windows Azure & Windows Phone 7, Eric WautersDynamics NAV, Windows Azure & Windows Phone 7, Eric Wauters
Dynamics NAV, Windows Azure & Windows Phone 7, Eric Wauters
dynamicscom
 
Aditya - Hacking Client Side Insecurities - ClubHack2008
Aditya - Hacking Client Side Insecurities - ClubHack2008Aditya - Hacking Client Side Insecurities - ClubHack2008
Aditya - Hacking Client Side Insecurities - ClubHack2008
ClubHack
 
iPhone Development For Experienced Web Developers
iPhone Development For Experienced Web DevelopersiPhone Development For Experienced Web Developers
iPhone Development For Experienced Web Developers
lisab517
 
Haiku OS Presentation
Haiku OS PresentationHaiku OS Presentation
Haiku OS Presentation
laawrence
 
Sriram simplify os_sdevelopment
Sriram simplify os_sdevelopmentSriram simplify os_sdevelopment
Sriram simplify os_sdevelopment
suniltomar04
 
Sriram simplify os_sdevelopment
Sriram simplify os_sdevelopmentSriram simplify os_sdevelopment
Sriram simplify os_sdevelopment
OpenSourceIndia
 

Similar to Battlelog - Building scalable web sites with tight game integration (20)

Firefox3.5 And Next
Firefox3.5 And NextFirefox3.5 And Next
Firefox3.5 And Next
 
OSC11 - The future is now for all your Business Processes
OSC11 - The future is now for all your Business ProcessesOSC11 - The future is now for all your Business Processes
OSC11 - The future is now for all your Business Processes
 
iOS Architecture and MVC
iOS Architecture and MVCiOS Architecture and MVC
iOS Architecture and MVC
 
OSP303 SharePoint 2010 – Planning High Availability for SharePoint 2010 Farms
OSP303 SharePoint 2010 – Planning High Availability for SharePoint 2010 FarmsOSP303 SharePoint 2010 – Planning High Availability for SharePoint 2010 Farms
OSP303 SharePoint 2010 – Planning High Availability for SharePoint 2010 Farms
 
A short introduction to the cloud
A short introduction to the cloudA short introduction to the cloud
A short introduction to the cloud
 
Dynamics NAV, Windows Azure & Windows Phone 7, Eric Wauters
Dynamics NAV, Windows Azure & Windows Phone 7, Eric WautersDynamics NAV, Windows Azure & Windows Phone 7, Eric Wauters
Dynamics NAV, Windows Azure & Windows Phone 7, Eric Wauters
 
Android
AndroidAndroid
Android
 
(GAM402) Deploying a Low-Latency Multiplayer Game Globally: Loadout | AWS re:...
(GAM402) Deploying a Low-Latency Multiplayer Game Globally: Loadout | AWS re:...(GAM402) Deploying a Low-Latency Multiplayer Game Globally: Loadout | AWS re:...
(GAM402) Deploying a Low-Latency Multiplayer Game Globally: Loadout | AWS re:...
 
Aditya - Hacking Client Side Insecurities - ClubHack2008
Aditya - Hacking Client Side Insecurities - ClubHack2008Aditya - Hacking Client Side Insecurities - ClubHack2008
Aditya - Hacking Client Side Insecurities - ClubHack2008
 
Html5 Game Development with Canvas
Html5 Game Development with CanvasHtml5 Game Development with Canvas
Html5 Game Development with Canvas
 
iPhone Development For Experienced Web Developers
iPhone Development For Experienced Web DevelopersiPhone Development For Experienced Web Developers
iPhone Development For Experienced Web Developers
 
SignalR
SignalRSignalR
SignalR
 
Outburst 3D
Outburst 3DOutburst 3D
Outburst 3D
 
SOA OSB BPEL BPM Presentation
SOA OSB BPEL BPM PresentationSOA OSB BPEL BPM Presentation
SOA OSB BPEL BPM Presentation
 
Haiku OS Presentation
Haiku OS PresentationHaiku OS Presentation
Haiku OS Presentation
 
Dzone
DzoneDzone
Dzone
 
Sriram simplify os_sdevelopment
Sriram simplify os_sdevelopmentSriram simplify os_sdevelopment
Sriram simplify os_sdevelopment
 
Sriram simplify os_sdevelopment
Sriram simplify os_sdevelopmentSriram simplify os_sdevelopment
Sriram simplify os_sdevelopment
 
The next generation of GPU APIs for Game Engines
The next generation of GPU APIs for Game EnginesThe next generation of GPU APIs for Game Engines
The next generation of GPU APIs for Game Engines
 
MongoDB: Optimising for Performance, Scale & Analytics
MongoDB: Optimising for Performance, Scale & AnalyticsMongoDB: Optimising for Performance, Scale & Analytics
MongoDB: Optimising for Performance, Scale & Analytics
 

More from Electronic Arts / DICE

High Dynamic Range color grading and display in Frostbite
High Dynamic Range color grading and display in FrostbiteHigh Dynamic Range color grading and display in Frostbite
High Dynamic Range color grading and display in Frostbite
Electronic Arts / DICE
 

More from Electronic Arts / DICE (20)

GDC2019 - SEED - Towards Deep Generative Models in Game Development
GDC2019 - SEED - Towards Deep Generative Models in Game DevelopmentGDC2019 - SEED - Towards Deep Generative Models in Game Development
GDC2019 - SEED - Towards Deep Generative Models in Game Development
 
SIGGRAPH 2010 - Style and Gameplay in the Mirror's Edge
SIGGRAPH 2010 - Style and Gameplay in the Mirror's EdgeSIGGRAPH 2010 - Style and Gameplay in the Mirror's Edge
SIGGRAPH 2010 - Style and Gameplay in the Mirror's Edge
 
SEED - Halcyon Architecture
SEED - Halcyon ArchitectureSEED - Halcyon Architecture
SEED - Halcyon Architecture
 
Syysgraph 2018 - Modern Graphics Abstractions & Real-Time Ray Tracing
Syysgraph 2018 - Modern Graphics Abstractions & Real-Time Ray TracingSyysgraph 2018 - Modern Graphics Abstractions & Real-Time Ray Tracing
Syysgraph 2018 - Modern Graphics Abstractions & Real-Time Ray Tracing
 
Khronos Munich 2018 - Halcyon and Vulkan
Khronos Munich 2018 - Halcyon and VulkanKhronos Munich 2018 - Halcyon and Vulkan
Khronos Munich 2018 - Halcyon and Vulkan
 
CEDEC 2018 - Functional Symbiosis of Art Direction and Proceduralism
CEDEC 2018 - Functional Symbiosis of Art Direction and ProceduralismCEDEC 2018 - Functional Symbiosis of Art Direction and Proceduralism
CEDEC 2018 - Functional Symbiosis of Art Direction and Proceduralism
 
SIGGRAPH 2018 - PICA PICA and NVIDIA Turing
SIGGRAPH 2018 - PICA PICA and NVIDIA TuringSIGGRAPH 2018 - PICA PICA and NVIDIA Turing
SIGGRAPH 2018 - PICA PICA and NVIDIA Turing
 
SIGGRAPH 2018 - Full Rays Ahead! From Raster to Real-Time Raytracing
SIGGRAPH 2018 - Full Rays Ahead! From Raster to Real-Time RaytracingSIGGRAPH 2018 - Full Rays Ahead! From Raster to Real-Time Raytracing
SIGGRAPH 2018 - Full Rays Ahead! From Raster to Real-Time Raytracing
 
HPG 2018 - Game Ray Tracing: State-of-the-Art and Open Problems
HPG 2018 - Game Ray Tracing: State-of-the-Art and Open ProblemsHPG 2018 - Game Ray Tracing: State-of-the-Art and Open Problems
HPG 2018 - Game Ray Tracing: State-of-the-Art and Open Problems
 
EPC 2018 - SEED - Exploring The Collaboration Between Proceduralism & Deep Le...
EPC 2018 - SEED - Exploring The Collaboration Between Proceduralism & Deep Le...EPC 2018 - SEED - Exploring The Collaboration Between Proceduralism & Deep Le...
EPC 2018 - SEED - Exploring The Collaboration Between Proceduralism & Deep Le...
 
DD18 - SEED - Raytracing in Hybrid Real-Time Rendering
DD18 - SEED - Raytracing in Hybrid Real-Time RenderingDD18 - SEED - Raytracing in Hybrid Real-Time Rendering
DD18 - SEED - Raytracing in Hybrid Real-Time Rendering
 
Creativity of Rules and Patterns: Designing Procedural Systems
Creativity of Rules and Patterns: Designing Procedural SystemsCreativity of Rules and Patterns: Designing Procedural Systems
Creativity of Rules and Patterns: Designing Procedural Systems
 
Shiny Pixels and Beyond: Real-Time Raytracing at SEED
Shiny Pixels and Beyond: Real-Time Raytracing at SEEDShiny Pixels and Beyond: Real-Time Raytracing at SEED
Shiny Pixels and Beyond: Real-Time Raytracing at SEED
 
High Dynamic Range color grading and display in Frostbite
High Dynamic Range color grading and display in FrostbiteHigh Dynamic Range color grading and display in Frostbite
High Dynamic Range color grading and display in Frostbite
 
4K Checkerboard in Battlefield 1 and Mass Effect Andromeda
4K Checkerboard in Battlefield 1 and Mass Effect Andromeda4K Checkerboard in Battlefield 1 and Mass Effect Andromeda
4K Checkerboard in Battlefield 1 and Mass Effect Andromeda
 
FrameGraph: Extensible Rendering Architecture in Frostbite
FrameGraph: Extensible Rendering Architecture in FrostbiteFrameGraph: Extensible Rendering Architecture in Frostbite
FrameGraph: Extensible Rendering Architecture in Frostbite
 
Lighting the City of Glass
Lighting the City of GlassLighting the City of Glass
Lighting the City of Glass
 
Photogrammetry and Star Wars Battlefront
Photogrammetry and Star Wars BattlefrontPhotogrammetry and Star Wars Battlefront
Photogrammetry and Star Wars Battlefront
 
Physically Based and Unified Volumetric Rendering in Frostbite
Physically Based and Unified Volumetric Rendering in FrostbitePhysically Based and Unified Volumetric Rendering in Frostbite
Physically Based and Unified Volumetric Rendering in Frostbite
 
Stochastic Screen-Space Reflections
Stochastic Screen-Space ReflectionsStochastic Screen-Space Reflections
Stochastic Screen-Space Reflections
 

Recently uploaded

Deira Call girl agency 0567006274 Call girls in Deira
Deira Call girl agency 0567006274 Call girls in DeiraDeira Call girl agency 0567006274 Call girls in Deira
Deira Call girl agency 0567006274 Call girls in Deira
Monica Sydney
 

Recently uploaded (20)

Kailashahar Call Girl Whatsapp Number 📞 8617370543 | Girls Number for Friend...
Kailashahar  Call Girl Whatsapp Number 📞 8617370543 | Girls Number for Friend...Kailashahar  Call Girl Whatsapp Number 📞 8617370543 | Girls Number for Friend...
Kailashahar Call Girl Whatsapp Number 📞 8617370543 | Girls Number for Friend...
 
Bhubaneswar🌹Call Girls Rasulgada ❤Komal 9777949614 💟 Full Trusted CALL GIRLS ...
Bhubaneswar🌹Call Girls Rasulgada ❤Komal 9777949614 💟 Full Trusted CALL GIRLS ...Bhubaneswar🌹Call Girls Rasulgada ❤Komal 9777949614 💟 Full Trusted CALL GIRLS ...
Bhubaneswar🌹Call Girls Rasulgada ❤Komal 9777949614 💟 Full Trusted CALL GIRLS ...
 
Call Girls in Perumbavoor / 9332606886 Genuine Call girls with real Photos an...
Call Girls in Perumbavoor / 9332606886 Genuine Call girls with real Photos an...Call Girls in Perumbavoor / 9332606886 Genuine Call girls with real Photos an...
Call Girls in Perumbavoor / 9332606886 Genuine Call girls with real Photos an...
 
Deira Call girl agency 0567006274 Call girls in Deira
Deira Call girl agency 0567006274 Call girls in DeiraDeira Call girl agency 0567006274 Call girls in Deira
Deira Call girl agency 0567006274 Call girls in Deira
 
Bhubaneswar🌹Call Girls Kalpana Mesuem ❤Komal 9777949614 💟 Full Trusted CALL ...
Bhubaneswar🌹Call Girls Kalpana Mesuem  ❤Komal 9777949614 💟 Full Trusted CALL ...Bhubaneswar🌹Call Girls Kalpana Mesuem  ❤Komal 9777949614 💟 Full Trusted CALL ...
Bhubaneswar🌹Call Girls Kalpana Mesuem ❤Komal 9777949614 💟 Full Trusted CALL ...
 
Bhubaneswar🌹Call Girls Chandrashekharpur ❤Komal 9777949614 💟 Full Trusted CAL...
Bhubaneswar🌹Call Girls Chandrashekharpur ❤Komal 9777949614 💟 Full Trusted CAL...Bhubaneswar🌹Call Girls Chandrashekharpur ❤Komal 9777949614 💟 Full Trusted CAL...
Bhubaneswar🌹Call Girls Chandrashekharpur ❤Komal 9777949614 💟 Full Trusted CAL...
 
Vip Call Girls Bhubaneswar 🐱‍🏍 9777949614 Independent Escorts Service Bhubane...
Vip Call Girls Bhubaneswar 🐱‍🏍 9777949614 Independent Escorts Service Bhubane...Vip Call Girls Bhubaneswar 🐱‍🏍 9777949614 Independent Escorts Service Bhubane...
Vip Call Girls Bhubaneswar 🐱‍🏍 9777949614 Independent Escorts Service Bhubane...
 
Call Girls Rajnandgaon / 9332606886 Genuine Call girls with real Photos and N...
Call Girls Rajnandgaon / 9332606886 Genuine Call girls with real Photos and N...Call Girls Rajnandgaon / 9332606886 Genuine Call girls with real Photos and N...
Call Girls Rajnandgaon / 9332606886 Genuine Call girls with real Photos and N...
 
Hire 💕 8617370543 Dhalai Call Girls Service Call Girls Agency
Hire 💕 8617370543 Dhalai Call Girls Service Call Girls AgencyHire 💕 8617370543 Dhalai Call Girls Service Call Girls Agency
Hire 💕 8617370543 Dhalai Call Girls Service Call Girls Agency
 
Satara call girl 8617370543♥️ call girls in satara escort service
Satara call girl 8617370543♥️ call girls in satara escort serviceSatara call girl 8617370543♥️ call girls in satara escort service
Satara call girl 8617370543♥️ call girls in satara escort service
 
Hire 💕 8617370543 Khalilabad Call Girls Service Call Girls Agency
Hire 💕 8617370543 Khalilabad Call Girls Service Call Girls AgencyHire 💕 8617370543 Khalilabad Call Girls Service Call Girls Agency
Hire 💕 8617370543 Khalilabad Call Girls Service Call Girls Agency
 
Ambassa Escorts | 8617370543 call girls service for all Users
Ambassa Escorts | 8617370543 call girls service for all UsersAmbassa Escorts | 8617370543 call girls service for all Users
Ambassa Escorts | 8617370543 call girls service for all Users
 
Deira Call girls 0507330913 Call girls in Deira
Deira Call girls 0507330913 Call girls in DeiraDeira Call girls 0507330913 Call girls in Deira
Deira Call girls 0507330913 Call girls in Deira
 
Call Girls Bhubaneswar 9777949614 call me Independent Escort Service Bhubaneswar
Call Girls Bhubaneswar 9777949614 call me Independent Escort Service BhubaneswarCall Girls Bhubaneswar 9777949614 call me Independent Escort Service Bhubaneswar
Call Girls Bhubaneswar 9777949614 call me Independent Escort Service Bhubaneswar
 
Call Girls Moradabad Just Call 8617370543 Top Class Call Girl Service Available
Call Girls Moradabad Just Call 8617370543 Top Class Call Girl Service AvailableCall Girls Moradabad Just Call 8617370543 Top Class Call Girl Service Available
Call Girls Moradabad Just Call 8617370543 Top Class Call Girl Service Available
 
Call Girls In Gorakhpur Escorts ☎️8617370543 🔝 💃 Enjoy 24/7 Escort Service En...
Call Girls In Gorakhpur Escorts ☎️8617370543 🔝 💃 Enjoy 24/7 Escort Service En...Call Girls In Gorakhpur Escorts ☎️8617370543 🔝 💃 Enjoy 24/7 Escort Service En...
Call Girls In Gorakhpur Escorts ☎️8617370543 🔝 💃 Enjoy 24/7 Escort Service En...
 
Call Girls in Kollam - 9332606886 Our call girls are sure to provide you with...
Call Girls in Kollam - 9332606886 Our call girls are sure to provide you with...Call Girls in Kollam - 9332606886 Our call girls are sure to provide you with...
Call Girls in Kollam - 9332606886 Our call girls are sure to provide you with...
 
Book ☎️ 8617370543 Call Girls in Bharuch and escort services 24x7
Book ☎️ 8617370543 Call Girls in Bharuch and escort services 24x7Book ☎️ 8617370543 Call Girls in Bharuch and escort services 24x7
Book ☎️ 8617370543 Call Girls in Bharuch and escort services 24x7
 
Deira call girls 0507330913 Call girls in Deira
Deira call girls 0507330913  Call girls in DeiraDeira call girls 0507330913  Call girls in Deira
Deira call girls 0507330913 Call girls in Deira
 
🌹Bhubaneswar🌹Ravi Tailkes ❤CALL GIRL 9777949614 ❤CALL GIRLS IN bhubaneswar E...
🌹Bhubaneswar🌹Ravi Tailkes  ❤CALL GIRL 9777949614 ❤CALL GIRLS IN bhubaneswar E...🌹Bhubaneswar🌹Ravi Tailkes  ❤CALL GIRL 9777949614 ❤CALL GIRLS IN bhubaneswar E...
🌹Bhubaneswar🌹Ravi Tailkes ❤CALL GIRL 9777949614 ❤CALL GIRLS IN bhubaneswar E...
 

Battlelog - Building scalable web sites with tight game integration

  • 1. //Building scalable web sites with tight game integration Johan Mjönes & Joakim Bodin
  • 2. What is battlelog? › Battlefield 10 year anniversary soon › Battlelog becoming the community hangout › Integrate game launching for PC players
  • 3. Features › Friend-centric › Easy communication › Current stats and history › Activity log › PC Menu › News / Forums
  • 4.
  • 5.
  • 8. Languages › Developing Battlelog means developing in Python, Java, C++ › The Battlelog Web is written primarily using Python › Plugin, game components in C++ › Python allows for rapid web development (e.g. remote access console)
  • 9. Partitioning Horizontal (sharding) Vertical Battlelog Battlelog 1-7 7-14 ... User Lab Feature ... ... User DBs Different processes (slices and shards)
  • 10. Persistence & Index › MySQL › No joins › Used as indexed KVS › Apache Solr › Full text search for forums › Other uses in the future › Fast!
  • 11. Server to client push › Uses ESN Beaconpush › Allows delivery of messages from web server to client browser. › Uses long polling or websockets (or flash) › AV / anti-malware software + push = › Blocks all websockets › Injects Javascript into the DOM › Etc...
  • 12. Caching with Memcached › Great framework support › Service methods cached via annotations › Invalidation using method signature instead of key › Allows populating cache directly after modification › Dog pile prevention
  • 13. EA Services › Nucleus › Users › No user info in Battlelog DB! Success! › Personas › Soldiers › Entitlements › Licenses › Blaze › Game Servers reports to Blaze › Events to Battlelog › Game Server information › Asynchronous responses (e.g. matchmaking) › REST › Stats
  • 14. Nucleus Details Web Nucleus HTTP Soldiers Web Backend Accounts Licenses Entitlements
  • 15. Game Servers Blaze Details Blaze › Uses Web Access Layer (WAL) DB Blaze › WAL client generated from TDF › TDF is a API definition language › Blaze events (XML over HTTP) Events WAL Thrift Web Frontend Web Backend AJAX Real-time Events Web Browser
  • 16.
  • 17. Friends › Started out normalized › Unmanagable amount of rows › Ended up as one blob per user › Packed user ids › A lot easier to cache properly
  • 18. Server Browser › Custom search server (Java) › Custom query language, minimal message overhead › Fast update, fast search
  • 20.
  • 21. Joining a game: plugin details Web Browser Pipe Game Client Plugin Game UI JS
  • 22. Battle Reports › Game report from Blaze (HTTP XML event) › Parse and divide per player › One report per player via internal message queue › Look for unlocks, rankups, medals, awards etc › Add to feed, send real time updates › Invalidate player stats caches › Compile Battlereport (& pre-cache it) › Send notification to involved (logged in) users
  • 23.
  • 24. Background › Load tested using Locust › Open Source (MIT License) › https://github.com/cgbystrom/locust › Built by ESN (& others) › Battlelog tested with 2.7 million PSU with 36 million players › That’s 40,000 requests per second › The tests was successful
  • 25. Pre-pass › Planet dev bar › Timing › Queries › No point in load testing if there are apparent issues with a single user
  • 26. Realistic load testing › Some testing tools simply hammer certain URLs › Locust allows for realistic usage scenarios › Many players go away for 20 minutes while playing, receiving notifications › Updated tests using actual usage data from alpha trial / open beta › Coordinated testing › Same user spans › Overpopulate tables to simulate fragmented MySQL indices
  • 27. What did we find? › Bugs › Bottlenecks › Never assume where your bottlenecks are › Test to find out › Network related › Saturated network, not CPU › Keep the traffic within the rack! › Software related › Best practices be damned, cheat if neccessary › Lazy loading data in controllers › Client side rendering › Surface + History API + JSON =
  • 28.
  • 29. Being a part of the pipeline › Data driven games › Battlelog has its own pipeline › Written in Python › Imports data from the game pipeline › Weapons, vehicles, levels, dog tags, etc › Assets include images, text, data › Resolving unlocks and dependencies › Generates python structs and javascript structs › Generates many helper maps. Some might only be used once. › DLC friendly! › Result of many iterations
  • 30. User Interface › Separate UI from consoles / in game menu › Having the same wouldn’t make sense, different UX › Adapt to different devices › Web features › Easily accessible, e.g. Sharing › Extendability with browser extensions, user styles etc › Access on any platform (play on console, have Battlelog on iPad) › Easy to iterate over UI changes
  • 31.
  • 32. Battlelog will evolve › Agile: Easy to update › Big things: › DLC › Public APIs › Other things we can’t talk about › Small things › Improvements based on community feedback
  • 33.
  • 34. Johan Mjönes The Battlelog team is hiring! @nollbit http://dice.se/hiring.asp Joakim Bodin jobs@dice.se @jbripley Technical Director Development Director Backend Frontend

Editor's Notes

  1. “Battlefield has existed for many years now, next year will be the 10 year anniversary of the series. Battlelog was our vision for becoming the center of the Battlefield community from BF3 and going forward. We wanted it to become the natural hangout for all the people playing Battlefield games. Especially for our PC playing audience, were we thought we could integrate launching the game and finding servers into Battlelog.”
  2. “We set up a list of features that Battlelog should include.”Friend-centric: All features should be integrated with your friends listCommunication: Always available com center UI. With friends status, such as Online/Playing/Away/Offline, 1-1 chat and group party chat system w/ optional VoIPStats: Deep and easily over viewed track record of your accomplishment and easy ways to compare yourself with your friends. This would also include a history of latest battles and a way to study them in detail.Keep up with your friends: A feed of unlock progress, played battles, new friends, popular game servers and interesting forum posts.PC Menu: Easily launch the PC game, include your friends in a Co-Op match or start a Multiplayer Squad.News / Forums: Keep up with what DICE are doing and discuss hot topics with other member of the community.All together, you would have a lot of ways to view and interact with how you and your friends play battlefield.
  3. “Battlefield has built a big community over the the years and BF3 was set to make it even bigger. We wanted to build a social network for this community and if successful would need support to a large amount of users.”“Our calculations put this community at several hundred thousands users accessing our site during peak hours. Very few web sites are built to be able to support these kinds of user numbers from day 1. This would be a massive undertaking in deploying hardware and scaling our software features.”Infographic credit:http://connect.icrossing.co.uk/global-facebook-statistics_6499
  4. Battlelog is not an island unto itself, so it would need to work well with EA’s account system (Nucleus) and the game backend system (Blaze).Battlelog uses Nucleus to display all your Battlelog soldiers, regardless if they’re connected to Xbox Live, PlayStation Network or Origin. We also use it to know which games and items that the player has bought or gotten through pre-order incentives for each platform.Battlelog uses Blaze to provide it with large amounts of stats information about your progress in the game, as well as detailed history of each round you’ve played. Blaze is also used by the web backend, for other functions, such as keeping track of game servers, reserve server slots and track your place in a game server queue.Blaze has an event system that enables the game servers to quickly push things to Battlelog. These events often end up as real-time information on the web frontend. For example, a Blaze event about new battle reports can be used for both pushing a real-time notification to the user and to intelligently invalidate our backend caches. This way, the player always knows when there is new information and we can make sure to always show them their latest accomplishments.”
  5. Communication with Nuclues is accomplished using a thin REST client, connecting Nuclues’ account and entitlement systems with the Web Backend. The web backend then transforms these accounts and entitlements into soldiers and licenses, which are then displayed on Battlelog.
  6. Battlelog uses Blaze to provide it with large amounts of stats information about your progress in the game, as well as detailed history of each round you’ve played. Blaze is also used by the web backend, for other functions, such as keeping track of game servers, reserve server slots and track your place in a game server queue.Blaze has an event system that enables the game servers to quickly push things to Battlelog. These events often end up as real-time information on the web frontend. For example, a Blaze event about new battle reports can be used for both pushing a real-time notification to the user and to intelligently invalidate our backend caches. This way, the player always knows when there is new information and we can make sure to always show them their latest accomplishments.”
  7. “From the players perspective, joining a PC game server on Battlelog is as easy as loading the server browser and clicking Join.  Of course, there is a lot of things that happen in the background when that Join button is clicked. First we make sure to reserve a slot on the game server, then we construct a command line that will instruct the game client what to do, and lastly we use our own web plug-in to run our game executable with that command line.”“As Battlelog needs to provide the same player interaction as the console game client, like showing if the game is running, it’s current progress, be able to communicate error messages and close it down. For that we need a two-way message system between the game client and the web browser.”
  8. Lets look at the components that make this possible.Game UIJSPluginPipeGame ClientTo make this work, we use a simple named pipe. When the browser plugin is running it has a named pipe endpoint set up and during launch the game client connects to this endpoint. After that, we can use a simple text protocol to send things such loading progress or error messages from the game to Battlelog. Of course. Battlelog can also us this pipe send commands to the game. Such as closing it down or make it switch between different game servers.”
  9. “BF3 is a data driven game, our pipeline picks up after the game pipeline. Weapons, images, localization, unlocks are all from the game. This allows us to pick up patch/DLC additions/changes quickly”