Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business...

17
Podium

Transcript of Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business...

Page 1: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Podium

Page 2: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Breaking the monolith with microservices!

μs μs μs

Frontend

Business logic

Data access layer

frontend

μs

μs

Monolith architecture Microservice “real world”?

μs μs μs

fe

Microservice “ideal world”?

fefe fe

Page 3: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Why microservices?

● Isolation● Independent● Autonomous● Evolutionary● Standard driven

● Complexity● Overhead● “The death star”

Advantages Drawbacks

Page 4: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

«frontend»

Page 5: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Owned by a single team

A fragment of a page

Business component- Data requirements- (not a generic UI widget)

What is a «component»?

Page 6: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Re-composable and it just works!

Page 7: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Podium parts

Asset ServiceLayout server

podlet

contract

Page 8: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Podlet

“A business feature”

A fragment of a page

Enables full-stack ownership of features

Page 9: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Layout Server

The user-facing webapp

Responsibilities:- Fetch content from podlets- Error-handling- Rendering a page- Proxy for podlets

Page 10: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Asset service

Responsibilities:- Build frontend dependencies- Monitor dependency usage

Page 11: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Frontend platform

Backend platform

Assets service Layout service(finn.no)

Domain service

Podlet Podlet

Domain service

Domain service

Domain service

Podlet

Layout service(xyz.com)

CDN

1. 2.

3.

Page 12: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Contract based

{ name: "my-podlet", version: "1.0.0", content: "/content", fallback: "/fallback", assets: { js: "def53.json", css:"ee212.json" }}

manifest.json

JSON Web TokenLocaleDevice TypeResource Mount Point

Podlet options- Static- Runtime (adId)

Context

?Browser API

Page 13: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Why?

More efficient development- Standardize common challenges

- Team should focus on delivering awesome business features

Isolation- Clear boundaries; Autonomous

- Easier to work on concrete features

- More robust

No “off the shelf” solutions- Secret sauce of larger sites

- Evolutionary

Page 14: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

prototype.js Angular.js Vue.js React.js

Front-End technologies changes over time

Page 15: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Evolutionary Frontend Tech Strategy

React React React React React React Spring

React React React React

Next 2 React

Next Next Next

Next Next Next Next Next Next React

Next Next Next Next Next

2018

2020

2022

2024Rewrite Web Platform

frontend unchanged

When new frontend technology is needed, we are able to introduce it gradually - one component at a time,

with no complete rewrites needed!

FrontendEvolution

Page 16: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Architecture direction

/Reise/Search /Småjobber/Front-Page /Object-page /Min-finn

Shared look & feel

Shared UI Components

/...

Shared tools

Webapp owned by Platform WEB Team

Teams owns Podlets

Webapp owned by domain teams

Follow guidelines and use standardized platform components (spaden, tools, ui components)

Page 17: Podium...2018/02/06  · Breaking the monolith with microservices! μs μs μs Frontend Business logic Data access layer frontend μs μs Monolith architecture Microservice “real

Demo Time!

Words words words. Show me the real deal!