Slide 1

Slide 1 text

JS @ SPOTIFY FELIPE RIBEIRO | @FELIPERNB

Slide 2

Slide 2 text

SPOTIFY FOR DESKTOP IS A WEB-BASED APP

Slide 3

Slide 3 text

A BIT OF HISTORY…

Slide 4

Slide 4 text

No content

Slide 5

Slide 5 text

No content

Slide 6

Slide 6 text

No content

Slide 7

Slide 7 text

WEB VIEWS INSIDE THE CLIENT WITH CEF

Slide 8

Slide 8 text

No content

Slide 9

Slide 9 text

No content

Slide 10

Slide 10 text

No content

Slide 11

Slide 11 text

No content

Slide 12

Slide 12 text

WEB ALL THE THINGS!!1!

Slide 13

Slide 13 text

No content

Slide 14

Slide 14 text

TO REWRITE OR NOT TO REWRITE?

Slide 15

Slide 15 text

ENGINEERING THINKING

Slide 16

Slide 16 text

THE ARCHITECTURE

Slide 17

Slide 17 text

client-core client-desktop Chromium Embedded Framework JS Container Browse Search Radio Playlist

Slide 18

Slide 18 text

No content

Slide 19

Slide 19 text

DID YOU JUST SAY *IFRAMES*? !

Slide 20

Slide 20 text

THE CODEBASE

Slide 21

Slide 21 text

▸ one repository per app (playlist, browse, search, …) ▸ one repository per lib ▸ internal npm registry to publish and distribute the libs

Slide 22

Slide 22 text

NOPE !

Slide 23

Slide 23 text

WHY NOT?

Slide 24

Slide 24 text

HARD TO COORDINATE HORIZONTAL CHANGES

Slide 25

Slide 25 text

COMPLICATES CI, TESTABILITY AND STANDARDIZATION

Slide 26

Slide 26 text

dependencies: { "spotify-css": "~1.0.0", "spotify-uri": "~1.5.0" } dependencies: { "spotify-css": "~2.0.0", "spotify-uri": "~1.0.0" }

Slide 27

Slide 27 text

No content

Slide 28

Slide 28 text

One repo to rule them all — Git Sauron

Slide 29

Slide 29 text

MONOREPO !

Slide 30

Slide 30 text

▸ simplified CI ▸ easier to test the impact of changes ▸ free to break backwards compatibility ▸ atomic refactorings (and rollbacks) ▸ consistency and standardization

Slide 31

Slide 31 text

No content

Slide 32

Slide 32 text

things are simpler than before, but there’s still a lot of entropy

Slide 33

Slide 33 text

GOLDEN PATH

Slide 34

Slide 34 text

▸ standardization workgroup ▸ de-facto standards and path of least resistance ▸ data-driven decision making

Slide 35

Slide 35 text

LESSONS LEARNED

Slide 36

Slide 36 text

▸ evolve things incrementally ▸ no “ivory tower” infra team ▸ architecture shouldn't depend on repository organization ▸ consistency is paramount

Slide 37

Slide 37 text

spotify.com/jobs

Slide 38

Slide 38 text

THANKS @FELIPERNB