SlideShare a Scribd company logo
1 of 83
Craig Ulliott
  likes building things
About me
About me

•   Needs to know how everything works
About me

•   Needs to know how everything works

•   Likes things that scale
About me

•   Needs to know how everything works

•   Likes things that scale

•   Think’s almost everything is inefficient
About me

•   Needs to know how everything works

•   Likes things that scale

•   Think’s almost everything is inefficient

•   Hates people
About me

•   Needs to know how everything works

•   Likes things that scale

•   Think’s almost everything is inefficient

•   Hates people

    •   Just kidding
About me

•   Needs to know how everything works

•   Likes things that scale

•   Think’s almost everything is inefficient

•   Hates people

    •   Just kidding

        •   But people are the cause of all the worlds inefficiencies
About me

•   Needs to know how everything works

•   Likes things that scale

•   Think’s almost everything is inefficient

•   Hates people

    •   Just kidding

        •   But people are the cause of all the worlds inefficiencies


What I do and have done:
Mistakes I’ve Made
Mistakes I’ve Made

Lessons I’ve Learned.
Minimum Viable Product
Minimum Viable Product



• Short sprints (release code regularly)
Minimum Viable Product



• Short sprints (release code regularly)
• Spend an hour thinking about why you’re
  building something, before you spend a
  week thinking about how.
Minimum Viable Product



• Short sprints (release code regularly)
• Spend an hour thinking about why you’re
  building something, before you spend a
  week thinking about how.
• Your developing a business not a website
Surround yourself with business people
Surround yourself with business people



•   If you have a good idea, a strong technical co-
    founder and a business co-founder
    - you will get money / incubated / successful
Surround yourself with business people



•   If you have a good idea, a strong technical co-
    founder and a business co-founder
    - you will get money / incubated / successful

•   I get asked every 3 days if I know any developers
    - why are you guys not meeting each other!
Bootstrap if you can
Bootstrap if you can



•   BUSINESSES that work when they are small are
    easier to scale
Bootstrap if you can



•   BUSINESSES that work when they are small are
    easier to scale

•   The first step to becoming an Entrepreneur is not
    quitting your job
Bootstrap if you can



•   BUSINESSES that work when they are small are
    easier to scale

•   The first step to becoming an Entrepreneur is not
    quitting your job

•   You wont be pragmatic if your worried about
    rent / children / debt / x / y / z
Bootstrap if you can



•   BUSINESSES that work when they are small are
    easier to scale

•   The first step to becoming an Entrepreneur is not
    quitting your job

•   You wont be pragmatic if your worried about
    rent / children / debt / x / y / z

•   Its also a great lesson in finances
Don’t be afraid to share your idea


•   “But someone might steal it.”

•   The hardest thing you will do is going to be getting
    someone genuinely interested in your idea.

•   People that could actually execute your idea are
    too busy with their own ideas.

•   It’s a lot cheaper for someone to take a bet (put all
    the risk) on you, than try and do it themselves.
Fail quickly and fail often
Fail quickly and fail often

one in seven businesses make it...
Fail quickly and fail often

one in seven businesses make it...
               ...so start seven businesses!
WIB APIs in 2009
Some problem’s

•   WIB was completely dependent on lots of
    different social networks

    •   They break and change stuff

    •   Our code becomes complicated (entropy)

•   WIB had a small team

    •   And lots of stuff to do

•   WIB had a lot of members

    •   half a billion db rows & 7000+ queries a second
What is abstraction
a web application is like an onion
The Solution:
       “Network Abstraction Layer”


•   Wrapped Facebook, Myspace, Bebo, Hi5,
    Friendster and Orkut

•   Normalized the I/O

•   Absorbed changes where they happen

•   Handled breakages

•   Data sharing across the whole network
    - Facebook user can see a MySpace user
and it’s really extensible




• We can add functionality and data without
  breaking the other networks
• We can add other networks very easily
It’s also nice and scalable (for a team)



• An API has a defined protocol, so
  developers on our team could work side by
  side on the different networks.
• As long as I/O stays the same, they can
  work independently
And it scales well technically



• Dividing an application into layers makes it
  much easier to scale.
• Mainly because the independent layers can
  be scaled (or re-written) independently,
  without breaking other components.
WIB APIs in 2011
WIB APIs in 2011
WIB Today

                           Where I’ve Been . com



                                             The website does not
                                            connect directly to the
                                                  database
 Facebook

  Twitter
                           WIB oAuth 2 REST API
Foursquare

And others...
                Database         Database          Database
Advantages of a single API


