59
Have you tried turning it off and turning it on again? Tanya Reilly (@whereistanya)

Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

  • Upload
    others

  • View
    1

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Have you tried turning it off and turning it on again?

Tanya Reilly (@whereistanya)

Page 2: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Where are you in the stack?

CMS

MY SKILLZ RESUME

Page 3: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Where are you in the stack?

MY SKILLZ RESUME

CMS

Page 4: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Where are you in the stack?

MY SKILLZ RESUME

CMS

CMS ???

Page 5: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Where are you in the stack?

CMS!!

CMS ???

MY SKILLZ RESUME

Page 6: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

What is it?

Page 7: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Abstractions let us

specialise

Page 8: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

A slidedoc is a visual document, developed in presentation software, that is intended to be read and referenced instead of projected.

9

Page 9: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

● fallback plans● dependencies● what can we do?

Page 10: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Fallback plans

Page 11: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

12

backups

Of course! I copied it to

/tmp/database.bak

Backup_Backup_Backup_-_And_Test_Restores, T-Town Photo Booth CC BY 2.0Backup, Backup Backup and Test Restores, T-Town Photo Booth CC BY 2.0

Page 12: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

If you haven't tested your backups, you don't have backups.

Page 13: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

the identical(ish!) failover site

Take two, they’re small

Page 14: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

1. Is it real?

Page 15: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

2. Is it up to date?

Retro, Melinda Seckington CC BY 2.0

Page 16: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

3. Is the idea of actually using it kind of terrifying?

FreeImages.com/barun patro

Page 17: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Two sites? I’ve

forgotten how to

count that low

replicated everything

Page 18: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

● fallback plans● dependencies● what can we do?

Page 19: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

(Micro)services

Page 20: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

(Micro)services

Page 21: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Jenga Tower of 50 blocks, Johannes Bader CC BY 2.0

Page 22: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Everybody's backend is

someone else's frontend

Page 23: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

“ "A service cannot be more available than the intersection of all its critical

dependencies."

-- "The Calculus of Service Availability"Ben Treynor, Mike Dahlin, Vivek Rau, Betsy Beyer

Page 24: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Your stack… is really

more of a "pile", isn't

it?

dependency cycles

Page 25: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

uh...

control plane cycles

ŠJů CC BY 4.0

Page 26: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

27

Why would we ever

restart it?

machines that run

forever (until they don't)

Page 27: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

28

root@X1:/# haltConnection to x1 closed by remote host.

root@x3:/# haltConnection to x3 closed by remote host.$

root@x2:/# haltConnection to x2 closed by remote host.

root@x10000:/# haltConnection to x10000 closed by remote host$

Global simultaneous reboot (doesn’t usually look like this)

root@x10001:/# haltConnection to x10001 closed by remote host.$

Page 28: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 29: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 30: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 31: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 32: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 33: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 34: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 35: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 36: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 37: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

tick tick tick...

Page 38: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

● fallback plans● dependencies● what can we do?

Page 39: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

dependency discovery

We're built on top of... really? Are you sure?

It’s Turtles All The Way Down, William Warby. CC BY 2.0

Page 40: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Original design. "We keep an in-memory index of the available cats with some metadata about them. The cat chooser uses the information from the user's request to determine the attributes that needs to be fulfilled. It checks the index for cats that match those attributes. It pulls those cats from storage and returns one to the user.

Indexers run at startup and at intervals to update the metadata and make sure we have accurate cat sentiment analysis and geolocation data."

design docs obscure information

Page 41: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Original design. "We keep an in-memory index of the available cats with some metadata about them. The cat chooser uses the information from the user's request to determine the attributes that needs to be fulfilled. It checks the index for cats that match those attributes. It pulls those cats from storage and returns one to the user.

Indexers run at startup and at intervals to update the metadata and make sure we have accurate cat sentiment analysis and geolocation data."

User story: cat must be a cat. "Since catness analysis is an expensive operation, we only run the catness analyzer on pictures that have a high likelihood of being served, i.e., those aleady indexed with geolocation and sentiment data. We'll take the index from the cat chooser and run catness analysis over the cats from that queue."

design docs obscure information

Page 42: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

webserver -> cat_chooser

cat_chooser -> cat_geotagger

cat_chooser -> cat_sentiment_analyzer

cat_chooser -> catness_analyzer

cat_chooser -> storage

catness_analyzer -> cat_chooser

catness_analyzer -> storage

cat_geotagger -> storage

cat_sentiment_analyzer -> storage

lists are better

Page 43: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

digraph {

webserver -> cat_chooser

cat_chooser -> cat_geotagger

cat_chooser -> cat_sentiment_analyzer

cat_chooser -> catness_analyzer

cat_chooser -> storage

catness_analyzer -> cat_chooser

catness_analyzer -> storage

cat_geotagger -> storage

cat_sentiment_analyzer -> storage

}

pictures are even better

Page 44: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

digraph {

webserver -> cat_chooser

cat_chooser -> cat_geotagger

cat_chooser -> cat_sentiment_analyzer

cat_chooser -> catness_analyzer

cat_chooser -> storage

catness_analyzer -> cat_chooser

catness_analyzer -> storage

cat_geotagger -> storage

cat_sentiment_analyzer -> storage

}

pictures are even better $ /usr/bin/dot -T png -o cats.png cats.dot

Page 45: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

But don't put humans in charge of remembering what connects to what

Page 46: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

dependency policies

This is Site Reliability. THERE ARE

RULES.

Page 47: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Are you on the guest

list?

policy enforcement

Page 48: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

policy enforcement

Are you on the guest

list?

kind: NetworkPolicyapiVersion: networking.k8s.io/v1metadata: name: access-nginxspec: podSelector: matchLabels: run: nginx ingress: - from: - podSelector: matchLabels: access: "true"

Page 49: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

Manage your dependencies early

(It’s harder later on)Some sock yarn, Kara, CC BY-ND 2.0

Page 50: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

architecting in layers

Look, an actual stack!

Page 51: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

soft dependencies

Page 52: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

The appearance of U.S. Department of Defense (DoD) visual information does not imply or constitute DoD endorsement.

The reserve parachute is always packed by an expert

reliable fallback plans

Page 53: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

54

testing

Really, try turning it off and

turning it on again

Page 54: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

in conclusion...

Page 55: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

❏ small fallback plans

❏ test everything ❏ manage

dependencies❏ architect in

layers

fallback plans:

small, simple, solid

Page 56: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

if it's not tested, assume it doesn't work

❏ small fallback plans

❏ test everything ❏ manage

dependencies❏ architect in

layers

if it's not tested, assume it doesn't work

Page 57: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

manage your dependencies before you need to

❏ small fallback plans

❏ test everything ❏ manage

dependencies❏ architect in

layers

Page 58: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

❏ small fallback plans

❏ test everything ❏ manage

dependencies❏ architect in

layers dependencies go down the stack

Page 59: Have you tried turning it off and turning it on again? · RESUME. What is it? Abstractions let us specialise. A slidedoc is a visual document, developed in presentation software,

hope is not a strategy

@whereistanya https://github.com/whereistanya/graphviz/ Presentation template by

slidescarnival.com