Tags:
create new tag
, view all tags
Some browser issues relate to the use of caches. I was going to attempt to refactor some of the page BrowserIssues but felt that:
  • I need to understand caches a little (or a lot) better in order to understand and then make a coherent explanation of the problems, and
  • People who try to read the page who don't understand caching need a simple and concise explanation.

On this page, I will attempt to do that, but probably starting with the long winded explanation based on what I think I know (because I'm WritingToThink, (or WritingToUnderstand), and then correcting it and editing it for conciseness.

Update: It looks like there are useful resources (and pointers to useful resources) here on TWiki, see Codev.BrowserAndProxyCacheControl, Codev.ViewAfterSaveCachesOldPage, and Codev.ViewAfterSaveLosesText for starters. -- rhk_

See AboutThesePages.

Contents

What Is a Cache

I'd like to come up with one or two useful real world examples. Let's try these:

A Local Bookstore

You can think of the stock of books at your local bookstore as a cache of books. The real source of the books is the publisher/printer's "factory". He doesn't print books to order, he prints large runs of books, and then "caches" them in warehouses and bookstores across the country.

In the normal course of events (when a book is in stock at your local bookstore), when you buy a book, you get it from the cached supply at the local bookstore. You get it much faster since it doesn't have to be shipped from the "factory" to you. Likewise, caching of information helps it get to you much faster.

Also, caching of books in a local bookstore helps make things easier on the shipping infrastructure. Instead of setting up a shipment from the factory to each buyer of a book, every time a book is bought, many fewer shipments are set up. When the book is first printed, a few shipments go from the printery to some strategically located warehouses. Then a larger quantity of shipments are made from those warehouses to local booksellers. But, the total number of shipments is far less than if each book was shipped to the final buyer. (Or, at least normally this is the case, and it is certainly the desired result.)

So, there is less traffic on the infrastructure (highways, railroads, boats, etc.) to deliver a given quantity of books. (Individual shipments are bigger, but there are fewer shipments. No one would ever do this, but imagine the situation if a tractor trailer were dispatched with a single book to deliver from the printery to the home of the person ordering the book! (Clearly that's an exxageration, if this was even close to the way things were done, you'd load that single tractor trailer with many different books for many different people that lived in the same geographical area. My example is just an exxageration to highlight some of the potential problems solved by caching books in warehouses and local bookstores.)

Now, to make this example more useful for talking about caching on the Internet, we will want to talk about a few special cases.

  • Suppose someone tells you that you should read Tenth Anniversary Edition of Stephen Hawking's "A Brief History of Time" because previous editions had some incorrect (or outdated) information, and your local bookstore only has the older edition.

  • Or (related to the above) suppose you just know that you want the latest edition of the book, but you don't know what the latest edition is. Do you just go to the bookstore and pick up the latest edition there and assume it is the latest edition available, or do you ask the bookstore to check with the publisher and find out whether what they have in stock is the latest edition?
    • Is it satisfactory if they just check back to the warehouse?
    • How long will you wait to get the latest edition, or are you willing to buy the current copy in the bookstore and buy a new copy when the latest edition comes in? Are you willing to pay extra (a special order charge and overnight shipping) to have the latest edition delivered to you the next day?

  • Other special cases?

All (or most) of these cases have some analog to caching on the Internet.

A Local Grocery Store

Hmm, maybe the bookstore analogy is all I need. I think it covers most cases. Maybe the only one that would be useful (I'll have to think about it) is a case where all the canned corn in a local grocery store is beyond it's "sell by" date. Yes, I think that will be useful.

Starting the Story

Ok, now I have to relate the situations in the book and grocery store to caching on the Internet.

Here are some points to deal with:

  • The analogies are not exact because computers can almost instantly create another copy. But they are still relevant, because if you copy an outdated original you get an outdated copy.
  • The idea of warehouses and local bookstores is useful because the Internet caches data at different locations. (In fact, extending the analogy to national and regional warehouses might be helpful -- maybe done easiest for grocery stores.) The local bookstore might be your browser's cache. A local warehouse might be a caching proxyserver in (at) your company's firewall. Where are other caches on the Internet? Should I talk about mirrors or load sharing servers? (Are mirrors the national warehouses?) (Is a load sharing server a second printing press at the printery, or a second printery in another part of the world, or?)

Aside

While saving this page just moments ago in preparation for taking a break, I previewed the page successfully, but when I saved it I got an error -- what did it say -- I can't remember, but it was like no content available. That is one of the caching problems I'm quite sure. IIRC, I went back to the edit page, previewed again (successfully), then saved again, this time successfully. Next time I see it, I'll make notes. (I am working in Mozilla 0.9.8 on Mandrake 8.2.)

<Taking a break>

Notes

Resources

See ResourceRecommendations. Feel free to add additional resources to these lists, but please follow the guidelines on ResourceRecommendations including ResourceRecommendations#Guidelines_for_Rating_Resources.

Recommended

  • (rhk) [[][]] --

Recommended for Specific Needs

  • (rhk) [[][]] --

Recommended by Others

  • (rhk) [[][]] --

No Recommendation

  • (rhk) [[][]] --

Not Recommended

  • (rhk) [[][]] --

Contributors

  • () RandyKramer - 14 Jul 2002
  • <If you edit this page: add your name here; move this to the next line; and include your comment marker (initials), if you have created one, in parenthesis before your WikiName.>

[[Main.RandyKramer#14 Jul 2002][]]

Rants

See MyRantings.

I wasn't going to rant, and this rant probably reflects poorly on myself, but why isn't there a simple, clear, concise explanation of things like caching. Now I'm sitting here thinking of undertaking a "study" of caching instead of the "goals" I originally had in mind. (Like I did a "study" of email servers, and a "study" of Linux.) Hmm, I guess that's part of Wikilearn.WhyWikilearn. Anyway, I may be complaining too soon -- I need to look at the resources listed above -- I might find the simple, clear, concise explanation I'm looking for.

Page Ratings

Edit | Attach | Watch | Print version | History: r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r2 - 2002-07-15 - RandyKramer
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by PerlCopyright 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding WikiLearn? WebBottomBar">Send feedback
See TWiki's New Look