•   Saves Time (money) and it’s Extensible (future proof)


•   Teams can work on their own platforms

    •   Website, iPhone, Android, Facebook App et.al.


•   Federate out content (or build developer network)
How to build an API
(an opinionated approach)
how to build stuff in general
how to build stuff in general



• Developers cost
how to build stuff in general



• Developers cost


• Servers cost
Use Ruby on Rails
Use Ruby on Rails

• It allows you to build reliable, powerful,
  readable code
Use Ruby on Rails

• It allows you to build reliable, powerful,
  readable code
• With RoR you can build a business in a
  week and host it for free
Use Ruby on Rails

• It allows you to build reliable, powerful,
  readable code
• With RoR you can build a business in a
  week and host it for free




               Even monkeys use tools!
Why Ruby on Rails is good for an API
Why Ruby on Rails is good for an API
        Especially if you’re a startup
Why Ruby on Rails is good for an API
              Especially if you’re a startup

•   RESTful out of the box
Why Ruby on Rails is good for an API
              Especially if you’re a startup

•   RESTful out of the box

•   Normalized data
Why Ruby on Rails is good for an API
               Especially if you’re a startup

•   RESTful out of the box

•   Normalized data

    •   Encourages powerful abstraction
Why Ruby on Rails is good for an API
               Especially if you’re a startup

•   RESTful out of the box

•   Normalized data

    •   Encourages powerful abstraction

•   It’s easy and quick to develop
Why Ruby on Rails is good for an API
               Especially if you’re a startup

•   RESTful out of the box

•   Normalized data

    •   Encourages powerful abstraction

•   It’s easy and quick to develop

•   Its easy to write tests
Why Ruby on Rails is good for an API
               Especially if you’re a startup

•   RESTful out of the box

•   Normalized data

    •   Encourages powerful abstraction

•   It’s easy and quick to develop

•   Its easy to write tests

•   Scales horizontally (until you’ve already “made it”)
    - the bottleneck will be your DB
RESTful web service


•   REST is how the web already works
    (makes it a pretty well known standard)

•   URL’s are self explanatory (easy to work with)

•   Closely matches the underlying data/objects

    •   Makes it easy to build in a DRY way

    •   Developers can get started very quickly
HTTP methods



•   POST : Create something new

•   GET : Retrieve something that already exists

•   PUT : Update something that already exists

•   DELETE : Remove something that already exists
Authorization and Authentication



• Authentication
 • Who is this
• Authorization
 • Can the Authenticated entity access this
    resource
oAuth1 vs oAuth2


• oAuth 2 is slightly less secure
• But it makes everyone’s lives SO much
  easier
• Build a “trusted” clients paradigm for
  internal use
  - login, register, reset password etc
HTTP Request

       Authentication
                                   Web server



                                   Framework




                                  Authentication
It makes things really easy for
         developers
                                  Authorization
lots of libraries and examples
              exist

                                  API Controller
Access Tokens

•   Different tokens for user+client and client


•   Store useful info in them, allows you to
    calculate on the fly instead of store in the db



        c1234-g7rCEVB867rbe4B-1234567
Access Tokens

•   Different tokens for user+client and client


•   Store useful info in them, allows you to
    calculate on the fly instead of store in the db



        c1234-g7rCEVB867rbe4B-1234567

        client_id = 12345
Access Tokens

•   Different tokens for user+client and client


•   Store useful info in them, allows you to
    calculate on the fly instead of store in the db



        c1234-g7rCEVB867rbe4B-1234567

                                   user_id = 1234576
Access Tokens

•   Different tokens for user+client and client


•   Store useful info in them, allows you to
    calculate on the fly instead of store in the db



        c1234-g7rCEVB867rbe4B-1234567

                  hash(client_secret+user_id)
Access Tokens

•   Different tokens for user+client and client


•   Store useful info in them, allows you to
    calculate on the fly instead of store in the db



        c1234-g7rCEVB867rbe4B-1234567
SSL


iPhone
           WiFi    laptop running squid           internet




 •   Require it, otherwise developers will expose all
     sort of stuff (like keys)

 •   Important if you want to be taken seriously by
     developer community
SSL


iPhone
           WiFi     laptop running squid           internet


               looking at all the traffic is easy



 •   Require it, otherwise developers will expose all
     sort of stuff (like keys)

 •   Important if you want to be taken seriously by
     developer community
Standardized Errors


• Assume success=true
• Always send back errors in the same way,
  so client libraries can be smart

    {
        "error": {
           "type": "ObjectException",
           "message": "Object does not exist"
        }
    }
Limit how much data gets send back

