13.07.2015 Views

Software Engineering for Internet Applications - Student Community

Software Engineering for Internet Applications - Student Community

Software Engineering for Internet Applications - Student Community

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

capability. How does our modern computer user view the results ofhis or her computations? On a 19-inch monitor.Programmers of most applications no longer need concernthemselves too much with processor and memory efficiency, whichwere obsessions in the 1960s. CPU and RAM are available inabundance. But screen real estate is as precious as ever. Look atyour page designs. Is the most important in<strong>for</strong>mation availablewithout scrolling? (In the newspaper business the term <strong>for</strong> this is"above the fold".) Are you making the best use of the screen spacethat you have? Are these large swaths of empty space on the page?Could you be using HTML tables to present two or three columns ofin<strong>for</strong>mation at the same time?One particularly egregious waste of screen space is the use of icons.Typically users can't understand what the icons mean so they needto be supplemented with plain language annotation. Generally thebest policy is to let the in<strong>for</strong>mation be the interface, e.g., display a listof article categories (the in<strong>for</strong>mation) and clicking on a category is theway to navigate to a page showing articles within that category.TimeMost people prefer fast to slow. Most people prefer consistent servicetime to inconsistent service time. These two preferences contributesubstantially to the popularity of McDonald's restaurants worldwide.When people are done with their lunch they bring those samepreferences to computer applications: fast is better than slow;response time should be consistent from session to session.Computer and network speeds will change over the years but humanbeings will evolve much more slowly. Thus we should start byconsidering limits derived from the humanity of our users. Theexperimental psychologists will tell us that short-term memory is good<strong>for</strong> remembering only about seven things at once ("The MagicalNumber Seven, Plus or Minus Two: Some Limits on Our Capacity <strong>for</strong>Processing In<strong>for</strong>mation", George A. Miller, The Psychological Review1956, 63:81-97) and that this memory is good <strong>for</strong> only about 20seconds. It is thus unwise to build any computer application in whichusers are required to remember too much from one page to another.It is also unwise to build any computer application where theinterpage delay is more than 20 seconds. People might <strong>for</strong>get whattask they were trying to accomplish!• task accomplishment: the user wants to find the photoupload page, not find discussions of photo sharing when heor she types "photo sharing"• housekeeping: the user wants to find the site's privacypolicy, not a discussion about privacy policies, after typing"privacy policy"On a large site a user might wish to restrict the search in some way.If the search <strong>for</strong>m is at the top of a document that is a chapter of anonline book, it might make sense to offer "whole site" and "within thechapters of this book" options. If the publisher or the other users havegone to the trouble of rating content, the default search might limitresults to those documents that have been rated of high quality. Ifthere are multiple discussion <strong>for</strong>ums on the site, each of which isessentially a self-contained subcommunity, the search boxes onthose pages might offer a "restrict searching to postings in this <strong>for</strong>um"option. If a user hasn't visited the site <strong>for</strong> a month and wants to see ifthere is anything new and relevant, the site should perhaps offer a"restrict searching to content added within the last 30 days" option.12.1 What's Wrong with SQL (Search Quality)The relational database management system (RDBMS) sounds likethe perfect tool <strong>for</strong> this job. We have a lot of data and we want toprovide a lot of flexibility in querying. Suppose a person comes to asite <strong>for</strong> athletes and types "running" into the search <strong>for</strong>m. The sitesends the following SQL query to the database:select *from contentwhere body like '%' || :user_query || '%'which, by the time the bind variable :user_query is substituted,turns intoselect *from contentwhere body like '%running%'In Oracle this won't pick up a row whose message contains the sameword but with a different capitalization. Instead we doselect *from contentwhere upper(body) like upper('%running%')122227

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!