A presentation on clearly defining a microservice architecture, culture, and discovering how to determine whether it is a step in the right direction for your system. I discuss about the decisions that lead us to take on a microservice architecture approach at Sprout, and the challenges we are facing as a startup learning a new method for making apps.
2. ASK AWAY!
Step 1. Go to slido.com
Step 2. Key in #SproutAcademy in the event code.
Step 3. Type your questions.
Wifi name: KMC
Wifi password: S0lstic3!
3. About Me
Senior Architect at Sprout
Solutions
Microsoft MVP for Visual Studio
and Development Technologies
User Group Lead of the
Philippine .NET Users Group
(PHINUG)
19. Integration became a business need...
Biometric data upload
Data integration between apps
20. More clients & users meant
more business needs came along...
Biometric data upload
Data integration between apps
Clients need APIs
High Availability
Performance
New products
Tangential features
Better UX
23. You have a true microservice when you achieve...
Componentization via services
Organized around business
capabilities
Products not Projects
Smart endpoints vs. dumb pipes
Decentralized governance
Decentralized data management
Infrastructure automation
Design for failure
Evolutionary Design
26. Organized around business capabilities
Each team must be full stack
Developer
QA
UI
DBA
System Admins/Devs
} DevOps culture
27. Products not projects
Each team must have a dedicated product owner
Preferably a domain expert
Otherwise needs to have immersed with end users
Team should be concerned over the product lifetime
29. Smart endpoints vs. dumb pipes
Endpoints should have full business logic
Security
Data validation
Error handling
Logging
Do not make CRUD endpoints
30. Decentralized governance & data management
Each team must have a say on their development stack
UI/UX
Backend
QA
Each team must have a say on their data store
SQL vs. No SQL?
Must otherwise be compliant with business requirements
38. Option 1: On Premise
Web
Live
Data
Live
Web
Test
Data
Test
● Pros: Greater degree of
control, more cost
effective (up to a certain
point)
● Cons: More difficult to
expand and provision,
less resilient to downtime,
need relevant skillset
39. Option 2: Public Cloud (AWS / Azure / Google)
● Pros: Faster provisioning,
more resilient, less
management overhead
● Cons: Beefed up specs
and bandwidth are
costlier, hidden costs,
data residency
complications
41. Option 1: Unsharded data
Sprout HR Sprout Payroll
Sharded by tenant Sharded by tenant
● Pros: Simpler data access,
easier maintenance for
backups & business
continuity
● Cons: Lost data isolation,
potential bottlenecks at
data layer
Employee 201
42. Option 2: Aggressive sharding
Sprout HR Sprout Payroll
Sharded by tenant and by
employee table
Sharded by tenant
● Pros: Greater data
isolation and modularity;
Shards could be deployed
to separate servers for
better throughput
● Cons: More difficult
maintenance for backups
& business continuity
Employee 201
43. Our journey towards...
Componentization via services
Organized around business
capabilities
Products not Projects
Smart endpoints vs. dumb pipes
Decentralized governance
Decentralized data management
Infrastructure automation
Design for failure
Evolutionary Design
Up to a certain size monoliths are much simpler
It’s easier to keep data consistent
Refactoring models across modules are easier because of reuse
And to answer that question, let’s tell another story
Biometric data upload -- need for a communication layer
Data integration between apps -- HR and Payroll talking to each other
New products -- Recruitment
Clients asking for REST APIs -- their own needs
Tangential features -- nice to haves + client requests
And to answer that question, let’s tell another story
If each shape is an individual business capability and the green field represents an application, this is how they would look like
Componentization -- a responsibility is represented as a service
Business capabilities -- Individual service teams are not centered around skillsets (UI vs devs vs DBA) but is full stack
Products not Projects -- Success is measured against usefulness vs. completion
Smart endpoints vs. dumb pipes -- Logic is at the endpoints. NO CRUD ENDPOINTS
Decentralized governance -- each product team should be able to use their own stack
Decentralized data management -- each product team should ideally have their own data store
Infrastructure automation -- provisioning and deployment should be automated
Design for failure -- capability to handle errors more gracefully
Evolutionary Design -- microservices are designed to constantly change and improve
Partial Deployment -- easier because no need to bring down whole app
Availability -- easier to scale, but data consistency is a question
Preserve Modularity -- the architecture is the modularity
Multiple Platforms -- No real need to stick to one stack
Componentization -- a responsibility is represented as a service
Business capabilities -- Individual service teams are not centered around skillsets (UI vs devs vs DBA) but is full stack
Products not Projects -- Success is measured against usefulness vs. completion
Smart endpoints vs. dumb pipes -- Logic is at the endpoints. NO CRUD ENDPOINTS
Decentralized governance -- each product team should be able to use their own stack
Decentralized data management -- each product team should ideally have their own data store
Infrastructure automation -- provisioning and deployment should be automated
Design for failure -- capability to handle errors more gracefully
Evolutionary Design -- microservices are designed to constantly change and improve