WebFund 2013F Lecture 19

From Soma-notes
Revision as of 19:11, 29 November 2013 by Soma (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The audio from the lecture given on November 25, 2013 is available here.

Notes

==Assignment 4 remarks

  • Shouldn’t need to use prototypes at all in assignment
  1. Before insert, do a lookup
    1. If there, you have the document and edit that
  2. Search for a special room called “start”
    1. Start is not a room, it’s a room pointer
    2. Can put description of a room in there
    3. Could have everything linked to the start room
      1. Have all rooms exit to start
      2. Title won’t be start
  3. JavaScript string replace
    1. Don’t use a for-loop
      1. There are nice string manipulation routines in JavaScript
  4. TA’s will be using their own custom database to test code
  5. Look up how to do file uploads
    1. Might do this in tutorial
    2. Don’t have to do string checking, just have to check objects to make sure all fields are there and they aren’t undefined
    3. Do all the exits refer to a room that actually exists?
      1. Not super important to do
    4. Each room has name, title, description exits, has a start room
      1. Can say valid
  6. Have to validate the data structure
    1. Have to make sure you don’t import garbage
  7. Don’t have to do this with AJAX

non assignment stuff

    • To get style points, probably going to have to do something nice
      • Probably don’t want to have to press submit a million times
  • Always time costs when you distribute a system
  • How’s it going to fail?
    • Anything from a database is expensive
  • Want a static webserver for front end
    • Incoming requests first go through here, if it can handle it, it will hand it off and respond
    • If it can’t, it will send it back
  • Gets don’t change server state, posts do
  • Gets can be cached
  • CDN
    • Content Distribution Network
    • Some combination between static servers and caching
  • Reading is never a problem
  • Searches are easy
  • Writes are what slow you down
    • Cannot be automatically replicated
    • Changed the state of part of your database, essentially your data structure
    • This is what limits database scalability
  • Fred Brooks