Independent Consultant & Software Architect
Trainer, Speaker, Frontend & Backend
Bottega IT Minds, ArchitekturaNaFroncie.pl (ANF)
soon: Developer Jutra (.pl)
Warsaw, PL
cele architektury
technikalia
client-side composition
server-side composition
niuanse architektoniczne
jak zepsuć: nieudane wdrożenia
jak NIE zepsuć: udane wdrożenia
jak, co i po co mierzyć
NIE JESTEM SPRZEDAWCĄ TECHNOLOGII 😉
niezależność wdrożeń / awarii
skalowalność / wydajność
niezależność wdrożeń / awarii
i tyle... :)
Any organization that designs a system (defined broadly) will produce a design whose structure is a copy of the organization's communication structure.
- Melvin Conway
MicroServices and MicroFrontends are technical solutions to people problems.
- someone
Stream-aligned:
cele BIZNESOWE
ownership
autonomia
CZĘSTO ZMIENIAĆ/WDRAŻAĆ HOSTA
Strangler Pattern
Web Components
Webpack Module Federation
iFrames
Custom Frameworks
// (HOST)
new ModuleFederationPlugin({
name: "shell",
remotes: {
mfe1: "mfe1@http://host1/remoteEntry.js",
mfe2: "mfe2@http://host2/remoteEntry.js",
},
}),
// (REMOTE)
new ModuleFederationPlugin({
name: "mfe1",
filename: "remoteEntry.js",
exposes: {
"./MyComp": "./src/components/MyComp",
},
}),
// (HOST)
new ModuleFederationPlugin({
name: "shell",
remotes: {
mfe1: "mfe1@http://host1/remoteEntry.js",
mfe2: "mfe2@http://host2/remoteEntry.js",
},
}),
// (REMOTE)
new ModuleFederationPlugin({
name: "mfe1",
filename: "remoteEntry.js",
exposes: {
"./MyComp": "./src/components/MyComp",
},
}),
// (HOST)
new ModuleFederationPlugin({
name: "shell",
remotes: {
mfe1: "mfe1@http://host1/remoteEntry.js",
mfe2: "mfe2@http://host2/remoteEntry.js",
},
}),
// (REMOTE)
new ModuleFederationPlugin({
name: "mfe1",
filename: "remoteEntry.js",
exposes: {
"./MyComp": "./src/components/MyComp",
},
}),
// (HOST)
new ModuleFederationPlugin({
name: "shell",
remotes: {
mfe1: "mfe1@http://host1/remoteEntry.js",
mfe2: "mfe2@http://host2/remoteEntry.js",
},
}),
// (REMOTE)
new ModuleFederationPlugin({
name: "mfe1",
filename: "remoteEntry.js",
exposes: {
"./MyComp": "./src/components/MyComp",
},
}),
współdziel stan między mikrofrontendami
interface MessageBroker {
publish(topic, event): void;
subscribe(topic, subscribeFn): void;
unsubscribe(topic, subscribeFn): void;
}
stwórz ogromną bibliotekę komponentów
a czym jest w ogóle "biblioteka komponentów"?
🤔 Jak często WDRAŻASZ: bibliotekę komp. vs brokera?
współdziel ile się da, jak najwięcej!
często wdrażaj HOST APP
wydłuż pipeline, np. dużo granularnych pakietów
📦
📦
📦
📦
📦
📦
📦
📦
📦
📦
📦
📦