• Mobile developers care a lot about this
• allow customizations:
  fields=name,gender
DRY Definitions
HTTP Request
                           Logging

Errors:                                                  Web server
  •       GetExceptional
          $20 a month (whats your time worth?)

Performance:                                             Framework
  •       New Relic

API Requests

  •       Something simple near the top of your stack      Logging
          (remember, storage is cheap)



                                                        API Controller
GetExceptional
GetExceptional - Backtraces
New Relic
New Relic
Roll your own
Roll your own
JSON



•   It’s smaller than XML

•   Developers write bad xml parsers, that rely on the
    order of the XML nodes

•   Facebook use it, and they set the standard
    - you want your API to be sexy don’t you?
Returning Data

• Standarized
  - objects
  - arrays of objects
  - nested objects
Standardize object output
DRY Documentation never goes out of date




• Build it off the
  - models
  - connections
  - methods
Testing



• Write tests on your API
 • Even if you hate tests
   • It’s easy
    • You can generate most of them just
       like the documentation
Tie it all together


•   A good API is a series of simple layers

•   Keep it DRY

    •   Use the data structure for more dynamic code

•   Standards are your friend

•   There are plenty of examples out there
    - Facebook, Foursquare, Twitter etc
Thanks




• Hope this was useful

More Related Content

What's hot

Untangling the web week 2 - SEO
Untangling the web week 2 - SEOUntangling the web week 2 - SEO
Untangling the web week 2 - SEODerek Jacoby
 
Funtional Ruby - Mikhail Bortnyk
Funtional Ruby - Mikhail BortnykFuntional Ruby - Mikhail Bortnyk
Funtional Ruby - Mikhail BortnykRuby Meditation
 
Triple your blog post frequency
Triple your blog post frequencyTriple your blog post frequency
Triple your blog post frequencyAndraz Tori
 
Achieving Beautiful Typography in eBooks
Achieving Beautiful Typography in eBooksAchieving Beautiful Typography in eBooks
Achieving Beautiful Typography in eBooksdigitalbindery
 
Surviving a Hackathon and Beyond
Surviving a Hackathon and BeyondSurviving a Hackathon and Beyond
Surviving a Hackathon and Beyondimoneytech
 
Untangling spring week2
Untangling spring week2Untangling spring week2
Untangling spring week2Derek Jacoby
 
Html5 web sockets - Brad Drysdale - London Web 2011-10-20
Html5 web sockets - Brad Drysdale - London Web 2011-10-20Html5 web sockets - Brad Drysdale - London Web 2011-10-20
Html5 web sockets - Brad Drysdale - London Web 2011-10-20Nathan O'Hanlon
 
Write a better FM
Write a better FMWrite a better FM
Write a better FMRich Bowen
 
Killer Docs for Killer Devs
Killer Docs for Killer DevsKiller Docs for Killer Devs
Killer Docs for Killer Devsspmckeown
 
Triple Your Post Frequency
Triple Your Post FrequencyTriple Your Post Frequency
Triple Your Post FrequencyZemanta
 
WordPress Rest API
WordPress Rest APIWordPress Rest API
WordPress Rest APIBrian Layman
 
11 Amazing things I Learnt At Word Camp Sydney 2014
11 Amazing things I Learnt At Word Camp Sydney 201411 Amazing things I Learnt At Word Camp Sydney 2014
11 Amazing things I Learnt At Word Camp Sydney 2014WordPressBrisbane
 
CPL12-Agile-planning
CPL12-Agile-planningCPL12-Agile-planning
CPL12-Agile-planningAmir Barylko
 
Write A Better FM - Ohio Linux 2011
Write A Better FM - Ohio Linux 2011Write A Better FM - Ohio Linux 2011
Write A Better FM - Ohio Linux 2011Rich Bowen
 
How to Increase Community Online
How to Increase Community OnlineHow to Increase Community Online
How to Increase Community OnlineNathan O'Hanlon
 
Rethinking Scala Presented in San Francisco May 7, 2014
Rethinking Scala Presented in San Francisco May 7, 2014Rethinking Scala Presented in San Francisco May 7, 2014
Rethinking Scala Presented in San Francisco May 7, 2014Bruce Eckel
 
SEO Horror Stories
SEO Horror StoriesSEO Horror Stories
SEO Horror Storiespointit
 
Using HipChat For Real Time Communication in Social Media - Thad West
Using HipChat For Real Time Communication in Social Media - Thad WestUsing HipChat For Real Time Communication in Social Media - Thad West
Using HipChat For Real Time Communication in Social Media - Thad WestAtlassian
 

