Top Banner
Fernand Galiana GraphQL New Black?
47

GraphQL The New Black?

Apr 14, 2017

Download

Technology

Fernand Galiana
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: GraphQL The New Black?

Fernand Galiana

GraphQL New Black?

Page 2: GraphQL The New Black?

imhotep.io @kitesurfer

CS 11

Page 3: GraphQL The New Black?

imhotep.io @kitesurfer

Page 4: GraphQL The New Black?

imhotep.io @kitesurfer

• RPC

• CORBA

• SOAP

• Beans

• JSONSchemas

• OData

• JSONAPI

• …

Page 5: GraphQL The New Black?

imhotep.io @kitesurfer

• REST

• Hypermedia

• Apiary

• Swagger

• …

Page 6: GraphQL The New Black?

imhotep.io @kitesurfer

grap

hQL

Page 7: GraphQL The New Black?

imhotep.io @kitesurfer

{ events { name year }

}

{ “events” { “name”: “Australian Open” “year” : 2017 }

}

Page 8: GraphQL The New Black?

imhotep.io @kitesurfer

• Thin Spec

• Consumer driven

• Self Docs

• What - !How

• Data Safety

• Incremental Adoption

• Transport Agnostic

• OnBoarding

• *REST Calls

• Over/Under fetch

Page 9: GraphQL The New Black?

imhotep.io @kitesurfer

big

deal

?

Page 10: GraphQL The New Black?

imhotep.io @kitesurfer

• Rich Clients

• Mo’ Data

• Savvier users

• Microservices

• Best of Bride Langs / Stores / Fmk

• Multi Devices / API Clients

• Mobile / Network Bandwidth

• Type all teh things!

Page 11: GraphQL The New Black?

imhotep.io @kitesurfer

2005

Page 12: GraphQL The New Black?

imhotep.io @kitesurfer

2017

Page 13: GraphQL The New Black?

2014

Page 14: GraphQL The New Black?

/api

Page 15: GraphQL The New Black?

2017

Page 16: GraphQL The New Black?

/graphql

Page 17: GraphQL The New Black?

imhotep.io @kitesurfer

Page 18: GraphQL The New Black?

imhotep.io @kitesurfer

arch

itectures

Page 19: GraphQL The New Black?

imhotep.io @kitesurfer

GraphQL

Page 20: GraphQL The New Black?

imhotep.io @kitesurfer

GraphQL

Svc1 Svc2 Svc3 Svc4

Page 21: GraphQL The New Black?

imhotep.io @kitesurfer

clos

er lo

ok

Page 22: GraphQL The New Black?

imhotep.io @kitesurfer

Query Mutation

oper

atio

ns

Page 23: GraphQL The New Black?

imhotep.io @kitesurfer

type

s

Page 24: GraphQL The New Black?

imhotep.io @kitesurfer

• String (!|[])

• ID

• Float

• Int

• Boolean

• Custom (Date)

• Enum

• Interface

• Unions (concrete types only!)

Page 25: GraphQL The New Black?

imhotep.io @kitesurfer

your

mis

sion

Page 26: GraphQL The New Black?

imhotep.io @kitesurfer

Page 27: GraphQL The New Black?

imhotep.io @kitesurfer

Rod Laver 6,4,6,3,6,2

ESP 32

SWI 35

Finals

Match

Rafael Nadal

Roger Federer

Aussie Open 2017 Draw

Page 28: GraphQL The New Black?

imhotep.io @kitesurfer

Rod Laver 6,4,6,3,6,2Finals

Match

ESP 32

Rafael Nadal

SWI 35

Aussie Open 2017 Draw

Quarter

Draw

Semis

DrawRoger Federer

Page 29: GraphQL The New Black?

imhotep.io @kitesurfer

Rod Laver 6,4,6,3,6,2

Quarter

Finals

Semis

Match

ESP 32

Rafael Nadal

SWI 35

Aussie Open 2017 Draw

Draw

DrawRoger Federer

Page 30: GraphQL The New Black?

imhotep.io @kitesurfer

Page 31: GraphQL The New Black?

Demo Sourcegithub.com/derailed/ao-demo

Page 32: GraphQL The New Black?

imhotep.io @kitesurfer

in a

ctio

n

Page 33: GraphQL The New Black?

EchoSystems

Page 34: GraphQL The New Black?

imhotep.io @kitesurfer

auth

[9,1

0]

Page 35: GraphQL The New Black?

imhotep.io @kitesurfer

Subscriptions

Herpes Test Results

Page 36: GraphQL The New Black?

imhotep.io @kitesurfer

cach

ing

Page 37: GraphQL The New Black?

imhotep.io @kitesurfer

batc

hing

Page 38: GraphQL The New Black?

imhotep.io @kitesurfer

• Throttle query calls for duration

• client side resolver (Relay)

Page 39: GraphQL The New Black?

imhotep.io @kitesurfer

pagi

natio

n

Page 40: GraphQL The New Black?

imhotep.io @kitesurfer

framew

orks

Page 41: GraphQL The New Black?

Relay

Page 42: GraphQL The New Black?
Page 43: GraphQL The New Black?

imhotep.io @kitesurfer

take

aw

ays

Page 44: GraphQL The New Black?

imhotep.io @kitesurfer

• Think graph!

• Baby steps

• Design for the future

• Name/Doc wisely

• Premature caching

• Forget polymorphism!

• Fragments reuse

• Track mutations

• Balance #calls vs payload

• QL Mocks

• Countermeasures for DDOS

• Client side still JSON - !Models

• Client/Server teams

• No breaking changes?

• Query tuning

• Null / Errors

• Relational Stores??

• Bigs schemas

• Monitoring /graphql?

Page 45: GraphQL The New Black?

imhotep.io @kitesurfer

refe

renc

es

Page 46: GraphQL The New Black?

imhotep.io @kitesurfer

• github.com/derailed/ao-demo

• graphql.org

• github.com/facebook/dataloader

• absinthe-graphql.org

• github.com/apollostack

• facebook.github.io/relay

• github.com/chentsulin/awesome-graphql

Page 47: GraphQL The New Black?

Thank you!

Photos provided by blackandwtf.tumblr.com