Modules instead of Microservies

Modules instead of Microservies

6d48d3849102b57bbc1462c0da0b3866?s=128

Benjamin Smith

August 11, 2017
Tweet

Transcript

  1. 3.
  2. 4.
  3. 5.
  4. 7.
  5. 14.
  6. 20.

    MODULES • All code lives in the same repo •

    Modules define the boundaries and dependencies @benjamin_smith
  7. 21.
  8. 24.
  9. 25.
  10. 26.
  11. 27.
  12. 28.
  13. 31.

    MICROSERVICES • Scaling • Shared data/behavior across apps • Different

    services requiring different tech stacks • Feeling cool @benjamin_smith
  14. 34.
  15. 37.
  16. 40.
  17. 41.
  18. 44.
  19. 45.
  20. 47.
  21. 51.
  22. 54.

    How to create a service • Step 1: create a

    module • Step 2: create a service • Step 3: ??? • Step 4: profit @benjamin_smith
  23. 55.
  24. 56.

    module to microservice class Likes def self.create(…) # create like

    in DB Like.create!(…) end end class Likes def self.create(…) # make request to Like service Net::HTTP.post_form(…) end end @benjamin_smith
  25. 57.
  26. 59.
  27. 85.
  28. 86.
  29. 87.

    –Martin Fowler “So my primary guideline would be don't even

    consider microservices unless you have a system that's too complex to manage as a monolith. The majority of software systems should be built as a single monolithic application. Do pay attention to good modularity within that monolith, but don't try to separate it into separate services.”