Diese Präsentation wurde erfolgreich gemeldet.
Wir verwenden Ihre LinkedIn Profilangaben und Informationen zu Ihren Aktivitäten, um Anzeigen zu personalisieren und Ihnen relevantere Inhalte anzuzeigen. Sie können Ihre Anzeigeneinstellungen jederzeit ändern.

DDD Taiwan Community 2019 01-26-1st-meetup-why ddd matters

912 Aufrufe

Veröffentlicht am

Domain Driven Design Taiwan Community meetup series. This slides learn from ddd_eu, DDD china and sort of public videos on youtube. Focus on Why DDD matters, what is microservices, and how can you adopt microservices.

Veröffentlicht in: Technologie
  • Login to see the comments

DDD Taiwan Community 2019 01-26-1st-meetup-why ddd matters

  1. 1. © 2019, Domain Driven Design Taiwan Community Kim Kao ( ) Jan 26, 2019 Why DDD matters Crunch problems, design solutions
  2. 2. © 2019, Domain Driven Design Taiwan Community
  3. 3. © 2019, Domain Driven Design Taiwan Community uncertainty.equals(dangerous) == true
  4. 4. © 2019, Domain Driven Design Taiwan Community A typical day for problem solving... Manager - “We are going to launch new product. We are challenged by competitors, several niche economics there." “I heard of microservices(anything else), sounds good to quick deliver. Make sure you are aware on this, and release on time!!!” Developer - “...........”
  5. 5. © 2019, Domain Driven Design Taiwan Community Problem Solving
  6. 6. & & &
  7. 7. © 2019, Domain Driven Design Taiwan Community Application is … Requirements Software Modeling Collaboration
  8. 8. © 2019, Domain Driven Design Taiwan Community Eric Evans Ubiquitous Language Bounded Context Collaboration
  9. 9. © 2019, Domain Driven Design Taiwan Community Sheet music works
  10. 10. © 2019, Domain Driven Design Taiwan Community When talk about problem
  11. 11. © 2019, Domain Driven Design Taiwan Community IoT SSO Server less Network Container Firecracker AI/ML DW Front End DB CI/CD
  12. 12. © 2019, Domain Driven Design Taiwan Community
  13. 13. © 2019, Domain Driven Design Taiwan Community Knowledge from stakeholders Use Case Modeling
  14. 14. © 2019, Domain Driven Design Taiwan Community Through Classic to Agile ICONIX Processing
  15. 15. © 2019, Domain Driven Design Taiwan Community Object Modeling … ER Modeling … xxx Modeling … A lack of Collaboration with non-tech stakeholders Not “Ubiquitous Language”
  16. 16. © 2019, Domain Driven Design Taiwan Community Way to collaborate • Point out the events • Who send the command • Find the Noun(s) • Have all team voices Commands Events Aggregate
  17. 17. © 2019, Domain Driven Design Taiwan Community Domain Driven Design
  18. 18. © 2019, Domain Driven Design Taiwan Community
  19. 19. © 2019, Domain Driven Design Taiwan Community Intent matters
  20. 20. © 2019, Domain Driven Design Taiwan Community Domain Driven Design (DDD) • What is DDD? • Not only a Technology / Methodology • Set of principles and patterns for focusing the design effort where it matters most • It’s all about • Understanding the domain where the software will be applied • Create highly expressive model of that domain • Distil Ubiquitous language
  21. 21. © 2019, Domain Driven Design Taiwan Community Domain (Strategy) Modeling – Basic Terms • Domain • Subject area where the software will be applied • Example : VOD Domain, EC Domain, Banking Domain • Subdomain • Logically separated part of the Domain • Example : Ingestion, Streaming, Geo Location • Domain Model • Software model for solution of a domain problem • Bounded Context • Explicit boundary where Domain Model lives
  22. 22. © 2019, Domain Driven Design Taiwan Community Tell about story
  23. 23. © 2019, Domain Driven Design Taiwan Community Domain is about capability Grab key events to Abstraction to give
  24. 24. © 2019, Domain Driven Design Taiwan Community Dive into relationships and why Strategic DDD
  25. 25. © 2019, Domain Driven Design Taiwan Community Pattern in Practice Tactical DDD
  26. 26. © 2019, Domain Driven Design Taiwan Community Approach • Collect the “Aggregates” which stand for similar concept in the “Bounded Context”. • Prioritize the “Domains”, which one is Core Domain, rest for Sub Domain, even Utility Domain. • Get Consensus, not Compromise • Focus on Core Domain
  27. 27. © 2019, Domain Driven Design Taiwan Community Tell story by coding
  28. 28. © 2019, Domain Driven Design Taiwan Community Microservices?
  29. 29. © 2019, Domain Driven Design Taiwan Community 100 LOC
  30. 30. © 2019, Domain Driven Design Taiwan Community 200 LOC
  31. 31. © 2019, Domain Driven Design Taiwan Community 400? 1000?
  32. 32. © 2019, Domain Driven Design Taiwan Community Trap in Microservices
  33. 33. © 2019, Domain Driven Design Taiwan Community Crunch Bounded Context • 1st focus on high Cohesion • Always Low Coupling later
  34. 34. © 2019, Domain Driven Design Taiwan Community “All Things Distributed” “Design to Fail” “Redundancy is hard” “Server provisioning hell .....................................”
  35. 35. © 2019, Domain Driven Design Taiwan Community It’s about capability • Are you ready to deal with M:N transaction compensation ? • Are you ready to embrace the rapidly change by contract ?
  36. 36. © 2019, Domain Driven Design Taiwan Community When you should dive in Microservices Team Partners Business Operation Coding Value
  37. 37. © 2019, Domain Driven Design Taiwan Community Migration Strategy Assess and prioritize, one app at a time Re-host (lift-and-shift) data center or Cloud Re-platform (lift-tinker-shift) VMs à containers Re-factor monolith à microservices Re-invent (cloud-native) new serverless microservices Determine Core/Sub/utility Domain
  38. 38. © 2019, Domain Driven Design Taiwan Community How BBoM to Microservices • Only one domain a time • Test Driven • Value Driven • Change Driven • Adapter in BBoM • Port in Microservices
  39. 39. © 2019, Domain Driven Design Taiwan Community Event handler
  40. 40. © 2019, Domain Driven Design Taiwan Community Domain Events means … Un Cer tain ty the state of being uncertain.
  41. 41. © 2019, Domain Driven Design Taiwan Community De duplicator Event 3 Event 1 Event 2 Event 1 Event 3 Event 2 Event 1 … Want In-Order, actually Uncertainty
  42. 42. © 2019, Domain Driven Design Taiwan Community Uncomfortable It’s okay to feel this way. @VaughnVernon
  43. 43. © 2019, Domain Driven Design Taiwan Community Dependencies
  44. 44. © 2019, Domain Driven Design Taiwan Community Focus on Contract and Protocol • Service owner is consumer • Expose SDK means projection technical decisions to consumer • “Operation” complexity spread to consumer • Consumer should be able to use any language/technology and change over time! • AWS • API Gateway, Lambda Execution, any composable API call
  45. 45. © 2019, Domain Driven Design Taiwan Community Some exceptions • Centralized Logging • Monitoring • Distributed tracing
  46. 46. © 2019, Domain Driven Design Taiwan Community Principle
  47. 47. © 2019, Domain Driven Design Taiwan Community Adopt Microservices?
  48. 48. © 2019, Domain Driven Design Taiwan Community Business Wants https://vaughnvernon.co/tag/event-storming/
  49. 49. © 2019, Domain Driven Design Taiwan Community But You Want https://vaughnvernon.co/tag/event-storming/
  50. 50. © 2019, Domain Driven Design Taiwan Community Challenge on migration to Microserivces • Legacy looks like Big ball of mud(BBOM) • Heavy dependency with external system • No idea on split BBOM • No idea to find out system boundary • Which service(s) worth to do • Human resources allocation • Team, out sourcing, ISVs solution
  51. 51. © 2019, Domain Driven Design Taiwan Community Business operation without whole picture The Blind Men and the Elephant Is It correct to all in microservices or serverless ?
  52. 52. © 2019, Domain Driven Design Taiwan Community Precondition to do microservices Rapid Provisioning Basic monitoring Rapid application deployment Martin Fowler Realize the business flow, way to decompos
  53. 53. © 2019, Domain Driven Design Taiwan Community Better way to decompose Monolith Domain Expert Matters
  54. 54. © 2019, Domain Driven Design Taiwan Community Learn and respect Domain experts
  55. 55. © 2019, Domain Driven Design Taiwan Community How DDD can help you • Business strategy on resource allocation • Best resources should be put in most key/core domain • Buy or out-sourcing common domain and sub domain • Service re-architecture • Form up the system context boundary • Knowing the upstream-downstream relationship between domains • Meaningful to do microservice (separate computing/persist, and API communication ) • Service Migration • Good to re-architecture
  56. 56. © 2019, Domain Driven Design Taiwan Community Migration Business Case Know Why/What/How • Options to Optimize • Learn and speak same language with Domain expert • Capture key business events, if it matters • Adopt appropriate AWS services to implement Solution
  57. 57. © 2019, Domain Driven Design Taiwan Community Sharpen your saw
  58. 58. © 2019, Domain Driven Design Taiwan Community DDD stuff
  59. 59. © 2019, Domain Driven Design Taiwan Community Event Storming
  60. 60. © 2019, Domain Driven Design Taiwan Community Specification by Example
  61. 61. © 2019, Domain Driven Design Taiwan Community Programming Skills level up • Test Driven Design • Behavior Driven Design • Refactoring • CI/CD
  62. 62. © 2019, Domain Driven Design Taiwan Community Practice DDD Telegram : YikaiKao WeChat : YikaiKao Twitter : @DddTaiwan, @YikaiKao GitHub Repos
  63. 63. © 2019, Domain Driven Design Taiwan Community Thank You!
  64. 64. © 2019, Domain Driven Design Taiwan Community Let’s explore Event Storming

×