Does Your Stuff Scale?

28
Does your stuff scale? Steven Holmes http://p.ota.to

description

Slides from my DjangoCon Europe 2013 talk: Does Your Stuff Scale?

Transcript of Does Your Stuff Scale?

Page 1: Does Your Stuff Scale?

Does your stuff scale?Steven Holmeshttp://p.ota.to

Page 2: Does Your Stuff Scale?

Potato?

Page 3: Does Your Stuff Scale?

Does your stuff scale?

1. Django + Google App Engine

2. Scaling an organisation + culture

Page 4: Does Your Stuff Scale?

Non-technical

Scalability

Technical1. Load2. Functional

3. Organisational4. Geographic

Page 5: Does Your Stuff Scale?

Part 1

+

Page 6: Does Your Stuff Scale?

1. Auto-scaling

2. Services & APIs

3. No sysadmin

Why Google App Engine?

Page 7: Does Your Stuff Scale?

Just make good things.

Page 8: Does Your Stuff Scale?

App Engine: caveats

1. Sandbox

2. File system

3. Portability

Page 9: Does Your Stuff Scale?

What is it?• Django ported to NoSQL• GitHub, open source• Django 1.4, Django 1.5 beta

Pros• Familiar APIs• Portability• Works in production

How do you run it?• Clone repo(s)• ./manage.py runserver

Cons• Familiarity can be misleading• Can feel ‘heavy’ / kludgy

Django non-rel github.com/django-nonrel

Page 10: Does Your Stuff Scale?
Page 11: Does Your Stuff Scale?

What is it?• Lightweight skeleton• Django + App Engine models

Pros• “Best of both worlds”• NDB

• Automatic caching, structured data

How do you run it?• Clone repo• dev_appserver.py .

Cons• Learning curve• Portability

Djappengine github.com/potatolondon/djappengine

Page 12: Does Your Stuff Scale?
Page 13: Does Your Stuff Scale?

What is it?• Custom Django database backend wrapper for Django's MySQL backend

Pros• Fully supported Django

• Flexibility

• Unpredictable reporting

How do you run it?• Create a CloudSQL instance

• 'google.appengine.ext.django.backends.rdbms' in settings.py

• ./manage.py syncdb

Cons• More setup

• Possibly not as scalable as datastore?

App Engine + CloudSQL Search “Django + CloudSQL”

Page 14: Does Your Stuff Scale?
Page 15: Does Your Stuff Scale?

Part 2

Page 16: Does Your Stuff Scale?

Technical

Non-technical

Scalability

1. Load2. Functional

3. Organisational4. Geographic

+

Page 17: Does Your Stuff Scale?

• Planning

• Caching

• Offline tasks

• Preparation◦ Load tests

◦ Profiling (e.g. using app stats)

Scalability - Load

Page 18: Does Your Stuff Scale?

Technical

Non-technical

Scalability

1. Load2. Functional

3. Organisational4. Geographic

+

Page 19: Does Your Stuff Scale?

• Django!◦ Documentation, Community

• App Engine◦ Services & APIs

■ Memcache

■ Taskqueue, mapreduce■ Search

■ Email■ Images

◦ Versioning■ 10 testable versions per app■ http://0.myapp.appspot.com {live}■ http://1.myapp.appspot.com {not live}

■ http://some-feature-branch.myapp.appspot.com {not live}

■ A/B testing / traffic splitting◦ SDK

Scalability - Functional

Page 20: Does Your Stuff Scale?

Technical

Non-technical

Scalability

1. Load2. Functional

3. Organisational4. Geographic

+

Page 21: Does Your Stuff Scale?

• Be a minimalist• Remove bottlenecks & overhead• Just make good things.• Internal apps

Scalability - Organisational

Page 22: Does Your Stuff Scale?
Page 23: Does Your Stuff Scale?
Page 24: Does Your Stuff Scale?
Page 25: Does Your Stuff Scale?

• Be a minimalist• Remove bottlenecks & overhead• Just make good things.• Internal apps◦ e.g. wiki, recruitment, deployments, checklists

Scalability - Organisational

• Integrated and centralised◦ Google Apps domain

• Security◦ HTTPs

Page 26: Does Your Stuff Scale?

Technical

Non-technical

Scalability

1. Load2. Functional

3. Organisational4. Geographic

+

Page 27: Does Your Stuff Scale?

Just make good things.

Page 28: Does Your Stuff Scale?

Questions?

• Potato lab > http://p.ota.to/lab

• GitHub > github.com/potatolondon

• App Engine > developers.google.com/appengine

• Django non-rel > django-nonrel.org