What's hot (20)

Untangling the web week 2 - SEO
Untangling the web week 2 - SEOUntangling the web week 2 - SEO
Untangling the web week 2 - SEO
 
Funtional Ruby - Mikhail Bortnyk
Funtional Ruby - Mikhail BortnykFuntional Ruby - Mikhail Bortnyk
Funtional Ruby - Mikhail Bortnyk
 
Triple your blog post frequency
Triple your blog post frequencyTriple your blog post frequency
Triple your blog post frequency
 
Achieving Beautiful Typography in eBooks
Achieving Beautiful Typography in eBooksAchieving Beautiful Typography in eBooks
Achieving Beautiful Typography in eBooks
 
Surviving a Hackathon and Beyond
Surviving a Hackathon and BeyondSurviving a Hackathon and Beyond
Surviving a Hackathon and Beyond
 
MWUG wp-myths
MWUG wp-mythsMWUG wp-myths
MWUG wp-myths
 
Untangling spring week2
Untangling spring week2Untangling spring week2
Untangling spring week2
 
Html5 web sockets - Brad Drysdale - London Web 2011-10-20
Html5 web sockets - Brad Drysdale - London Web 2011-10-20Html5 web sockets - Brad Drysdale - London Web 2011-10-20
Html5 web sockets - Brad Drysdale - London Web 2011-10-20
 
Write a better FM
Write a better FMWrite a better FM
Write a better FM
 
Killer Docs for Killer Devs
Killer Docs for Killer DevsKiller Docs for Killer Devs
Killer Docs for Killer Devs
 
Triple Your Post Frequency
Triple Your Post FrequencyTriple Your Post Frequency
Triple Your Post Frequency
 
WordPress Rest API
WordPress Rest APIWordPress Rest API
WordPress Rest API
 
11 Amazing things I Learnt At Word Camp Sydney 2014
11 Amazing things I Learnt At Word Camp Sydney 201411 Amazing things I Learnt At Word Camp Sydney 2014
11 Amazing things I Learnt At Word Camp Sydney 2014
 
Blogging
BloggingBlogging
Blogging
 
CPL12-Agile-planning
CPL12-Agile-planningCPL12-Agile-planning
CPL12-Agile-planning
 
Write A Better FM - Ohio Linux 2011
Write A Better FM - Ohio Linux 2011Write A Better FM - Ohio Linux 2011
Write A Better FM - Ohio Linux 2011
 
How to Increase Community Online
How to Increase Community OnlineHow to Increase Community Online
How to Increase Community Online
 
Rethinking Scala Presented in San Francisco May 7, 2014
Rethinking Scala Presented in San Francisco May 7, 2014Rethinking Scala Presented in San Francisco May 7, 2014
Rethinking Scala Presented in San Francisco May 7, 2014
 
SEO Horror Stories
SEO Horror StoriesSEO Horror Stories
SEO Horror Stories
 
Using HipChat For Real Time Communication in Social Media - Thad West
Using HipChat For Real Time Communication in Social Media - Thad WestUsing HipChat For Real Time Communication in Social Media - Thad West
Using HipChat For Real Time Communication in Social Media - Thad West
 

Viewers also liked

Technology Instuction
Technology InstuctionTechnology Instuction
Technology Instuctioncynthia5000
 
Art Of Liu Mao Shan現代感的國畫
Art Of Liu Mao Shan現代感的國畫Art Of Liu Mao Shan現代感的國畫
Art Of Liu Mao Shan現代感的國畫yu3495
 
Blaireail
BlaireailBlaireail
Blaireailjpurdy
 
Henryail
HenryailHenryail
Henryailjpurdy
 
The Farmers Robert Duncan Ari
The Farmers Robert Duncan AriThe Farmers Robert Duncan Ari
The Farmers Robert Duncan Arikatehsieh
 
Mirandanet Seminar 22nd September 2009
Mirandanet Seminar   22nd September 2009Mirandanet Seminar   22nd September 2009
Mirandanet Seminar 22nd September 2009guest7c46c5b
 
Integrating Tech Ppt
Integrating Tech PptIntegrating Tech Ppt
Integrating Tech Pptcynthia5000
 
Skateboardingail
SkateboardingailSkateboardingail
Skateboardingailjpurdy
 
Presentation made at Devoxx'09
Presentation made at Devoxx'09Presentation made at Devoxx'09
Presentation made at Devoxx'09Usi4Biz
 

Viewers also liked (9)

Technology Instuction
Technology InstuctionTechnology Instuction
Technology Instuction
 
