Successfully reported this slideshow.
Your SlideShare is downloading. ×

Microservices, la risposta che (forse) cercavi!

Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Upcoming SlideShare
Docker & Kubernetes
Docker & Kubernetes
Loading in …3
×

Check these out next

1 of 139 Ad

Microservices, la risposta che (forse) cercavi!

Download to read offline

Dalle applicazioni desktop al web ed alle architetture multi tier. Dallo sviluppo basato sui componenti alle service oriented architecture… I Microservices saranno la soluzione vincente?

Dalle applicazioni desktop al web ed alle architetture multi tier. Dallo sviluppo basato sui componenti alle service oriented architecture… I Microservices saranno la soluzione vincente?

Advertisement
Advertisement

More Related Content

Advertisement

More from Commit University (20)

Advertisement

Recently uploaded (20)

Microservices, la risposta che (forse) cercavi!

  1. 1. MICROSERVICES, LA RISPOSTA CHE (FORSE) CERCAVI! FIRENZE 22 MARZO 2018
  2. 2. ! I’M THOMAS NICE TO MEET YOU!
  3. 3. MICHELE FRANZIN @REALFUZZY
  4. 4. AGENDA
  5. 5. INTEREST IN #MICROSERVICES
  6. 6. DISCLAIMER our personal experience ideas, comment, etc… are welcome subject is wide, so I’d love to hear your thoughts :-) it’s not a code talk (some source showed)
  7. 7. THE MONOLITH
  8. 8. THE (SOMETIMES EVIL) MONOLITH http://www.infoq.com/articles/microservices-intro
  9. 9. easy to develop
  10. 10. IDEs & development tools support
  11. 11. easy to test
  12. 12. simple to deploy
  13. 13. works well for relatively small apps
  14. 14. AFTER A WHILE… http://www.qcodemag.it/wp-content/uploads/2014/09/favela.jpg
  15. 15. growth overloads everything
  16. 16. difficult to adopt new technologies
  17. 17. often stuck with the starting choices
  18. 18. doesn’t scale to long-lived application
  19. 19. BUAHAHAHAHA! I AM THE MONOLITH! COME TO THE WORLD TO BRING IMMOBILISM AND COMPLEXITY!
  20. 20. MONOLITH
  21. 21. MONOLITH ARCHITECTURE ARCHITECTURE MICROSERVICEIC
  22. 22. ARCHITECTURE is the keyword
  23. 23. WHY MICROSERVICES • suite of small services • running in its own process • communicating with lightweight mechanisms • built around business capabilities • independently automated deployable • technology agnostic
  24. 24. http://blog.arungupta.me/monolithic-microservices-refactoring-javaee-applications/
  25. 25. EXPECTATIONS http://www.wallpaperawesome.com/wallpapers-awesome/
  26. 26. relatively small
  27. 27. easier to understand
  28. 28. easier to scale development
  29. 29. improve fault isolation
  30. 30. develop & deploy independently
  31. 31. no vendor lock
  32. 32. improves tuning & scaling
  33. 33. - additional complexity of a distributed system - tools/IDEs are monolithic applications oriented - testing is more difficult - must implement the inter-service communication - increase memory consumption
  34. 34. 1ST WEEK
  35. 35. Divide et Impera
  36. 36. "
  37. 37. "
  38. 38. "
  39. 39. "
  40. 40. 2ND WEEK
  41. 41. IT WAS NOT SO GOOD
  42. 42. THE ONLY WAY TO MAKE SOFTWARE SECURE, RELIABLE, AND FAST IS TO MAKE IT SMALL. Andrew S. Tanenbaum
  43. 43. #
  44. 44. #
  45. 45. #
  46. 46. 6TH MONTH
  47. 47. 3 days * 2 people = 6 workdays! ⬇ %
  48. 48. #
  49. 49. OUR MICROSERVICES TECHNOLOGY/TOOLS
  50. 50. &
  51. 51. & '
  52. 52. ? days * ? people = ? days!
  53. 53. (
  54. 54. Simulates isolate systems(like production) Usable in more OS Ready to use Easy to install and use (
  55. 55. )
  56. 56. )
  57. 57. *
  58. 58. Simulates isolate systems(like production) Usable in more OS Ready to use Easy to install and use (
  59. 59. DOCKER FOR MAC/WINDOWS Docker for Mac/Windows is an easy-to-install desktop app for building, debugging and testing Dockerized apps on a Mac/PC.  +
  60. 60. Docker platform Docker compose Docker CLI Docker Notary CLI
  61. 61. Simulate isolate systems Usable in more OS Ready to use Easy to install and use ,
  62. 62. Docker platform Docker compose Docker CLI Docker Notary CLI
  63. 63. DEMO TIME &
  64. 64. DEMO FILES •Dockerfile •docker-compose.yml
  65. 65. DOCKER IMAGE
  66. 66. DOCKER IMAGE
  67. 67. DOCKER IMAGE FROM ruby RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs RUN mkdir /my_app WORKDIR /my_app File: ./my_app/Dockerfile
  68. 68. DOCKER IMAGE FROM ruby RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs RUN mkdir /my_app WORKDIR /my_app File: ./my_app/Dockerfile
  69. 69. https://hub.docker.com/
  70. 70. DOCKER IMAGE FROM ruby RUN apt-get update -qq && apt-get install -y build- essential libpq-dev nodejs RUN mkdir /my_app WORKDIR /my_app File: ./my_app/Dockerfile
  71. 71. DOCKER IMAGE FROM ruby RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs RUN mkdir /my_app WORKDIR /my_app File: ./my_app/Dockerfile
  72. 72. CONTAINER AND MICROSERVICES: A ❤ STORY
  73. 73. DOCKER COMPOSE
  74. 74. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/myapp - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  75. 75. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  76. 76. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  77. 77. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  78. 78. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  79. 79. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  80. 80. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  81. 81. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  82. 82. version: '3' services: web: build: ./my_local_app command: bash -c "bundle install --path=/cache && rails s -p 3000 -b '0.0.0.0'" ports: - "4000:3000" volumes: - ./my_local_app/my_rails_app:/my_app - ./my_local_app/gem_cache:/cache depends_on: - db db: image: postgres DOCKER COMPOSE File: ./docker-compose.yml
  83. 83. WEB DB WEB DB & '
  84. 84. 3 days * 2 people = 6 workdays!
  85. 85. 0.25 days * 2 people = 0.5 workday! 3 days * 2 people = 6 workdays!
  86. 86. CONTAINER AND MICROSERVICES: A ❤ STORY
  87. 87. ▸ Microservices are cool, but be careful. ▸ Docker compose is very useful in develop env. ▸ How a portable and repeatable development environment save your time, especially with microservices architecture. WHAT HAVE WE SEEN?
  88. 88. OK BUT…WHAT’S NEXT? .
  89. 89. κυβερνήτης
  90. 90. κυβερνήτης “helmsman of a ship”
  91. 91. CO-LOCATING HELPER PROCESSES MOUNTING STORAGE SYSTEMS DISTRIBUTING SECRETS CHECKING APPLICATION HEALTH REPLICATING APPLICATION INSTANCES USING HORIZONTAL POD AUTOSCALING NAMING AND DISCOVERING BALANCING LOADS ROLLING UPDATES MONITORING RESOURCES ACCESSING AND INGESTING LOGS DEBUGGING APPLICATIONS PROVIDING AUTHENTICATION AND AUTHORIZATION
  92. 92. HTTP://KOMPOSE.IO/ -> KOMPOSE ->
  93. 93. delivered is better than perfect
  94. 94. BUAHAHAHAHA! I AM THE MONOLITH! COME TO THE WORLD TO BRING IMMOBILISM AND COMPLEXITY!
  95. 95. ~385.7Mb compressed
  96. 96. • single error in csv import should not abort the whole process • realtime data input • expose results to thousands of potential visitors (web) • it should work on every browser (at least 5 years) • expose functions to 3rd party applications via API • sell to other companies as white-label SAAS (optional) Changes!
  97. 97. how do you proceed? should I take care of what? any potential pitfalls?
  98. 98. <tag cloud>
  99. 99. Technical choices have non-technical outcomes
  100. 100. – Melvin Conway, 1968 “organizations which design systems … are constrained to produce designs which are copies of the communication structures of these organizations”.
  101. 101. Non-technical choices have technical outcomes
  102. 102. AWARENESS
  103. 103. / do practice ask experts 0 be aware
  104. 104. HAPPY HACKING!
  105. 105. QUESTIONS ? 1 2
  106. 106. @realfuzzy Michele Franzin @rosse91 Thomas Rossetto Thanks 4 coming!

×