day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day...

21
day 10

Upload: others

Post on 19-Aug-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

day 10

Page 2: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

mobile developmentday 11, day 12

Page 3: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

I'm still struggling to understand the concept of a callback function. Could we go over that again?

Page 4: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

So when we talked about Ajax and you showed us the lag Google maps exhibits when dragging around quickly, it seems what

actually happens is that for a split second we are shown a very blurry image of a map, which then comes into focus a second later.

It seems that the lag is not due to communication time with the server (as I presume we would see a blank space for a second

instead of seeing a blurry map that eventually comes into focus) but rather the rendering time on the client side. Is this a correct way to think about it? In general, when it comes to client-side

image rendering, does that lag time usually outweigh the lag of the actual communication time with the server? Is that a bottleneck of

the browser's power or of the client-computer's RAM?

Page 5: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

When the appearance/format of a website changes dynamically (for example a carousel graphic, or elaborate iterations of

graphics or headers, for instance here http://gisele.underarmour.com) is this an example of ajax or

asynchronization? Or is this a different complicated front-end programming language and ajax is more back-end?

Page 6: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

What's the difference between local storage and a cookie? When is an example you would use local storage and not a cookie?

Page 7: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

vertical scaling

CPU

cores, L2 cache, …

Disk

SATA, SAS, SSD, …

RAID

RAM

Page 8: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

horizontal scaling

Page 9: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

extremetech.com

Page 10: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

caching

• Python bytecode

• MySQL query cache

• Memcache

• Redis

• …

Page 11: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

load balancing

microsoft.com

Page 12: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

%  nslookup  www.google.com  

Non-­‐authoritative  answer:  Name:  www.google.com  Address:  173.194.219.99  Name:  www.google.com  Address:  173.194.219.106  Name:  www.google.com  Address:  173.194.219.147  Name:  www.google.com  Address:  173.194.219.104  Name:  www.google.com  Address:  173.194.219.105  Name:  www.google.com  Address:  173.194.219.103

Page 13: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

sticky sessions

cookies

shared storage

Page 14: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

master-slave replication

High Performance MySQL

Page 15: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

master-master replication

High Performance MySQL

Page 16: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

load balancing + replication

High Performance MySQL

Page 17: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

load balancing + replication +partitioning

High Performance MySQL

Page 18: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

high availability

High Performance MySQL

Page 19: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

cloud services

Amazon Web Services

Google App Engine

Microsoft Azure

Page 20: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

Amazon Web Services

CloudFront Elastic Compute Cloud (EC2)ElasticacheElastic Load Balancer (ELB)GlacierRelational Database Service (RDS)Route 53Simple Storage Service (S3)…

Page 21: day 10 - cdn.cs50.netcdn.cs50.net/2015/mba/classes/10/day10.pdf · day 10. mobile development day 11, day 12. I'm still struggling to understand the concept of a callback function

to be continued