Art Of Liu Mao Shan現代感的國畫
Art Of Liu Mao Shan現代感的國畫Art Of Liu Mao Shan現代感的國畫
Art Of Liu Mao Shan現代感的國畫
 
Blaireail
BlaireailBlaireail
Blaireail
 
Henryail
HenryailHenryail
Henryail
 
The Farmers Robert Duncan Ari
The Farmers Robert Duncan AriThe Farmers Robert Duncan Ari
The Farmers Robert Duncan Ari
 
Mirandanet Seminar 22nd September 2009
Mirandanet Seminar   22nd September 2009Mirandanet Seminar   22nd September 2009
Mirandanet Seminar 22nd September 2009
 
Integrating Tech Ppt
Integrating Tech PptIntegrating Tech Ppt
Integrating Tech Ppt
 
Skateboardingail
SkateboardingailSkateboardingail
Skateboardingail
 
Presentation made at Devoxx'09
Presentation made at Devoxx'09Presentation made at Devoxx'09
Presentation made at Devoxx'09
 

Similar to Craig Ulliott's Guide to Building Things

Serverless Toronto helps Startups
Serverless Toronto helps StartupsServerless Toronto helps Startups
Serverless Toronto helps StartupsDaniel Zivkovic
 
Seven Jobs You Should Be Running #sqlsat126
Seven Jobs You Should Be Running #sqlsat126Seven Jobs You Should Be Running #sqlsat126
Seven Jobs You Should Be Running #sqlsat126Mike Hillwig
 
Inside Wordnik's Architecture
Inside Wordnik's ArchitectureInside Wordnik's Architecture
Inside Wordnik's ArchitectureTony Tam
 
The business case for contributing code
The business case for contributing codeThe business case for contributing code
The business case for contributing codeZivtech, LLC
 
Velocity Conference NYC 2014 - Real World DevOps
Velocity Conference NYC 2014 - Real World DevOpsVelocity Conference NYC 2014 - Real World DevOps
Velocity Conference NYC 2014 - Real World DevOpsRodrigo Campos
 
6 reasons Jubilee could be a Rubyist's new best friend
6 reasons Jubilee could be a Rubyist's new best friend6 reasons Jubilee could be a Rubyist's new best friend
6 reasons Jubilee could be a Rubyist's new best friendForrest Chang
 
Lean Startup with WebObjects
Lean Startup with WebObjectsLean Startup with WebObjects
Lean Startup with WebObjectsWO Community
 
Community and Github: 7/27/2011
Community and Github: 7/27/2011Community and Github: 7/27/2011
Community and Github: 7/27/2011Andy Lester
 
Scaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHPScaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHP120bi
 
Scaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsScaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsAchievers Tech
 
Scaling with swagger
Scaling with swaggerScaling with swagger
Scaling with swaggerTony Tam
 
Surviving in a Microservices environment -abridged
Surviving in a Microservices environment -abridgedSurviving in a Microservices environment -abridged
Surviving in a Microservices environment -abridgedSteve Pember
 
Austin NoSQL 2011-07-06
Austin NoSQL 2011-07-06Austin NoSQL 2011-07-06
Austin NoSQL 2011-07-06jimbojsb
 
DevDay 2013 - Building Startups and Minimum Viable Products
DevDay 2013 - Building Startups and Minimum Viable ProductsDevDay 2013 - Building Startups and Minimum Viable Products
DevDay 2013 - Building Startups and Minimum Viable ProductsBen Hall
 
Build your own analytics power tools
Build your own analytics power toolsBuild your own analytics power tools
Build your own analytics power toolsAlban Gérôme
 
Devconf 2011 - PHP - How Yii framework is developed
Devconf 2011 - PHP - How Yii framework is developedDevconf 2011 - PHP - How Yii framework is developed
Devconf 2011 - PHP - How Yii framework is developedAlexander Makarov
 
SharePoint Saturday Utah - The Art of the Possible Keynote
SharePoint Saturday Utah - The Art of the Possible KeynoteSharePoint Saturday Utah - The Art of the Possible Keynote
SharePoint Saturday Utah - The Art of the Possible KeynoteLiam Cleary [MVP]
 
Enabling your DevOps culture with AWS-webinar
Enabling your DevOps culture with AWS-webinarEnabling your DevOps culture with AWS-webinar
Enabling your DevOps culture with AWS-webinarAaron Walker
 

Similar to Craig Ulliott's Guide to Building Things (20)

Serverless Toronto helps Startups
Serverless Toronto helps StartupsServerless Toronto helps Startups
Serverless Toronto helps Startups
 
