Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Evolution of edX LMS and Studio Architecture

Evolution of edX LMS and Studio Architecture

The LMS and Studio architecture has evolved in many ways over the last few years and we are actively developing its future. This talk focuses on the past, present, and possible future of the edX-platform codebase.

Learn about how the edx-platform evolved as it quickly grew in team size, features, and usage since 2011. Be aware of the upcoming transformation of edX's technology-concerned monolith to a business-centric monolith. Additionally, learn how the edX architecture is scaling by investing in technology and design principles inspired by the Reactive Manifesto via asynchronous messaging/eventing, CQRS, and bounded contexts. These are illustrated through recent work on Block Transformers and the Grades architecture.

907b8b314ff2b32d218325077c45b6f0?s=128

Nimisha Asthagiri

May 25, 2017
Tweet

Transcript

  1. May 26, 2017 Evolution of LMS and Studio Architecture Nimisha

    Asthagiri nimisha@edx.org github.com/nasthagiri
  2. How have we evolved? Where are we now? What’s a

    desirable future? How are we getting there? What are some examples?
  3. How have we evolved? Where are we now? What’s a

    desirable future? How are we getting there? What are some examples?
  4. edx-pla(orm Commits

  5. edx-pla(orm Contributors 0 10 20 30 40 50 60 70

    edx-pla(orm contributors Trimester Total: 342
  6. Team Growth 0 10 20 30 40 50 60 70

    80 2013 2014 2015 2016 2017 edX Engineers year
  7. File Growth 0 1000 2000 3000 4000 5000 6000 7000

    Apr-13 Jun-13 Aug-13 Oct-13 Dec-13 Feb-14 Apr-14 Jun-14 Aug-14 Oct-14 Dec-14 Feb-15 Apr-15 Jun-15 Aug-15 Oct-15 Dec-15 Feb-16 Apr-16 Jun-16 Aug-16 Oct-16 Dec-16 Feb-17 Apr-17 Number of files .po files removed
  8. None
  9. None
  10. None
  11. None
  12. None
  13. None
  14. Usage Growth 0 500 1000 1500 2000 2500 3000 3500

    4000 4500 Number of enrollments in Thousands
  15. Usage Growth 0 5 10 15 20 25 30 35

    40 45 Compounded enrollments in Millions
  16. Data Growth 0 500 1000 1500 2000 2500 3000 3500

    4000 4/1/12 6/1/12 8/1/12 10/1/12 12/1/12 2/1/13 4/1/13 6/1/13 8/1/13 10/1/13 12/1/13 2/1/14 4/1/14 6/1/14 8/1/14 10/1/14 12/1/14 2/1/15 4/1/15 6/1/15 8/1/15 10/1/15 12/1/15 2/1/16 4/1/16 6/1/16 8/1/16 10/1/16 12/1/16 2/1/17 4/1/17 Number of courses enrolled courses total enrolled courses to date
  17. How have we evolved? Where are we now? What’s a

    desirable future? How are we getting there? What are some examples?
  18. None
  19. None
  20. None
  21. None
  22. None
  23. None
  24. None
  25. How have we evolved? Where are we now? What’s a

    desirable future? How are we getting there? What are some examples?
  26. Discoverability Extensibility Resilient ElasOc Responsive Modularity

  27. ReacOve Manifesto ElasOc LMS: 13k rpm Studio: 60 rpm no

    bo;lenecks Responsive 99% < 2s consistent Resilient 99.9% upAme MTTF & MTTR isolaAon
  28. How have we evolved? Where are we now? What’s a

    desirable future? How are we getting there? What are some examples?
  29. ReacOve Manifesto ElasOc Responsive Resilient

  30. ReacOve Manifesto ElasOc Responsive Resilient Message Driven event-driven asynchronous loosely

    coupled locaAon transparency
  31. Asynchronous: OrchestraOon or Choreography?

  32. Resources •  ReacOve Manifesto •  Self-contained Systems (SCS) •  Domain

    Driven Design, Eric Evans •  Building Microservices, Sam Newman •  Modularity, Parnas, 1972 •  Architecture Decision Records, Michael Nygard
  33. Modularity Extensibility Main take aways •  Asynchronous non-blocking calls • 

    Separate reads from writes (CQRS) •  Bounded contexts •  Aligned best pracOces Responsive ElasOc Resilient Discoverability
  34. None
  35. Technical Concerns Steel Silver Wood PlasOc

  36. Business Concerns Currency Hardware Kitchenware

  37. Technical Concerns

  38. Business Concerns

  39. How have we evolved? Where are we now? What’s a

    desirable future? How are we getting there? What are some examples?
  40. Recent examples Asynchronous Bounded Context CQRS Extensibility Grades ✔ ✔

    ✔ Course sharing ✔ ✔ Course experiences ✔ ✔ Enterprise ✔ ✔ Course import/export ✔ Block transformers ✔ ✔ ✔ ✔ Course catalog ✔ ✔ Course overviews ✔ ✔ LTI consumer xBlock ✔ ✔
  41. Block Transformers today’s max: 4,332 blocks in an MIT course

  42. Block Transformers •  Collect phase for expensive operaOons –  Content

    tree traversal –  Denormalize –  xBlock instanOaOon via Modulestore –  Asynchronous, non-blocking •  Read phase for fast-access to block data –  User-specific and API-specific transformaOons –  Access read-opOmized data structure from AWS S3 –  Synchronous, blocking
  43. Block Transformer ‘Collect’ Phase: Block Transformer ‘Transform’ (Read) Phase:

  44. Example: Start Date Transformer ‘Collect’ Phase:

  45. None
  46. Best PracOces •  Join the discussions (OEPs, doc PRs, slack):

    –  Tests –  Code Structure –  Extensibility •  xBlocks + django •  Pluggable framework: Stevedore •  LTI + SSO •  Web hooks
  47. Gracias Nimisha Asthagiri nimisha@edx.org github.com/nasthagiri

  48. Extra Slides

  49. Example: Content Tags Transformer ‘Collect’ Phase:

  50. Data Scale 0 250 500 750 1000 1250 1500 1750

    2000 2250 0-499 500 1000 1500 2000 2500 3000 3500 4000 number of courses number of course blocks max: 4332