2. Lack of etiquette and manners is a huge turn off.
KnolX Etiquettes
Punctuality
Respect Knolx session timings, you
are requested not to join sessions
after a 5 minutes threshold post
the session start time.
Feedback
Make sure to submit a constructive
feedback for all sessions as it is
very helpful for the presenter.
Silent Mode
Keep your mobile devices in silent
mode, feel free to move out of
session in case you need to attend
an urgent call.
Avoid Disturbance
Avoid unwanted chit chat during
the session.
3. Our Agenda
Monolith vs Microservices
02 What is Microservices?
03 What is Lagom Framework?
CQRS and ES
05
Lagom Architecture
01
04
05
Demo
06
5. What is Microservices?
Microservice architecture is an architecture used in the process of
application creation where each feature is developed separately and
independently between one feature and another. To communicate between
each feature or service using HTTP rest or message bus.
Benefits-
● Separate development and deployment
● Scaling and resilience
● Independent technologies stacks
6. Lagom Framework
Lagom is an open source framework for architecting microservices. Lagom
helps you to build microservices as systems which are elastic, resilient and
scalable from within.
Lagom is build on top of Play and Akka Actors. In particular, it adds API for
implementing services and a CQRS- based persistence API on top of the APIs
Play already has.
7. Lagom Framework - The Reactive
Microservices Framework
Lagom design rests on the following principles:
● Message Driven and Asynchronous - Build upon Akka stream for
asynchronous streaming
● Distributed Persistence - Lagom favours distributed persistence patterns
using Event Sourcing with Command Query Responsibility Segreation. (CQRS)
● Developers Productivity - Starting all microservices with a single command,
code hot reloading and expensive service interface declarations are some
examples of Lagom’s high emphasis on developer productivity.
8. Lagom Framework - The Reactive
Microservices Framework
Lagom design rests on the following principles:
● Message Driven and Asynchronous - Build upon Akka stream for
asynchronous streaming
● Distributed Persistence - Lagom favours distributed persistence patterns
using Event Sourcing with Command Query Responsibility Segreation. (CQRS)
● Developers Productivity - Starting all microservices with a single command,
code hot reloading and expensive service interface declarations are some
examples of Lagom’s high emphasis on developer productivity.
9. CQRS and ES
Event Sourcing and CQRS (Command Query and Responsibility Segregation)
are fundamental concepts behind Lagom support for Services that store
information.
● Event Sourcing core principle is that each service should own its data and it is
only the services itself that should have direct access to the database. Other
services must use the Service API to interact with the data. There must be no
sharing of database across different services since that would result in tight
coupling.
● To achieve this, Lagom’s persistence module advocates the use of event
sourcing and CQRS.
10. Lagom Architecture
Lagom Architecture is divided into two parts -
● Service API ->
The Service API is defined as interface in project. It declares a set of methods that
represent the API for the service. It also declares a descriptor that exposes the
methods through HTTP endpoint.
● Service Implementation ->
The concrete class is created to implement the interface defined in the API
The class will provide an implementation for each of the methods defined the
service API.