Seven Jobs You Should Be Running #sqlsat126
Seven Jobs You Should Be Running #sqlsat126Seven Jobs You Should Be Running #sqlsat126
Seven Jobs You Should Be Running #sqlsat126
 
Inside Wordnik's Architecture
Inside Wordnik's ArchitectureInside Wordnik's Architecture
Inside Wordnik's Architecture
 
The business case for contributing code
The business case for contributing codeThe business case for contributing code
The business case for contributing code
 
Velocity Conference NYC 2014 - Real World DevOps
Velocity Conference NYC 2014 - Real World DevOpsVelocity Conference NYC 2014 - Real World DevOps
Velocity Conference NYC 2014 - Real World DevOps
 
6 reasons Jubilee could be a Rubyist's new best friend
6 reasons Jubilee could be a Rubyist's new best friend6 reasons Jubilee could be a Rubyist's new best friend
6 reasons Jubilee could be a Rubyist's new best friend
 
JSON all the way
JSON all the wayJSON all the way
JSON all the way
 
Lean Startup with WebObjects
Lean Startup with WebObjectsLean Startup with WebObjects
Lean Startup with WebObjects
 
Community and Github: 7/27/2011
Community and Github: 7/27/2011Community and Github: 7/27/2011
Community and Github: 7/27/2011
 
Scaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHPScaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHP
 
Scaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsScaling High Traffic Web Applications
Scaling High Traffic Web Applications
 
Wp 3hr-course
Wp 3hr-courseWp 3hr-course
Wp 3hr-course
 
Scaling with swagger
Scaling with swaggerScaling with swagger
Scaling with swagger
 
Surviving in a Microservices environment -abridged
Surviving in a Microservices environment -abridgedSurviving in a Microservices environment -abridged
Surviving in a Microservices environment -abridged
 
Austin NoSQL 2011-07-06
Austin NoSQL 2011-07-06Austin NoSQL 2011-07-06
Austin NoSQL 2011-07-06
 
DevDay 2013 - Building Startups and Minimum Viable Products
DevDay 2013 - Building Startups and Minimum Viable ProductsDevDay 2013 - Building Startups and Minimum Viable Products
DevDay 2013 - Building Startups and Minimum Viable Products
 
Build your own analytics power tools
Build your own analytics power toolsBuild your own analytics power tools
Build your own analytics power tools
 
Devconf 2011 - PHP - How Yii framework is developed
Devconf 2011 - PHP - How Yii framework is developedDevconf 2011 - PHP - How Yii framework is developed
Devconf 2011 - PHP - How Yii framework is developed
 
SharePoint Saturday Utah - The Art of the Possible Keynote
SharePoint Saturday Utah - The Art of the Possible KeynoteSharePoint Saturday Utah - The Art of the Possible Keynote
SharePoint Saturday Utah - The Art of the Possible Keynote
 
Enabling your DevOps culture with AWS-webinar
Enabling your DevOps culture with AWS-webinarEnabling your DevOps culture with AWS-webinar
Enabling your DevOps culture with AWS-webinar
 

Recently uploaded

Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfPrecisely
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxBkGupta21
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 

Recently uploaded (20)

Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptx
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 

