Some ideas from Full Stack Fest 2016

Dapeng Li

Full Stack Fest

  • Barcelona
  • 2 days on Backend
  • 2 days on Frontend

现趸现卖

selling stuff one just acquired from somewhere

Operations

Scalability

Security

Development

Architectures

Programming Langs

Specifications

Applications

For curious minds

New ideas

Reflections

Operations

undefined

Development

GraphQL

Serverless app

For curious minds

Physical Web

IPFS

Project:

how a project evolves, what happened with XYZ

Technical herd:

language, platform, specification

Discipline:

computing, software engineering

Human kind:

preserving knowledge, equality, freedom

Project:

undefined

Technical herd:

GraphQL, Serverless App, Physical Web

Discipline:

undefined

Human kind:

IPFS

GraphQL

Data query spec for APIs

REST is simple, but it...

  • Focuses on use cases
  • Can bloat quickly
  • Couples consumers & providers

A REST endpoint

teams/1

{
    name: 'FC Barcelona',
    city: 'Barcelona',
    country: 'Spain,
    stadium: 'Camp Nou',
    manager: 'Luis Enrique'
}

A REST endpoint (cont.)

teams/1

{
    name: 'FC Barcelona',
    city: 'Barcelona',
    country: 'Spain,
    stadium: 'Camp Nou',
    manager: 'Luis Enrique',
    president: 'Josep Maria Bartomeu',
    website: 'http://www.fcbarcelona.com/',
    leagues: [
        {
            name: 'La Liga',
            ...
        },
        ...
    ],
    players: [
        {
            name: 'Lionel Messi',
            nationality: 'Argentina',
            position: 'forward'
        },
        {
        },
        ...
    ],
    trophies: [
    ],
    ...
}

Example of GraphQL

{
    team(id: 1) {
        name
        stadium
        manager
    }
}
{
    team: {
        name: 'FC Barcelona',
        stadium: 'Camp Nou',
        manager: 'Luis Enrique'
    }
}

Example of GraphQL (cont.)

{
  team(id: 1) {
    name
    manager
    website
    leagues(country: 'Spain') {
        name
    }
    players(first: 5) {
        name
        position
    }
  }
}
{
  team: {
    name: 'FC Barcelona',
    manager: 'Luis Enrique',
    website: 'http://www.fcbarcelona.com/',
    leagues: [
      {
        name: 'La Liga'
      }
    ],
    players: [
      {
        name: 'Lionel Messi',
        position: 'forward'
      },
      {
      },
      ...
    ]
  }
}

Comparison

Advantages

  • Clean API
  • Efficient communication
  • Easier documentation

Challenges

  • Complexity
  • Security
  • Caching

More logic in Frontend?

FE is a Full Stack

(interlude)

Evolution of FE

Evolution of FE (cont.)

Evolution of FE (cont.)

Evolution of FE (cont.)

Serverless app

functions, functions, functions

Ideas to the extreme

  • Code review -> Pair programming
  • Unit Test -> Test driven development
  • Frequent delivery -> Continuous delivery

Serverless app

  • FaaS (Amazon Lambda)
  • Write functions, pay per execution*
  • Forget about managing servers

* Java, JavaScript and Python are currently supported in Amazon Lambda

Advantages

  • Focus on business logic
  • Reduce cost
  • Auto scale

Challenges

  • Organize code effectively
  • Vendor lock-in
  • Different security and identity models
  • Loss of control

Physical Web

Discover things around you

There's an app for everything, but...

I don't want to install 1000 apps on my phone

There might be a website for it, but how do I find it?

  • Search engine
  • Displayed URL
  • QR Code

Beacons

  • Broadcast content (URL)
  • Long battery life (Bluetooth LE)
  • Small

Enables interaction when native is not practical

 

Any physical web devices nearby?

Advantages

  • Opens like a web
  • Just a web page
  • On-demand
  • Scales

Challenges

  • Spam?
  • Phishing?
  • Thousands of beacons?

IPFS

Aims to replace HTTP

Challenges with HTTP

  • Inefficient and expensive
  • Humanity's history is deleted daily
  • The web's centralization limits opportunity
  • Our apps are addicted to the backbone

InterPlanetary File System

...IPFS could be seen as a single BitTorrent swarm, exchanging objects within one Git repository

Usages

  • Preserve knowledge
  • Spread knowledage
  • Deliver content

Personal observations

The Web keeps getting better

Functional Programming

P2P computing

Thank you

Some ideas from Full Stack Fest 2016

By Dapeng Li

Some ideas from Full Stack Fest 2016

  • 856