Craig Ulliott's Guide to Building Things

  • 1. Craig Ulliott likes building things
  • 3. About me • Needs to know how everything works
  • 4. About me • Needs to know how everything works • Likes things that scale
  • 5. About me • Needs to know how everything works • Likes things that scale • Think’s almost everything is inefficient
  • 6. About me • Needs to know how everything works • Likes things that scale • Think’s almost everything is inefficient • Hates people
  • 7. About me • Needs to know how everything works • Likes things that scale • Think’s almost everything is inefficient • Hates people • Just kidding
  • 8. About me • Needs to know how everything works • Likes things that scale • Think’s almost everything is inefficient • Hates people • Just kidding • But people are the cause of all the worlds inefficiencies
  • 9. About me • Needs to know how everything works • Likes things that scale • Think’s almost everything is inefficient • Hates people • Just kidding • But people are the cause of all the worlds inefficiencies What I do and have done:
  • 11. Mistakes I’ve Made Lessons I’ve Learned.
  • 13. Minimum Viable Product • Short sprints (release code regularly)
  • 14. Minimum Viable Product • Short sprints (release code regularly) • Spend an hour thinking about why you’re building something, before you spend a week thinking about how.
  • 15. Minimum Viable Product • Short sprints (release code regularly) • Spend an hour thinking about why you’re building something, before you spend a week thinking about how. • Your developing a business not a website
  • 16. Surround yourself with business people
  • 17. Surround yourself with business people • If you have a good idea, a strong technical co- founder and a business co-founder - you will get money / incubated / successful
  • 18. Surround yourself with business people • If you have a good idea, a strong technical co- founder and a business co-founder - you will get money / incubated / successful • I get asked every 3 days if I know any developers - why are you guys not meeting each other!
  • 20. Bootstrap if you can • BUSINESSES that work when they are small are easier to scale
  • 21. Bootstrap if you can • BUSINESSES that work when they are small are easier to scale • The first step to becoming an Entrepreneur is not quitting your job
  • 22. Bootstrap if you can • BUSINESSES that work when they are small are easier to scale • The first step to becoming an Entrepreneur is not quitting your job • You wont be pragmatic if your worried about rent / children / debt / x / y / z
  • 23. Bootstrap if you can • BUSINESSES that work when they are small are easier to scale • The first step to becoming an Entrepreneur is not quitting your job • You wont be pragmatic if your worried about rent / children / debt / x / y / z • Its also a great lesson in finances
  • 24. Don’t be afraid to share your idea • “But someone might steal it.” • The hardest thing you will do is going to be getting someone genuinely interested in your idea. • People that could actually execute your idea are too busy with their own ideas. • It’s a lot cheaper for someone to take a bet (put all the risk) on you, than try and do it themselves.
  • 25. Fail quickly and fail often
  • 26. Fail quickly and fail often one in seven businesses make it...
  • 27. Fail quickly and fail often one in seven businesses make it... ...so start seven businesses!
  • 28. WIB APIs in 2009
  • 29. Some problem’s • WIB was completely dependent on lots of different social networks • They break and change stuff • Our code becomes complicated (entropy) • WIB had a small team • And lots of stuff to do • WIB had a lot of members • half a billion db rows & 7000+ queries a second
  • 30. What is abstraction a web application is like an onion
  • 31. The Solution: “Network Abstraction Layer” • Wrapped Facebook, Myspace, Bebo, Hi5, Friendster and Orkut • Normalized the I/O • Absorbed changes where they happen • Handled breakages • Data sharing across the whole network - Facebook user can see a MySpace user
  • 32. and it’s really extensible • We can add functionality and data without breaking the other networks • We can add other networks very easily
  • 33. It’s also nice and scalable (for a team) • An API has a defined protocol, so developers on our team could work side by side on the different networks. • As long as I/O stays the same, they can work independently
  • 34. And it scales well technically • Dividing an application into layers makes it much easier to scale. • Mainly because the independent layers can be scaled (or re-written) independently, without breaking other components.
  • 35. WIB APIs in 2011
  • 36. WIB APIs in 2011
  • 37. WIB Today Where I’ve Been . com The website does not connect directly to the database Facebook Twitter WIB oAuth 2 REST API Foursquare And others... Database Database Database
  • 38. Advantages of a single API • Saves Time (money) and it’s Extensible (future proof) • Teams can work on their own platforms • Website, iPhone, Android, Facebook App et.al. • Federate out content (or build developer network)
  • 39. How to build an API (an opinionated approach)
  • 40. how to build stuff in general
  • 41. how to build stuff in general • Developers cost
  • 42. how to build stuff in general • Developers cost • Servers cost
  • 43. Use Ruby on Rails
  • 44. Use Ruby on Rails • It allows you to build reliable, powerful, readable code
  • 45. Use Ruby on Rails • It allows you to build reliable, powerful, readable code • With RoR you can build a business in a week and host it for free
  • 46. Use Ruby on Rails • It allows you to build reliable, powerful, readable code • With RoR you can build a business in a week and host it for free Even monkeys use tools!
  • 47. Why Ruby on Rails is good for an API
  • 48. Why Ruby on Rails is good for an API Especially if you’re a startup
  • 49. Why Ruby on Rails is good for an API Especially if you’re a startup • RESTful out of the box
  • 50. Why Ruby on Rails is good for an API Especially if you’re a startup • RESTful out of the box • Normalized data
  • 51. Why Ruby on Rails is good for an API Especially if you’re a startup • RESTful out of the box • Normalized data • Encourages powerful abstraction
  • 52. Why Ruby on Rails is good for an API Especially if you’re a startup • RESTful out of the box • Normalized data • Encourages powerful abstraction • It’s easy and quick to develop
  • 53. Why Ruby on Rails is good for an API Especially if you’re a startup • RESTful out of the box • Normalized data • Encourages powerful abstraction • It’s easy and quick to develop • Its easy to write tests
  • 54. Why Ruby on Rails is good for an API Especially if you’re a startup • RESTful out of the box • Normalized data • Encourages powerful abstraction • It’s easy and quick to develop • Its easy to write tests • Scales horizontally (until you’ve already “made it”) - the bottleneck will be your DB
  • 55. RESTful web service • REST is how the web already works (makes it a pretty well known standard) • URL’s are self explanatory (easy to work with) • Closely matches the underlying data/objects • Makes it easy to build in a DRY way • Developers can get started very quickly
  • 56. HTTP methods • POST : Create something new • GET : Retrieve something that already exists • PUT : Update something that already exists • DELETE : Remove something that already exists
  • 57. Authorization and Authentication • Authentication • Who is this • Authorization • Can the Authenticated entity access this resource
  • 58. oAuth1 vs oAuth2 • oAuth 2 is slightly less secure • But it makes everyone’s lives SO much easier • Build a “trusted” clients paradigm for internal use - login, register, reset password etc
  • 59. HTTP Request Authentication Web server Framework Authentication It makes things really easy for developers Authorization lots of libraries and examples exist API Controller
  • 60. Access Tokens • Different tokens for user+client and client • Store useful info in them, allows you to calculate on the fly instead of store in the db c1234-g7rCEVB867rbe4B-1234567
  • 61. Access Tokens • Different tokens for user+client and client • Store useful info in them, allows you to calculate on the fly instead of store in the db c1234-g7rCEVB867rbe4B-1234567 client_id = 12345
  • 62. Access Tokens • Different tokens for user+client and client • Store useful info in them, allows you to calculate on the fly instead of store in the db c1234-g7rCEVB867rbe4B-1234567 user_id = 1234576
  • 63. Access Tokens • Different tokens for user+client and client • Store useful info in them, allows you to calculate on the fly instead of store in the db c1234-g7rCEVB867rbe4B-1234567 hash(client_secret+user_id)
  • 64. Access Tokens • Different tokens for user+client and client • Store useful info in them, allows you to calculate on the fly instead of store in the db c1234-g7rCEVB867rbe4B-1234567
  • 65. SSL iPhone WiFi laptop running squid internet • Require it, otherwise developers will expose all sort of stuff (like keys) • Important if you want to be taken seriously by developer community
  • 66. SSL iPhone WiFi laptop running squid internet looking at all the traffic is easy • Require it, otherwise developers will expose all sort of stuff (like keys) • Important if you want to be taken seriously by developer community
  • 67. Standardized Errors • Assume success=true • Always send back errors in the same way, so client libraries can be smart { "error": { "type": "ObjectException", "message": "Object does not exist" } }
  • 68. Limit how much data gets send back • Mobile developers care a lot about this • allow customizations: fields=name,gender
  • 70. HTTP Request Logging Errors: Web server • GetExceptional $20 a month (whats your time worth?) Performance: Framework • New Relic API Requests • Something simple near the top of your stack Logging (remember, storage is cheap) API Controller
  • 77. JSON • It’s smaller than XML • Developers write bad xml parsers, that rely on the order of the XML nodes • Facebook use it, and they set the standard - you want your API to be sexy don’t you?
  • 78. Returning Data • Standarized - objects - arrays of objects - nested objects
  • 80. DRY Documentation never goes out of date • Build it off the - models - connections - methods
  • 81. Testing • Write tests on your API • Even if you hate tests • It’s easy • You can generate most of them just like the documentation
  • 82. Tie it all together • A good API is a series of simple layers • Keep it DRY • Use the data structure for more dynamic code • Standards are your friend • There are plenty of examples out there - Facebook, Foursquare, Twitter etc
  • 83. Thanks • Hope this was useful

Editor's Notes

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. \n
  27. \n
  28. \n
  29. \n
  30. \n
  31. \n
  32. \n
  33. \n
  34. \n
  35. \n
  36. \n
  37. \n
  38. \n
  39. \n
  40. \n
  41. \n
  42. \n
  43. \n
  44. \n
  45. \n
  46. \n
  47. \n
  48. \n
  49. \n
  50. \n
  51. \n
  52. \n
  53. \n
  54. \n
  55. \n
  56. \n
  57. \n
  58. \n
  59. \n
  60. \n
  61. \n
  62. \n
  63. \n
  64. \n
  65. \n
  66. \n
  67. \n
  68. \n
  69. \n
  70. \n
  71. \n
  72. \n
  73. \n
  74. \n
  75. \n
  76. \n
  77. \n
  78. \n
  79. \n
  80. \n
  81. \n
  82. \n
  83. \n